Package com.iizix.api

Enum AnnotationType

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<AnnotationType>

    public enum AnnotationType
    extends java.lang.Enum<AnnotationType>
    The annotation types.
    Author:
    Christopher Mindus
    • Field Detail

      • fqn

        public final java.lang.String fqn
        The class name for the annotation.
      • scope

        public final AnnotationType scope
        The type used for annotation scoping, null for none.
      • isScope

        public final boolean isScope
        Flag indicating this is the scope annotation.
      • refDescription

        public final java.lang.String refDescription
        The description of the supported classes being referenced, null for none.
      • refPropClasses

        public final java.lang.Class<?>[] refPropClasses
        Array of supported property classes being referenced, null for none.
      • signature

        public final java.lang.String signature
        Method signature as e.g. "void(com.iizix.api.vs.VSActionEvent,java.lang.String)".
      • params

        public final java.lang.String params
        Parameters names (signature) as e.g. "event,myString".
      • isStatic

        public final boolean isStatic
        Static flag, used for methods and classes (not reference type annotations).
      • processor

        public final IAnnotationReferenceProcessor<?,​?> processor
        The reference processor interface, null if not a reference annotation type.
    • Method Detail

      • values

        public static AnnotationType[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (AnnotationType c : AnnotationType.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static AnnotationType valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • getEventAtom

        public Atom getEventAtom()
        Gets the atom for the event.
        Returns:
        An atom as Atom.get('$'+name()).
      • isReferenceClassAllowed

        public boolean isReferenceClassAllowed​(java.lang.Class<?> refClass)
        Verifies if a class is allowed as the referenced property class.
        Parameters:
        refClass - The class reference found.
        Returns:
        true if allowed, false otherwise.
      • fromEventAtom

        public static AnnotationType fromEventAtom​(Atom atom)
        Gets the annotation type that matches an atom method event property name.
        Parameters:
        atom - The atom name should be in the form of "$OnNNN".
        Returns:
        The annotation type matching, or null for none.