public class DiagnosticConfig
extends java.lang.Object
DiagnosticConfig
class is used to store DiagnosticProvider
scoped StateCollectionSpec
information. This information can include wild-cards
and its purpose is to allow a DiagnosticProvider to enable specific tracing/debug type operations.
The system-wide StateCollectionSpec
comes in as a string which can look something
like: *=0;ConnectionManager:profile-datasource.*=1;WebContainer:transport.*=1
This is explained further in DiagnosticConfigHome
. Classes that
implement the AlertAgent interface may retrieve all necessary DiagnosticConfig
objects and hold them. The DiagnosticConfigHome
will still automatically
update them as needed.
DiagnosticConfigHome
Modifier and Type | Method and Description |
---|---|
boolean |
deRegisterCallback(DiagnosticCollectionCallback aDiagnosticCollectionCallback)
deRegisters a class implementing the DiagnosticCollectionCallback interface, allows that class to
be removed from the list (ie: if it were going to go out of service)
|
boolean |
isAnythingEnabled()
determines if the StateCollectionSpec contains any collection specific to this Diagnostic
Provider
|
boolean |
isEnabled(java.lang.String aTestDiag)
determines if a particular
diagnostic is enabled. |
void |
registerCallback(DiagnosticCollectionCallback aDiagnosticCollectionCallback)
registers a class implementing the DiagnosticCollectionCallback interface to be notified
on any changes to the StateCollectionSpec
|
public void registerCallback(DiagnosticCollectionCallback aDiagnosticCollectionCallback)
aDiagnosticCollectionCallback
- object to be notified with data when
the state collection spec changespublic boolean deRegisterCallback(DiagnosticCollectionCallback aDiagnosticCollectionCallback)
aDiagnosticCollectionCallback
- object to be removed from notification listpublic boolean isEnabled(java.lang.String aTestDiag)
diagnostic
is enabled. This method is optimized for
heavy usage.aTestDiag
- Diagnostic for which the DiagnosticProvider caller is
requesting enablement information.public boolean isAnythingEnabled()