|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sbbi.upnp.jmx.UPNPServiceMBean
This is a dynamic MBean for UPNP services The dynamic MBean will be populated with basic informations about UPNP service attributes and operations. You can provide a locale object that will try to lookup a resource bundle to generate attributes and operations informations. The bundle must contains the following data to match the UPNP devices actions and state variables: service.name=My Service description attribute.ServiceAttribute=My Attribute Desc operation.ServiceOperation=My Action de description operation.ServiceOperation.ActionArgument1=My Action first argument description operation.ServiceOperation.ActionArgument2=My Action second argument description and must be named with the UPNP service Id + locale, the service id ':' char must be replaced with '_' chars. urn:upnp-org:serviceId:LANHostCfg1 will be translated into : urn_upnp-org_serviceId_LANHostCfg1_fr.properties
Constructor Summary | |
UPNPServiceMBean(UPNPDevice device,
UPNPService service)
Creates a dynamic MBean from an UPNP service with no resource bundle to describe the service |
|
UPNPServiceMBean(UPNPDevice device,
UPNPService service,
java.util.Locale locale,
java.lang.String bundlePackage)
Creates a dynamic MBean from an UPNP service |
Method Summary | |
java.lang.Object |
getAttribute(java.lang.String attributeName)
|
javax.management.AttributeList |
getAttributes(java.lang.String[] attributeNames)
|
javax.management.MBeanInfo |
getMBeanInfo()
|
javax.management.ObjectName |
getObjectName()
Creates an object name for this device, this name should be used ot avoid any names collision especially with multiple sames UPNP devices type on the network |
static UPNPServiceMBean[] |
getUPNPRootDeviceAsMBeans(UPNPRootDevice device)
Creates UPNPServiceMBean device service mBeans for a given UPNPRootDevice |
java.lang.Object |
invoke(java.lang.String operationName,
java.lang.Object[] paramsValue,
java.lang.String[] signature)
|
void |
setAttribute(javax.management.Attribute attributeName)
|
javax.management.AttributeList |
setAttributes(javax.management.AttributeList attributeNames)
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public UPNPServiceMBean(UPNPDevice device, UPNPService service)
device
- the device that is hosting the serviceservice
- the service that will be exposed as an MBeanpublic UPNPServiceMBean(UPNPDevice device, UPNPService service, java.util.Locale locale, java.lang.String bundlePackage)
device
- the device that is hosting the serviceservice
- the service that will be exposed as an MBeanlocale
- the resource bundle locale, null if no bundle needs to be used..bundlePackage
- the resource bundle package location into the classpath
I.E net/sbbi/upnplib/myDevicesBundlesPackage, null if the bundles are located at the
classpath root.Method Detail |
public java.lang.Object getAttribute(java.lang.String attributeName) throws javax.management.AttributeNotFoundException, javax.management.MBeanException, javax.management.ReflectionException
getAttribute
in interface javax.management.DynamicMBean
javax.management.AttributeNotFoundException
javax.management.MBeanException
javax.management.ReflectionException
public javax.management.AttributeList getAttributes(java.lang.String[] attributeNames)
getAttributes
in interface javax.management.DynamicMBean
public javax.management.MBeanInfo getMBeanInfo()
getMBeanInfo
in interface javax.management.DynamicMBean
public java.lang.Object invoke(java.lang.String operationName, java.lang.Object[] paramsValue, java.lang.String[] signature) throws javax.management.MBeanException, javax.management.ReflectionException
invoke
in interface javax.management.DynamicMBean
javax.management.MBeanException
javax.management.ReflectionException
public void setAttribute(javax.management.Attribute attributeName) throws javax.management.AttributeNotFoundException, javax.management.InvalidAttributeValueException, javax.management.MBeanException, javax.management.ReflectionException
setAttribute
in interface javax.management.DynamicMBean
javax.management.AttributeNotFoundException
javax.management.InvalidAttributeValueException
javax.management.MBeanException
javax.management.ReflectionException
public javax.management.AttributeList setAttributes(javax.management.AttributeList attributeNames)
setAttributes
in interface javax.management.DynamicMBean
public javax.management.ObjectName getObjectName() throws javax.management.MalformedObjectNameException
javax.management.MalformedObjectNameException
public static UPNPServiceMBean[] getUPNPRootDeviceAsMBeans(UPNPRootDevice device)
device
- the root device
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |