Re: [JBoss-user] How to get reference to XMBean

2003-07-10 Thread julien viet
I agree, but that would be specific to the xmbean implementation.
usually a managed resource is not aware of the surrounding model mbean.

That might be done with a specific interface in jboss mx, like

interface XMBeanAware
{
void setXMBean(XMBean xmbean);
}

julien

Thursday, July 10, 2003, 12:02:04 PM, you wrote:

EJ Is there any way to get a reference from within a managed object to the
EJ surounding XMBean? The managed object is an MBean and may in rare cases
EJ need to modify the MBeanInfo provided by the XMBean on its behalf.

EJ --
EJ Eric Jain



EJ ---
EJ This SF.Net email sponsored by: Parasoft
EJ Error proof Web apps, automate testing  more.
EJ Download  eval WebKing and get a free book.
EJ www.parasoft.com/bulletproofapps
EJ ___
EJ JBoss-user mailing list
EJ [EMAIL PROTECTED]
EJ https://lists.sourceforge.net/lists/listinfo/jboss-user



-- 
Best regards,
 julienmailto:[EMAIL PROTECTED]



---
This SF.Net email sponsored by: Parasoft
Error proof Web apps, automate testing  more.
Download  eval WebKing and get a free book.
www.parasoft.com/bulletproofapps
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user


Re: [JBoss-user] How to get reference to XMBean

2003-07-10 Thread Scott M Stark
Querying the MBeanRegistry should work:

import javax.management.ObjectName;
import org.jboss.mx.server.ServerConstants;
import org.jboss.mx.server.registry.MBeanEntry;
import org.jboss.mx.server.registry.MBeanRegistry;
   Object[] args = {xmbeanName};
   String[] sig = {ObjectName.class.getName()}
   MBeanEntry entry = (MBeanEntry)
mbeanServer.invoke(ServerConstants.MBEAN_REGISTRY, get, args, sig);
   Object xmbean = entry.getResourceInstance();
--

Scott Stark
Chief Technology Officer
JBoss Group, LLC

Eric Jain wrote:

Is there any way to get a reference from within a managed object to the
surounding XMBean? The managed object is an MBean and may in rare cases
need to modify the MBeanInfo provided by the XMBean on its behalf.
--
Eric Jain


---
This SF.Net email sponsored by: Parasoft
Error proof Web apps, automate testing  more.
Download  eval WebKing and get a free book.
www.parasoft.com/bulletproofapps
___
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user