|
SAP NetWeaver 7.20 (SP01) Composition Environment | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.sap.tc.logging.SimpleLogger
public class SimpleLogger
Exposes main functionality of SAP Logging API by the means of several, easy to use methods
Constructor Summary | |
---|---|
SimpleLogger()
|
Method Summary | |
---|---|
static boolean |
isWritable(int severity,
LogController lc)
Determines if a message with provided severity will pass severity check for Log Controller and will be written |
static LogRecord |
log(int severity,
Category category,
Location location,
String messageID,
String message)
Issues a log message through a Category. |
static LogRecord |
log(int severity,
Category category,
Location location,
String messageID,
String message,
Object... args)
Issues a log message through a Category. |
static LogRecord |
log(int severity,
Category category,
Location location,
String dcName,
String csnComponent,
String messageID,
String message,
Object... args)
Issues a log message through a Category. |
static LogRecord |
trace(int severity,
Location location,
String message)
Issues a trace message through a Location |
static LogRecord |
trace(int severity,
Location location,
String message,
Object... args)
Issues a trace message through a Location. |
static LogRecord |
trace(int severity,
Location location,
String messageID,
String message)
Issues a trace message through a Location. |
static LogRecord |
trace(int severity,
Location location,
String messageID,
String message,
Object... args)
Issues a trace message through a Location. |
static LogRecord |
trace(int severity,
Location location,
String dcName,
String csnComponent,
String messageID,
String message,
Throwable exc,
Object... args)
Issues a trace message through a Location. |
static LogRecord |
traceThrowable(int severity,
Location location,
String messageID,
String message,
Throwable exc)
Issues a trace message through a Location. |
static LogRecord |
traceThrowable(int severity,
Location location,
String message,
Throwable exc)
Issues a trace message through a Location. traceThrowable methods are designed to format and write exception stacktraces. |
static LogRecord |
traceThrowable(int severity,
Location location,
Throwable exc,
String messageID,
String message,
Object... args)
Issues a trace message through a Location. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SimpleLogger()
Method Detail |
---|
public static boolean isWritable(int severity, LogController lc)
severity
- Severity to check againstlc
- Log Controller to chack against
public static LogRecord trace(int severity, Location location, String message)
severity
- severity of the trace message that is issuedlocation
- Location where the message will be dispatched to and from where (if severity check is passed) it will be issued.message
- the message text itself
public static LogRecord trace(int severity, Location location, String messageID, String message)
severity
- severity of the trace message that is issuedlocation
- Location where the message will be dispatched to and from where (if severity check is passed) it will be issued.messageID
- messageID to be assigned to this message. MessageID format is [prefix]-[range][number] (e.g. ASJ-jndi-000135)message
- the message text itself
public static LogRecord trace(int severity, Location location, String message, Object... args)
severity
- severity of the trace message that is issuedlocation
- Location where the message will be dispatched to and from where (if severity check is passed) it will be issued.message
- the message text itselfargs
- values to be placed in the text message. Each of the message placeholders {0}, {1} will be replaced with args[0], args[1], etc.
public static LogRecord trace(int severity, Location location, String messageID, String message, Object... args)
severity
- severity of the trace message that is issuedlocation
- Location where the message will be dispatched to and from where (if severity check is passed) it will be issued.messageID
- messageID to be assigned to this message. MessageID format is [prefix]-[range][number] (e.g. ASJ-jndi-000135)message
- the message text itselfargs
- values to be placed in the text message. Each of the message placeholders {0}, {1} will be replaced with args[0], args[1], etc.
public static LogRecord trace(int severity, Location location, String dcName, String csnComponent, String messageID, String message, Throwable exc, Object... args)
severity
- severity of the trace message that is issuedlocation
- Location where the message will be dispatched to and from where (if severity check is passed) it will be issued.dcName
- DC name to be written in the trace entrycsnComponent
- CSN Component to be written in the trace entrymessageID
- messageID to be assigned to this message. MessageID format is [prefix]-[range][number] (e.g. ASJ-jndi-000135)message
- the message text itselfexc
- If not null, the exception stacktrace is formatted and appended at the end of the trace record as a message parameterargs
- values to be placed in the text message. Each of the message placeholders {0}, {1} will be replaced with args[0], args[1], etc.
public static LogRecord traceThrowable(int severity, Location location, String message, Throwable exc)
severity
- Severity of the trace message that is issuedlocation
- Location where the message will be dispatched to and from where (if severity check is passed) it will be issued.message
- The message text itself. It should be different from exc.getMessage()exc
- The exception stacktrace is formatted and appended at the end of the trace record as a message parameter
public static LogRecord traceThrowable(int severity, Location location, String messageID, String message, Throwable exc)
severity
- Severity of the trace message that is issuedlocation
- Location where the message will be dispatched to and from where (if severity check is passed) it will be issued.messageID
- messageID to be assigned to this message. MessageID format is [prefix]-[range][number] (e.g. ASJ-jndi-000135)message
- The message text itself. It should be different from exc.getMessage()exc
- The exception stacktrace is formatted and appended at the end of the trace record as a message parameter
public static LogRecord traceThrowable(int severity, Location location, Throwable exc, String messageID, String message, Object... args)
severity
- Severity of the trace message that is issuedlocation
- Location where the message will be dispatched to and from where (if severity check is passed) it will be issued.exc
- The exception stacktrace is formatted and appended at the end of the trace record as a message parametermessageID
- messageID to be assigned to this message. MessageID format is [prefix]-[range][number] (e.g. ASJ-jndi-000135)message
- The message text itself. It should be different from exc.getMessage()args
- values to be placed in the text message. Each of the message placeholders {0}, {1} will be replaced with args[0], args[1], etc.
public static LogRecord log(int severity, Category category, Location location, String messageID, String message, Object... args)
severity
- severity of the trace message that is issuedCategory
- Category where the message will be dispatched to and from where (if severity check is passed) it will be issued.location
- If a message has been produced by Category,
it will also be dispatched to the Location so that it will go to traces as well.messageID
- messageID to be assigned to this message. MessageID format is [prefix]-[range][number] (e.g. ASJ-jndi-000135)message
- the message text itselfargs
- values to be placed at the end of the log entry as parameters.
Each of the message placeholders {0}, {1} will correspond to args[0], args[1], etc.
These placeholders will not be replaced in the plain text entry but will be replaced if logs are viewed with Log Viewer.
public static LogRecord log(int severity, Category category, Location location, String dcName, String csnComponent, String messageID, String message, Object... args)
severity
- Severity of the trace message that is issuedCategory
- Category where the message will be dispatched to and from where (if severity check is passed) it will be issued.location
- If a message has been produced by Category,
it will also be dispatched to the Location so that it will go to traces as well.dcName
- DC name to be written in the log entry. If dcName and csnComponent are null they are evaluated during runtime.csnComponent
- CSN Component to be written in the log entry. If dcName and csnComponent are null they are evaluated during runtime.messageID
- Message ID to be assigned to this message. MessageID format is [prefix]-[range][number] (e.g. ASJ-jndi-000135)message
- The message text itselfargs
- Values to be placed at the end of the log entry as parameters.
Each of the message placeholders {0}, {1} will correspond to args[0], args[1], etc.
These placeholders will not be replaced in the plain text entry but will be replaced if logs are viewed with Log Viewer.
public static LogRecord log(int severity, Category category, Location location, String messageID, String message)
severity
- severity of the trace message that is issuedCategory
- Category where the message will be dispatched to and from where (if severity check is passed) it will be issued.location
- If a message has been produced by Category,
it will also be dispatched to the Location so that it will go to traces as well.messageID
- messageID to be assigned to this message. MessageID format is [prefix]-[range][number] (e.g. ASJ-jndi-000135)message
- the message text itself
Access Rights |
---|
SC | DC |
---|---|
[sap.com] FRAMEWORK
|
[sap.com] tc/ddic/ddicruntime
|
[sap.com] ENGINEAPI
|
[sap.com] tc/logging
|
[sap.com] ENGFACADE
|
[sap.com] tc/bl/logging/api
|
[sap.com] CORE-TOOLS
|
[sap.com] com.sap.engine.client.lib
|
[sap.com] BRMS-FACADE
|
[sap.com] tc/brms/facade
|
|
SAP NetWeaver 7.20 (SP01) Composition Environment | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |