类 IdentityNamingStrategy
- java.lang.Object
- org.springframework.jmx.export.naming.IdentityNamingStrategy
- 所有已实现的接口:
ObjectNamingStrategy
public class IdentityNamingStrategy extends Object implements ObjectNamingStrategy
An implementation of theObjectNamingStrategy
interface that creates a name based on the identity of a given instance.The resulting
ObjectName
will be in the form package:class=class name,hashCode=identity hash (in hex)- 从以下版本开始:
- 1.2
- 作者:
- Rob Harrop, Juergen Hoeller
字段概要
字段 修饰符和类型 字段 说明 static String
HASH_CODE_KEY
The hash code key.static String
TYPE_KEY
The type key.
构造器概要
构造器 构造器 说明 IdentityNamingStrategy()
构造器详细资料
IdentityNamingStrategy
public IdentityNamingStrategy()
方法详细资料
getObjectName
public ObjectName getObjectName(Object managedBean, @Nullable String beanKey) throws MalformedObjectNameException
Returns an instance ofObjectName
based on the identity of the managed resource.- 指定者:
getObjectName
在接口中ObjectNamingStrategy
- 参数:
managedBean
- the bean that will be exposed under the returnedObjectName
beanKey
- the key associated with this bean in the beans map passed to theMBeanExporter
- 返回:
- the
ObjectName
instance - 抛出:
MalformedObjectNameException
- if the resultingObjectName
is invalid