DescriptorKey

Annotation Type DescriptorKey

@Documented
 @Retention(value=RUNTIME)
 @Target(value=METHOD)
public @interface DescriptorKey

Meta-annotation that describes how an annotation element relates to a field in a Descriptor. This can be the Descriptor for an MBean, or for an attribute, operation, or constructor in an MBean, or for a parameter of an operation or constructor.

Consider this annotation for example:

@Documented
 @Target(ElementType.METHOD)
 @Retention(RetentionPolicy.RUNTIME)
 public @interface Units {
     @DescriptorKey("units")
     String value();
 }

and this use of the annotation:

public interface CacheControlMBean {
     @Units("bytes")
     public long getCacheSize();
 }

When a Standard MBean is made from the CacheControlMBean, the