org.norther.tammi.core.monitor
Class DefaultFinalizer<T>
java.lang.Object
org.norther.tammi.core.base.Adaptee
org.norther.tammi.core.thread.DefaultExecutable
org.norther.tammi.core.monitor.DefaultFinalizer<T>
- Type Parameters:
T
- the object type.
- All Implemented Interfaces:
- Serializable, Runnable, NotificationBroadcaster, NotificationEmitter, Manageable, MBeanDelegate, Startable, Finalizer<T>, Executable
public class DefaultFinalizer<T>
- extends DefaultExecutable
- implements Finalizer<T>
A default implementation of Finalizer.
- Version:
- $Id: DefaultFinalizer.java,v 1.6 2009/09/28 15:08:42 cvsimp Exp $
- Author:
- Ilkka Priha
- See Also:
- Serialized Form
Methods inherited from class org.norther.tammi.core.base.Adaptee |
addAdaptee, addNotificationListener, getAttributeSupport, getBroker, getCanonicalName, getDomain, getFactory, getLoader, getLog, getLog, getMBean, getMBeanServer, getNotificationInfo, getObjectName, getRegistrationTime, getSequenceNumber, hasListeners, isRegistered, premanaged, removeNotificationListener, removeNotificationListener, sendNotification, sendNotification, sendNotification, sendNotification, unregister |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DefaultFinalizer
public DefaultFinalizer()
- Constructs a new finalizer.
addPhantomListener
public PhantomReference<T> addPhantomListener(T referent,
QueueListener listener)
- Description copied from interface:
Finalizer
- Adds a new phantom reference to the reference queue and registers its
listener.
- Specified by:
addPhantomListener
in interface Finalizer<T>
- Parameters:
referent
- the referent of the reference.listener
- a listener for the enqueued referent.
- Returns:
- the new phantom reference.
addWeakListener
public WeakReference<T> addWeakListener(T referent,
QueueListener listener)
- Description copied from interface:
Finalizer
- Adds a new weak reference to the reference queue and registers its
listener.
- Specified by:
addWeakListener
in interface Finalizer<T>
- Parameters:
referent
- the referent of the reference.listener
- a listener for the enqueued referent.
- Returns:
- the new weak reference.
addSoftListener
public SoftReference<T> addSoftListener(T referent,
QueueListener listener)
- Description copied from interface:
Finalizer
- Adds a new soft reference to the reference queue and registers its
listener.
- Specified by:
addSoftListener
in interface Finalizer<T>
- Parameters:
referent
- the referent of the reference.listener
- a listener for the enqueued referent.
- Returns:
- the new soft reference.
removeListener
public void removeListener(Reference<?> reference)
- Description copied from interface:
Finalizer
- Removes the registered listener of a reference.
- Specified by:
removeListener
in interface Finalizer<T>
- Parameters:
reference
- the reference.
run
public void run()
- Specified by:
run
in interface Runnable
- Overrides:
run
in class DefaultExecutable
Copyright © 2004 The Norther Organization. All rights reserved.