Package org.togglz.core.annotation
Annotation Type FeatureAttribute
-
@Retention(RUNTIME) @Target(TYPE) public @interface FeatureAttribute
Annotation used to define custom metadata attributes for features.
Let's assume you want to define a custom attribute that holds the issue identifier of your issue tracker. To do so, create an annotation like this:
@Retention(RetentionPolicy.RUNTIME) @Target(ElementType.FIELD) @FeatureAttribute("Issue") public @interface Issue { String value(); }
Now you can use this new annotation on your feature enum like this:
public enum MyFeatures implements Feature { @Label("My cool new feature") @Issue("TOGGLZ-123") MY_NEW_FEATURE; }
- Author:
- Christian Kaltepoth
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description String
annotationAttribute
The name of the method to call on the annotation to retrieve the value of the attribute.
-