java.lang.Object
de.espirit.firstspirit.access.store.templatestore.gom.Item
All Implemented Interfaces:
ValueOfContractor, Serializable
Direct Known Subclasses:
Preset

public abstract class Item extends Object implements Serializable, ValueOfContractor
Abstract supertype for item providing containers. Subclasses have to implement ValueOfContractor creating a new instance by an item-name having a corresponding is-prefixed method. E.g., the item "Default" (case-sensitive) must have a corresponding method "isDefault" (case-sensitive).
Since:
4.0.55
See Also:
  • Constructor Details

    • Item

      protected Item(@NotNull @NotNull String name)
      Constructor taking the item's name.
      Parameters:
      name - The item's name.
      Since:
      4.0.55
  • Method Details

    • getName

      public String getName()
      Provides the item's name.
      Returns:
      The item's name.
      Since:
      4.0.55
    • equals

      public boolean equals(Object obj)
      Equality implementation based on the item's name.
      Overrides:
      equals in class Object
      Parameters:
      obj - The object to compare to.
      Returns:
      true, if equal.
      Since:
      4.0.55
    • hashCode

      public int hashCode()
      The hashcode implementation.
      Overrides:
      hashCode in class Object
      Returns:
      The hashcode.
      Since:
      4.0.55
    • toString

      public String toString()
      Provides the textual representation of this item.
      Overrides:
      toString in class Object
      Returns:
      The textual representation.
      Since:
      4.0.55
    • getAnnotation

      public final <T extends Annotation> T getAnnotation(Class<T> clazz)
      Provides all annotations defined for the given class.
      Parameters:
      clazz - The class to get annotations for.
      Returns:
      The class's annotations.
      Since:
      4.0.55
    • camelize

      protected static String camelize(String name)
      Camelizes the given name.
      Parameters:
      name - The name to be camelized.
      Returns:
      The camelized name.
      Since:
      4.0.55