Enum Class MethodType

java.lang.Object
java.lang.Enum<MethodType>
org.simpleframework.xml.core.MethodType
All Implemented Interfaces:
Serializable, Comparable<MethodType>, Constable

enum MethodType extends Enum<MethodType>
The MethodType enumeration is used to specify a set of types that can be used to classify Java Beans methods. This creates three types for the get, is, and set methods. The method types allow the MethodScanner to determine what function the method has in creating a contact point for the object. This also enables methods to be parsed correctly.
See Also:
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    This is used to represent a method that acts as a getter.
    This is used to represent a method that acts as a getter.
    This is used to represent a a normal method to be ignored.
    This is used to represent a method that acts as a setter.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private int
    This is the length of the prefix the method type uses.
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    private
    MethodType(int prefix)
    Constructor for the MethodType object.
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    This is used to acquire the prefix for the method type.
    static MethodType
    Returns the enum constant of this class with the specified name.
    static MethodType[]
    Returns an array containing the constants of this enum class, in the order they are declared.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • GET

      public static final MethodType GET
      This is used to represent a method that acts as a getter.
    • IS

      public static final MethodType IS
      This is used to represent a method that acts as a getter.
    • SET

      public static final MethodType SET
      This is used to represent a method that acts as a setter.
    • NONE

      public static final MethodType NONE
      This is used to represent a a normal method to be ignored.
  • Field Details

    • prefix

      private int prefix
      This is the length of the prefix the method type uses.
  • Constructor Details

    • MethodType

      private MethodType(int prefix)
      Constructor for the MethodType object. This is used to create a method type specifying the length of the prefix. This allows the method name to be parsed easily.
      Parameters:
      prefix - this is the length of the method name prefix
  • Method Details

    • values

      public static MethodType[] 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 MethodType 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
    • getPrefix

      public int getPrefix()
      This is used to acquire the prefix for the method type. The prefix allows the method name to be extracted easily as it is used to determine the character range that forms the name.
      Returns:
      this returns the method name prefix for the type