Enum Class FormEncoding

java.lang.Object
java.lang.Enum<FormEncoding>
com.jbstrap.ui.components.form.FormEncoding
All Implemented Interfaces:
Serializable, Comparable<FormEncoding>, Constable

public enum FormEncoding extends Enum<FormEncoding>
Enum containing the possible encoding types of the form data.
Since:
4.0
Author:
JBStrap
  • Enum Constant Details

    • URL_ENCODED

      public static final FormEncoding URL_ENCODED
      Every character is encoded, according to URL encode standard, before sending. (The space character will be "+", while special characters will be converted into their ASCII hex code.)
    • MULTIPART

      public static final FormEncoding MULTIPART
      The data is not encoded. Used when the form contains files. Default encoding type.
    • PLAIN

      public static final FormEncoding PLAIN
      The space character will be "+", while special characters will not be converted.
  • Method Details

    • values

      public static FormEncoding[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static FormEncoding valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getValue

      public String getValue()
      Gets the HTML ID string that corresponds to the method
      Returns:
      The HTML string that corresponds to the method
    • fromValue

      public static FormEncoding fromValue(String value)
      Determines the method, based on the specified HTML ID string
      Parameters:
      value - The HTML ID string
      Returns:
      The corresponding method or null, if not found