|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.avalon.framework.logger.AbstractLogEnabled org.apache.excalibur.instrument.AbstractLogEnabledInstrumentable
Utility class to ease the construction of components that can be instrumented but must also implement LogEnabled.
Subclasses should call addInstrument
or
addChildInstrumentable
as part of the component's
initialization.
Field Summary |
Fields inherited from interface org.apache.excalibur.instrument.Instrumentable |
EMPTY_INSTRUMENT_ARRAY, EMPTY_INSTRUMENTABLE_ARRAY |
Constructor Summary | |
protected |
AbstractLogEnabledInstrumentable()
Creates a new AbstractLogEnabledInstrumentable. |
Method Summary | |
protected void |
addChildInstrumentable(Instrumentable child)
Adds a child Instrumentable to the list of child Instrumentables published by the component. |
protected void |
addInstrument(Instrument instrument)
Adds an Instrument to the list of Instruments published by the component. |
Instrumentable[] |
getChildInstrumentables()
Any Object which implements Instrumentable can also make use of other Instrumentable child objects. |
java.lang.String |
getInstrumentableName()
Gets the name of the Instrumentable. |
Instrument[] |
getInstruments()
Obtain a reference to all the Instruments that the Instrumentable object wishes to expose. |
void |
setInstrumentableName(java.lang.String name)
Sets the name for the Instrumentable. |
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled |
enableLogging, getLogger, setupLogger, setupLogger, setupLogger |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
protected AbstractLogEnabledInstrumentable()
Method Detail |
protected void addInstrument(Instrument instrument)
instrument
- Instrument to publish.protected void addChildInstrumentable(Instrumentable child)
Note that Child Instrumentables must be named by the caller using the setInstrumentableName method.
child
- Child Instrumentable to publish.public final java.lang.String getInstrumentableName()
getInstrumentableName
in interface Instrumentable
public final void setInstrumentableName(java.lang.String name)
This value may be set by a parent Instrumentable, or by the InstrumentManager using the value of the 'instrumentable' attribute in the configuration of the component.
setInstrumentableName
in interface Instrumentable
name
- The name used to identify a Instrumentable.public final Instrumentable[] getChildInstrumentables()
getChildInstrumentables
in interface Instrumentable
public final Instrument[] getInstruments()
getInstruments
in interface Instrumentable
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |