Top Description Methods
org.springframework.jmx.export.metadata

public Interface JmxAttributeSource

Known Direct Implementers
org.springframework.jmx.export.annotation.AnnotationJmxAttributeSource
Imports
java.lang.reflect.Method, org.springframework.lang.Nullable

Interface used by the MetadataMBeanInfoAssembler to read source-level metadata from a managed resource's class.
Authors
Rob Harrop, Jennifer Hickey
Since
1.2
See Also
org.springframework.jmx.export.assembler.MetadataMBeanInfoAssembler#setAttributeSource, org.springframework.jmx.export.MBeanExporter#setAssembler

Method Summary

Modifier and TypeMethod and Description
public ManagedAttribute

Returns:

the attribute, or null if not found
getManagedAttribute
(Method
the method to read the attribute data from
method
)

Implementations should return an instance of ManagedAttribute if the supplied Method has the corresponding metadata.

public ManagedMetric

Returns:

the metric, or null if not found
getManagedMetric
(Method
the method to read the attribute data from
method
)

Implementations should return an instance of ManagedMetric if the supplied Method has the corresponding metadata.

public ManagedNotification[]

Returns:

the notification information
getManagedNotifications
(Class<?>
the Class to read the metadata from
clazz
)

Implementations should return an array of ManagedNotifications if the supplied Class has the corresponding metadata.

public ManagedOperation

Returns:

the attribute, or null if not found
getManagedOperation
(Method
the method to read the attribute data from
method
)

Implementations should return an instance of ManagedOperation if the supplied Method has the corresponding metadata.

public ManagedOperationParameter[]

Returns:

the parameter information.
getManagedOperationParameters
(Method
the Method to read the metadata from
method
)

Implementations should return an array of ManagedOperationParameter if the supplied Method has the corresponding metadata.

public ManagedResource

Returns:

the attribute, or null if not found
getManagedResource
(Class<?>
the class to read the attribute data from
clazz
)

Implementations should return an instance of ManagedResource if the supplied Class has the appropriate metadata.

Method Detail

getManagedAttributeback to summary
public ManagedAttribute getManagedAttribute(Method method) throws InvalidMetadataException

Implementations should return an instance of ManagedAttribute if the supplied Method has the corresponding metadata. Otherwise, should return null.

Parameters
method:Method

the method to read the attribute data from

Returns:ManagedAttribute

the attribute, or null if not found

Annotations
@Nullable
Exceptions
InvalidMetadataException:
in case of invalid attributes
getManagedMetricback to summary
public ManagedMetric getManagedMetric(Method method) throws InvalidMetadataException

Implementations should return an instance of ManagedMetric if the supplied Method has the corresponding metadata. Otherwise, should return null.

Parameters
method:Method

the method to read the attribute data from

Returns:ManagedMetric

the metric, or null if not found

Annotations
@Nullable
Exceptions
InvalidMetadataException:
in case of invalid attributes
getManagedNotificationsback to summary
public ManagedNotification[] getManagedNotifications(Class<?> clazz) throws InvalidMetadataException

Implementations should return an array of ManagedNotifications if the supplied Class has the corresponding metadata. Otherwise, should return an empty array.

Parameters
clazz:Class<?>

the Class to read the metadata from

Returns:ManagedNotification[]

the notification information

Exceptions
InvalidMetadataException:
in the case of invalid metadata
getManagedOperationback to summary
public ManagedOperation getManagedOperation(Method method) throws InvalidMetadataException

Implementations should return an instance of ManagedOperation if the supplied Method has the corresponding metadata. Otherwise, should return null.

Parameters
method:Method

the method to read the attribute data from

Returns:ManagedOperation

the attribute, or null if not found

Annotations
@Nullable
Exceptions
InvalidMetadataException:
in case of invalid attributes
getManagedOperationParametersback to summary
public ManagedOperationParameter[] getManagedOperationParameters(Method method) throws InvalidMetadataException

Implementations should return an array of ManagedOperationParameter if the supplied Method has the corresponding metadata. Otherwise, should return an empty array if no metadata is found.

Parameters
method:Method

the Method to read the metadata from

Returns:ManagedOperationParameter[]

the parameter information.

Exceptions
InvalidMetadataException:
in the case of invalid attributes.
getManagedResourceback to summary
public ManagedResource getManagedResource(Class<?> clazz) throws InvalidMetadataException

Implementations should return an instance of ManagedResource if the supplied Class has the appropriate metadata. Otherwise, should return null.

Parameters
clazz:Class<?>

the class to read the attribute data from

Returns:ManagedResource

the attribute, or null if not found

Annotations
@Nullable
Exceptions
InvalidMetadataException:
in case of invalid attributes