Annotation Type EnumApi


  • @Retention(RUNTIME)
    @Target(TYPE)
    public @interface EnumApi
    Marks interface as an interface, which is meant to be used in API where usually enum is used. Use this interface to receive any string value, and then compare it to other such values with == operator, as you would do with enums. If used to send something to external service, this interface only restricts what developer may explicitly specify with enum, specified in enumClass parameter.
    • Required Element Summary

      Required Elements 
      Modifier and Type Required Element Description
      Class<? extends Enum<?>> enumClass
      Enum, implementing interface on which this annotation is put
    • Element Detail

      • enumClass

        Class<? extends Enum<?>> enumClass
        Enum, implementing interface on which this annotation is put