Package org.glassfish.gmbal.impl
Class MBeanSkeleton
- java.lang.Object
-
- org.glassfish.gmbal.impl.MBeanSkeleton
-
public class MBeanSkeleton extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static class
MBeanSkeleton.DescriptorType
static interface
MBeanSkeleton.Operation
-
Field Summary
Fields Modifier and Type Field Description private static java.security.Permission
accessControlPermission
private static javax.management.Descriptor
DEFAULT_AMX_DESCRIPTOR
private javax.management.Descriptor
descriptor
private java.util.Map<java.lang.String,AttributeDescriptor>
getters
private java.util.List<javax.management.modelmbean.ModelMBeanAttributeInfo>
mbeanAttributeInfoList
private java.util.List<javax.management.modelmbean.ModelMBeanOperationInfo>
mbeanOperationInfoList
private AMXMetadata
mbeanType
private javax.management.modelmbean.ModelMBeanInfoSupport
mbInfo
private ManagedObjectManagerInternal
mom
private AttributeDescriptor
nameAttributeDescriptor
private java.util.Map<java.lang.String,java.util.Map<java.util.List<java.lang.String>,MBeanSkeleton.Operation>>
operations
private java.util.concurrent.atomic.AtomicLong
sequenceNumber
private java.util.Map<java.lang.String,AttributeDescriptor>
setters
private java.lang.String
type
-
Constructor Summary
Constructors Modifier Constructor Description private
MBeanSkeleton(MBeanSkeleton first, MBeanSkeleton second)
MBeanSkeleton(EvaluatedClassDeclaration annotatedClass, EvaluatedClassAnalyzer ca, ManagedObjectManagerInternal mom)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private <K,L,V>
voidaddToCompoundMap(java.util.Map<K,java.util.Map<L,V>> source, java.util.Map<K,java.util.Map<L,V>> dest)
private void
analyzeAttributes(EvaluatedClassAnalyzer ca)
private void
analyzeObjectNameKeys(EvaluatedClassAnalyzer ca)
private void
analyzeOperations(EvaluatedClassAnalyzer ca)
private void
annotatedMethod(EvaluatedMethodDeclaration annotatedMethod)
private void
attributeInfoContents(javax.management.modelmbean.ModelMBeanAttributeInfo info)
private void
attributes(org.glassfish.pfl.basic.contain.Pair<java.util.Map<java.lang.String,AttributeDescriptor>,java.util.Map<java.lang.String,AttributeDescriptor>> amap)
MBeanSkeleton
compose(MBeanSkeleton skel)
Create a new MBeanSkeleton that is the composition of this one and skel.private void
describe(java.lang.String msg, java.lang.Object data)
private void
descriptorContents(java.lang.String name, java.lang.String description, javax.management.Descriptor desc)
java.lang.Object
getAttribute(org.glassfish.pfl.basic.facet.FacetAccessor fa, java.lang.String name)
javax.management.AttributeList
getAttributes(org.glassfish.pfl.basic.facet.FacetAccessor fa, java.lang.String[] attributes)
javax.management.modelmbean.ModelMBeanInfoSupport
getMBeanInfo()
AMXMetadata
getMBeanType()
java.lang.String
getNameValue(org.glassfish.pfl.basic.facet.FacetAccessor fa)
java.lang.String
getType()
java.lang.Object
invoke(org.glassfish.pfl.basic.facet.FacetAccessor fa, java.lang.String actionName, java.lang.Object[] params, java.lang.String[] sig)
private javax.management.modelmbean.ModelMBeanInfoSupport
makeMbInfo(java.lang.String description)
private org.glassfish.pfl.basic.contain.Pair<MBeanSkeleton.Operation,javax.management.modelmbean.ModelMBeanOperationInfo>
makeOperation(EvaluatedMethodDeclaration m)
(package private) javax.management.Descriptor
makeValidDescriptor(javax.management.Descriptor desc, MBeanSkeleton.DescriptorType dtype, java.lang.String dname)
ManagedObjectManagerInternal
mom()
private void
nameAttributeDescriptorIsNull()
private void
processAttribute(AttributeDescriptor getter, AttributeDescriptor setter)
void
setAttribute(javax.management.NotificationBroadcasterSupport emitter, org.glassfish.pfl.basic.facet.FacetAccessor fa, javax.management.Attribute attribute)
javax.management.AttributeList
setAttributes(javax.management.NotificationBroadcasterSupport emitter, org.glassfish.pfl.basic.facet.FacetAccessor fa, javax.management.AttributeList attributes)
private void
setterNames(java.lang.String msg, java.util.Set<java.lang.String> names)
java.lang.String
toString()
-
-
-
Field Detail
-
DEFAULT_AMX_DESCRIPTOR
private static javax.management.Descriptor DEFAULT_AMX_DESCRIPTOR
-
mbeanType
private AMXMetadata mbeanType
-
type
private final java.lang.String type
-
descriptor
private javax.management.Descriptor descriptor
-
sequenceNumber
@DumpToString private final java.util.concurrent.atomic.AtomicLong sequenceNumber
-
mom
@DumpToString private final ManagedObjectManagerInternal mom
-
setters
@DumpIgnore private final java.util.Map<java.lang.String,AttributeDescriptor> setters
-
getters
private final java.util.Map<java.lang.String,AttributeDescriptor> getters
-
nameAttributeDescriptor
private AttributeDescriptor nameAttributeDescriptor
-
operations
private final java.util.Map<java.lang.String,java.util.Map<java.util.List<java.lang.String>,MBeanSkeleton.Operation>> operations
-
mbeanAttributeInfoList
private final java.util.List<javax.management.modelmbean.ModelMBeanAttributeInfo> mbeanAttributeInfoList
-
mbeanOperationInfoList
private final java.util.List<javax.management.modelmbean.ModelMBeanOperationInfo> mbeanOperationInfoList
-
mbInfo
private final javax.management.modelmbean.ModelMBeanInfoSupport mbInfo
-
accessControlPermission
private static final java.security.Permission accessControlPermission
-
-
Constructor Detail
-
MBeanSkeleton
public MBeanSkeleton(EvaluatedClassDeclaration annotatedClass, EvaluatedClassAnalyzer ca, ManagedObjectManagerInternal mom)
-
MBeanSkeleton
private MBeanSkeleton(MBeanSkeleton first, MBeanSkeleton second)
-
-
Method Detail
-
addToCompoundMap
private <K,L,V> void addToCompoundMap(java.util.Map<K,java.util.Map<L,V>> source, java.util.Map<K,java.util.Map<L,V>> dest)
-
makeMbInfo
private javax.management.modelmbean.ModelMBeanInfoSupport makeMbInfo(java.lang.String description)
-
compose
public MBeanSkeleton compose(MBeanSkeleton skel)
Create a new MBeanSkeleton that is the composition of this one and skel. Note that, if this and skel contain the same attribute, the version from skel will appear in the composition.
-
makeValidDescriptor
javax.management.Descriptor makeValidDescriptor(javax.management.Descriptor desc, MBeanSkeleton.DescriptorType dtype, java.lang.String dname)
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
descriptorContents
@InfoMethod private void descriptorContents(java.lang.String name, java.lang.String description, javax.management.Descriptor desc)
-
attributeInfoContents
@InfoMethod private void attributeInfoContents(javax.management.modelmbean.ModelMBeanAttributeInfo info)
-
processAttribute
private void processAttribute(AttributeDescriptor getter, AttributeDescriptor setter)
-
attributes
@InfoMethod private void attributes(org.glassfish.pfl.basic.contain.Pair<java.util.Map<java.lang.String,AttributeDescriptor>,java.util.Map<java.lang.String,AttributeDescriptor>> amap)
-
setterNames
@InfoMethod private void setterNames(java.lang.String msg, java.util.Set<java.lang.String> names)
-
analyzeAttributes
private void analyzeAttributes(EvaluatedClassAnalyzer ca)
-
annotatedMethod
@InfoMethod private void annotatedMethod(EvaluatedMethodDeclaration annotatedMethod)
-
analyzeObjectNameKeys
private void analyzeObjectNameKeys(EvaluatedClassAnalyzer ca)
-
describe
@InfoMethod private void describe(java.lang.String msg, java.lang.Object data)
-
makeOperation
private org.glassfish.pfl.basic.contain.Pair<MBeanSkeleton.Operation,javax.management.modelmbean.ModelMBeanOperationInfo> makeOperation(EvaluatedMethodDeclaration m)
-
analyzeOperations
private void analyzeOperations(EvaluatedClassAnalyzer ca)
-
getType
public java.lang.String getType()
-
getMBeanType
public AMXMetadata getMBeanType()
-
getAttribute
public java.lang.Object getAttribute(org.glassfish.pfl.basic.facet.FacetAccessor fa, java.lang.String name) throws javax.management.AttributeNotFoundException, javax.management.MBeanException, javax.management.ReflectionException
- Throws:
javax.management.AttributeNotFoundException
javax.management.MBeanException
javax.management.ReflectionException
-
setAttribute
public void setAttribute(javax.management.NotificationBroadcasterSupport emitter, org.glassfish.pfl.basic.facet.FacetAccessor fa, javax.management.Attribute attribute) throws javax.management.AttributeNotFoundException, javax.management.InvalidAttributeValueException, javax.management.MBeanException, javax.management.ReflectionException
- Throws:
javax.management.AttributeNotFoundException
javax.management.InvalidAttributeValueException
javax.management.MBeanException
javax.management.ReflectionException
-
getAttributes
public javax.management.AttributeList getAttributes(org.glassfish.pfl.basic.facet.FacetAccessor fa, java.lang.String[] attributes)
-
setAttributes
public javax.management.AttributeList setAttributes(javax.management.NotificationBroadcasterSupport emitter, org.glassfish.pfl.basic.facet.FacetAccessor fa, javax.management.AttributeList attributes)
-
invoke
public java.lang.Object invoke(org.glassfish.pfl.basic.facet.FacetAccessor fa, java.lang.String actionName, java.lang.Object[] params, java.lang.String[] sig) throws javax.management.MBeanException, javax.management.ReflectionException
- Throws:
javax.management.MBeanException
javax.management.ReflectionException
-
nameAttributeDescriptorIsNull
@InfoMethod private void nameAttributeDescriptorIsNull()
-
getNameValue
public java.lang.String getNameValue(org.glassfish.pfl.basic.facet.FacetAccessor fa) throws javax.management.MBeanException, javax.management.ReflectionException
- Throws:
javax.management.MBeanException
javax.management.ReflectionException
-
getMBeanInfo
public javax.management.modelmbean.ModelMBeanInfoSupport getMBeanInfo()
-
mom
public ManagedObjectManagerInternal mom()
-
-