|
TPTP 4.4.0 Monitoring Tools Project Public API Specification |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.eclipse.hyades.logging.adapter.impl.Component
Abstract class provided for the convinience. Contains some default implementations of the main functionality for the component Role of the abstract class Component is to provide initial most common implementation of basic functionality for component. So the class provide implementation for the getter and setter for the componentName, getter and setter for the targetName, stabs for the start, stop and update functions.
| Field Summary | |
|---|---|
protected IProcessUnit |
logger
|
protected Status |
status
|
protected boolean |
stopping
|
| Constructor Summary | |
|---|---|
Component()
Constructor for Component. |
|
| Method Summary | |
|---|---|
void |
clean()
|
IComponent[] |
getComponents()
Method returns the components this component manages |
Status |
getComponentStatus()
Get the component status object |
org.w3c.dom.Element |
getConfiguration()
Method getConfiguration. |
org.w3c.dom.Element |
getContextConfiguration()
Method getContextConfiguration. |
java.lang.String |
getDescription()
Method returns the component description |
org.eclipse.hyades.logging.events.cbe.EventFactory |
getEventFactory()
|
java.lang.String |
getExecutableClassName()
Method returns the executable class name |
java.lang.String |
getImplementationCreationDate()
Method returns implementation creation date |
java.lang.String |
getImplementationVersion()
Method returns the version specific role description |
java.lang.String |
getImplementationVersionDescription()
Method returns implementation version description |
int |
getItemsProcessedCount()
Gets the number of items processed by the component. |
IProcessUnit |
getLogger()
Retrieve the logger for this adapter. |
short |
getLoggingLevel()
Method returns loggin level of the component |
java.lang.String |
getName()
Method returns name of the component |
IComponent |
getParent()
Components are arranged in a heirarchy. |
java.lang.String |
getRole()
Method returns the role of the component |
java.lang.String |
getRoleCreationDate()
Method returns role creation date |
java.lang.String |
getRoleVersion()
Method returns the role version |
java.lang.String |
getRoleVersionDescription()
Method returns the version specific role description |
java.lang.String |
getUniqueID()
Method returns the uniqueID of this component instance |
void |
incrementItemsProcessedCount()
Increments the number of items processed count for this component. |
void |
incrementItemsProcessedCount(int n)
Increments the number of items processed count for this component by the value passed in. |
boolean |
init()
Initialize all the Component level properties from the context config for this component, and then ask all child components to do the same. |
boolean |
isDisabled()
|
boolean |
isStopping()
Returns whether the component is in stopping state. |
void |
log(org.eclipse.hyades.logging.events.cbe.CommonBaseEvent event)
Logging method. |
void |
log(org.eclipse.hyades.logging.events.cbe.CommonBaseEvent event,
short level)
Deprecated. Set the severity on the Common Base Event and use the log(CommonBaseEvent event) API. |
void |
setComponents(IComponent[] newComponents)
Method sets the list of components this component manages. |
void |
setConfiguration(org.w3c.dom.Element newConfiguration)
Sets the config. |
void |
setContextConfiguration(org.w3c.dom.Element newConfiguration)
Sets the context config. |
void |
setDescription(java.lang.String newDescription)
Method sets the description of this component |
void |
setDisabled(boolean disabled)
Set whether this component is disabled or not |
void |
setExecutableClassName(java.lang.String newExecutableClassName)
Method sets executable class name |
void |
setImplemenationCreationDate(java.lang.String newImplementationCreationDate)
Method sets implementation creation date |
void |
setImplementationVersion(java.lang.String newImplementationVersion)
Method sets the implementation version in the form of x.y.z where x is a major release level, which may have api changes y is a minor release level with no api changes z is an optional fix level with no api changes |
void |
setImplementationVersionDescription(java.lang.String newImplementationVersionDescription)
Method sets implementation version description |
void |
setLogger(IProcessUnit logger)
The logger will be set by the context during initialization. |
void |
setLoggingLevel(short newLevel)
Method sets logging level of the component |
void |
setName(java.lang.String newName)
Method sets name of the component |
void |
setParent(IComponent parent)
Components are arranged in a heirarchy. |
void |
setRole(java.lang.String newRole)
Method sets the role of the component |
void |
setRoleCreationDate(java.lang.String newCreationDate)
Method sets role creation time |
void |
setRoleVersion(java.lang.String newRoleVersion)
Method sets role version |
void |
setRoleVersionDescription(java.lang.String newRoleVersionDescription)
Method sets the version specific role description |
void |
setStopping(boolean stopping)
Set the stopping state of the component. |
void |
setUniqueID(java.lang.String newUniqueID)
Method sets the uniqueID of this component instance |
void |
start()
Method start. |
void |
stop()
Method stop. |
void |
stop(int toStop)
|
void |
trace(java.lang.String msgKey,
java.lang.String sub)
Tracing method with one substitution variable. |
void |
trace(java.lang.String msgKey,
java.lang.String sub1,
java.lang.String sub2)
Tracing method with two substitution variables. |
void |
trace(java.lang.String msgKey,
java.lang.String sub1,
java.lang.String sub2,
java.lang.String sub3)
Tracing method with three substitution variables. |
void |
update()
Set Component instance level properties based on the component configuration Element. |
void |
update(org.w3c.dom.Element config)
Method update. |
protected void |
updateConfigurationAttribute(java.lang.String attrName,
java.lang.String attrValue)
Update an attribute in the configuration element |
protected void |
updateContextConfigurationAttribute(java.lang.String attrName,
java.lang.String attrValue)
Update an attribute in the context configuration element |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected IProcessUnit logger
protected Status status
protected boolean stopping
| Constructor Detail |
public Component()
| Method Detail |
public boolean init()
init in interface IComponentIComponent.init()public void start()
IComponent
start in interface IComponentIComponent.start()public void stop(int toStop)
org.eclipse.hyades.logging.adapter.IComponent#stop(int)public void stop()
IComponent
stop in interface IComponentIComponent.stop()
protected void updateConfigurationAttribute(java.lang.String attrName,
java.lang.String attrValue)
attrName - name of attributeattrValue - value of the attribute
protected void updateContextConfigurationAttribute(java.lang.String attrName,
java.lang.String attrValue)
attrName - attrValue -
public void update(org.w3c.dom.Element config)
throws AdapterInvalidConfig
IComponent
update in interface IComponentconfig - - configuration DOM element
AdapterInvalidConfig - if the configuration is invalid or cannot be processed.IComponent.update(Element)
public void update()
throws AdapterInvalidConfig
update in interface IComponentAdapterInvalidConfig - if the configuration is invalid or cannot be processed.IComponent.update()public org.w3c.dom.Element getContextConfiguration()
IComponent
getContextConfiguration in interface IComponentIComponent.getContextConfiguration()public void setContextConfiguration(org.w3c.dom.Element newConfiguration)
setContextConfiguration in interface IComponentIComponent.setContextConfiguration(Element)public org.w3c.dom.Element getConfiguration()
IComponent
getConfiguration in interface IComponentIComponent.getConfiguration()public void setConfiguration(org.w3c.dom.Element newConfiguration)
setConfiguration in interface IComponentpublic IProcessUnit getLogger()
IComponent
getLogger in interface IComponentIComponent.getLogger()public void setLogger(IProcessUnit logger)
IComponent
setLogger in interface IComponentlogger - the logger for this component to useIComponent.setLogger(IProcessUnit)public org.eclipse.hyades.logging.events.cbe.EventFactory getEventFactory()
public short getLoggingLevel()
IComponent
getLoggingLevel in interface IComponentIComponent.getName()public void setLoggingLevel(short newLevel)
IComponent
setLoggingLevel in interface IComponentnewLevel - - new logging levelorg.eclipse.hyades.logging.adapter.IComponent#setName(short)public java.lang.String getName()
IComponent
getName in interface IComponentIComponent.getName()public void setName(java.lang.String newName)
IComponent
setName in interface IComponentIComponent.setName(java.lang.String)public java.lang.String getRole()
IComponent
getRole in interface IComponentIComponent.getRole()public void setRole(java.lang.String newRole)
IComponent
setRole in interface IComponentIComponent.setRole(java.lang.String)public java.lang.String getDescription()
IComponent
getDescription in interface IComponentIComponent.getDescription()public void setDescription(java.lang.String newDescription)
IComponent
setDescription in interface IComponentIComponent.setDescription(java.lang.String)public java.lang.String getUniqueID()
IComponent
getUniqueID in interface IComponentIComponent.getUniqueID()public void setUniqueID(java.lang.String newUniqueID)
IComponent
setUniqueID in interface IComponentIComponent.setUniqueID(java.lang.String)public java.lang.String getExecutableClassName()
IComponent
getExecutableClassName in interface IComponentIComponent.getExecutableClassName()public void setExecutableClassName(java.lang.String newExecutableClassName)
IComponent
setExecutableClassName in interface IComponentIComponent.setExecutableClassName(java.lang.String)public java.lang.String getRoleVersion()
IComponent
getRoleVersion in interface IComponentIComponent.getRoleVersion()public void setRoleVersion(java.lang.String newRoleVersion)
IComponent
setRoleVersion in interface IComponentIComponent.setRoleVersion(java.lang.String)public java.lang.String getRoleCreationDate()
IComponent
getRoleCreationDate in interface IComponentIComponent.getRoleCreationDate()public void setRoleCreationDate(java.lang.String newCreationDate)
IComponent
setRoleCreationDate in interface IComponentIComponent.setRoleCreationDate(java.lang.String)public java.lang.String getRoleVersionDescription()
IComponent
getRoleVersionDescription in interface IComponentIComponent.getRoleVersionDescription()public void setRoleVersionDescription(java.lang.String newRoleVersionDescription)
IComponent
setRoleVersionDescription in interface IComponentIComponent.setRoleVersionDescription(java.lang.String)public java.lang.String getImplementationVersion()
IComponent
getImplementationVersion in interface IComponentIComponent.getImplementationVersion()public void setImplementationVersion(java.lang.String newImplementationVersion)
IComponent
setImplementationVersion in interface IComponentIComponent.setImplementationVersion(java.lang.String)public java.lang.String getImplementationCreationDate()
IComponent
getImplementationCreationDate in interface IComponentIComponent.getImplementationCreationDate()public void setImplemenationCreationDate(java.lang.String newImplementationCreationDate)
IComponent
setImplemenationCreationDate in interface IComponentIComponent.setImplemenationCreationDate(java.lang.String)public java.lang.String getImplementationVersionDescription()
IComponent
getImplementationVersionDescription in interface IComponentIComponent.getImplementationVersionDescription()public void setImplementationVersionDescription(java.lang.String newImplementationVersionDescription)
IComponent
setImplementationVersionDescription in interface IComponentIComponent.setImplementationVersionDescription(java.lang.String)public IComponent[] getComponents()
IComponent
getComponents in interface IComponentIComponent.getComponents()public void setComponents(IComponent[] newComponents)
IComponent
setComponents in interface IComponentIComponent.setComponents(org.eclipse.hyades.logging.adapter.IComponent[])public void clean()
public void trace(java.lang.String msgKey,
java.lang.String sub)
The message with the specified resource key and substutution value is logged in a Common Base Event with severity 5.
msgKey - resource key for trace message string.sub - substitution value - null for no value
public void trace(java.lang.String msgKey,
java.lang.String sub1,
java.lang.String sub2)
The message with the specified resource key and substutution values is logged in a Common Base Event with severity 5.
msgKey - resource key for trace message string.sub1 - first substitution valuesub2 - second substitution value
public void trace(java.lang.String msgKey,
java.lang.String sub1,
java.lang.String sub2,
java.lang.String sub3)
The message with the specified resource key and substutution values is logged in a Common Base Event with severity 5.
msgKey - resource key for trace message string.sub1 - first substitution valuesub2 - second substitution valuesub3 - third substitution valuepublic void log(org.eclipse.hyades.logging.events.cbe.CommonBaseEvent event)
The Common Base Event is logged based on its severity.
log in interface IComponentevent - The Common Base Event to be logged.
public void log(org.eclipse.hyades.logging.events.cbe.CommonBaseEvent event,
short level)
log(CommonBaseEvent event) API.
log in interface IComponentevent - The Common Base Event to be logged.level - The severity of the Common Base Event to be logged.public void setParent(IComponent parent)
IComponent
setParent in interface IComponentparent - the parent component in the hierarchyIComponent.setParent(org.eclipse.hyades.logging.adapter.IComponent)public IComponent getParent()
IComponent
getParent in interface IComponentIComponent.getParent()public boolean isStopping()
public void setStopping(boolean stopping)
stopping - - true for stopping, false for not stoppingpublic int getItemsProcessedCount()
public void incrementItemsProcessedCount()
public void incrementItemsProcessedCount(int n)
n - Amount to increment the count by.public Status getComponentStatus()
public boolean isDisabled()
public void setDisabled(boolean disabled)
disabled - boolean
|
TPTP 4.4.0 Monitoring Tools Project Public API Specification |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||