Package org.glassfish.external.amx
Class MBeanListener.CallbackImpl
java.lang.Object
org.glassfish.external.amx.MBeanListener.CallbackImpl
- All Implemented Interfaces:
MBeanListener.Callback
- Direct Known Subclasses:
AMXGlassfish.BootAMXCallback
,AMXGlassfish.WaitForDomainRootListenerCallback
- Enclosing class:
MBeanListener<T extends MBeanListener.Callback>
Default callback implementation, can be subclassed if needed
Remembers only the last MBean that was seen.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final CountDownLatch
private ObjectName
private final boolean
private ObjectName
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
await()
Optional: wait for the CountDownLatch to fire If used, the subclass should countDown() the latch when the appropriate event happensvoid
mbeanRegistered
(ObjectName objectName, MBeanListener listener) void
mbeanUnregistered
(ObjectName objectName, MBeanListener listener)
-
Field Details
-
mRegistered
-
mUnregistered
-
mStopAtFirst
private final boolean mStopAtFirst -
mLatch
-
-
Constructor Details
-
CallbackImpl
public CallbackImpl() -
CallbackImpl
public CallbackImpl(boolean stopAtFirst)
-
-
Method Details
-
getRegistered
-
getUnregistered
-
await
public void await()Optional: wait for the CountDownLatch to fire If used, the subclass should countDown() the latch when the appropriate event happens -
mbeanRegistered
- Specified by:
mbeanRegistered
in interfaceMBeanListener.Callback
-
mbeanUnregistered
- Specified by:
mbeanUnregistered
in interfaceMBeanListener.Callback
-