Module com.zeroc.ice
Package com.zeroc.IceMX
Class ObserverFactoryWithDelegate<T extends Metrics,OImpl extends ObserverWithDelegate<T,O>,O extends Observer>
java.lang.Object
com.zeroc.IceMX.ObserverFactory<T,OImpl>
com.zeroc.IceMX.ObserverFactoryWithDelegate<T,OImpl,O>
- Type Parameters:
T
- the metrics typeOImpl
- the observer implementation type that supports delegationO
- the delegate observer type
public class ObserverFactoryWithDelegate<T extends Metrics,OImpl extends ObserverWithDelegate<T,O>,O extends Observer>
extends ObserverFactory<T,OImpl>
Factory for creating observer instances that support delegation.
-
Constructor Summary
ConstructorsConstructorDescriptionObserverFactoryWithDelegate
(com.zeroc.Ice.MetricsAdminI metrics, String name, Class<T> cl) Constructs an ObserverFactoryWithDelegate. -
Method Summary
Modifier and TypeMethodDescriptiongetObserver
(MetricsHelper<T> helper, Class<OImpl> cl, O delegate) Gets an observer instance with a delegate.getObserver
(MetricsHelper<T> helper, Object observer, Class<OImpl> cl, O delegate) Gets an observer instance with a delegate and previous observer.Methods inherited from class com.zeroc.IceMX.ObserverFactory
destroy, getObserver, getObserver, isEnabled, registerSubMap, setUpdater, update
-
Constructor Details
-
ObserverFactoryWithDelegate
Constructs an ObserverFactoryWithDelegate.- Parameters:
metrics
- the metrics admin instancename
- the name of the metrics mapcl
- the metrics class
-
-
Method Details
-
getObserver
Gets an observer instance with a delegate.- Parameters:
helper
- the metrics helpercl
- the observer implementation classdelegate
- the delegate observer- Returns:
- the observer instance with delegate set, or the delegate if no metrics maps are enabled
-
getObserver
Gets an observer instance with a delegate and previous observer.- Parameters:
helper
- the metrics helperobserver
- the previous observer, or nullcl
- the observer implementation classdelegate
- the delegate observer- Returns:
- the observer instance with delegate set, or the delegate if no metrics maps are enabled
-