A Logger class
Method | Description |
---|---|
debug |
Creates a new debug-level entry in the log with the given message, details and calling component. |
error |
Creates a new error-level entry in the log with the given message, details and calling component. |
fatal |
Creates a new fatal-level entry in the log with the given message, details and calling component. |
getLevel |
Returns the log level currently effective for the given component. If no component is given or when no level has been configured for a given component, the log level for the default component of this logger is returned. |
info |
Creates a new info-level entry in the log with the given message, details and calling component. |
isLoggable |
Checks whether logging is enabled for the given log level, depending on the currently effective log level for the given component. If no component is given, the default component of this logger will be taken into account. |
setLevel |
Defines the maximum Note: Setting a global default log level has no impact on already defined component log levels. They always override the global default log level. |
trace |
Creates a new trace-level entry in the log with the given message, details and calling component. |
warning |
Creates a new warning-level entry in the log with the given message, details and calling component. |
Creates a new debug-level entry in the log with the given message, details and calling component.
Param | Type | DefaultValue | Description |
---|---|---|---|
sMessage | string |
Message text to display |
|
sDetails | string | '' |
Details about the message, might be omitted |
sComponent | string | '' |
Name of the component that produced the log entry |
fnSupportInfo | function |
Callback that returns an additional support object to be logged in support mode. This function is only called if support info mode is turned on with |
Creates a new error-level entry in the log with the given message, details and calling component.
Param | Type | DefaultValue | Description |
---|---|---|---|
sMessage | string |
Message text to display |
|
sDetails | string | '' |
Details about the message, might be omitted |
sComponent | string | '' |
Name of the component that produced the log entry |
fnSupportInfo | function |
Callback that returns an additional support object to be logged in support mode. This function is only called if support info mode is turned on with |
Creates a new fatal-level entry in the log with the given message, details and calling component.
Param | Type | DefaultValue | Description |
---|---|---|---|
sMessage | string |
Message text to display |
|
sDetails | string | '' |
Details about the message, might be omitted |
sComponent | string | '' |
Name of the component that produced the log entry |
fnSupportInfo | function |
Callback that returns an additional support object to be logged in support mode. This function is only called if support info mode is turned on with |
Returns the log level currently effective for the given component. If no component is given or when no level has been configured for a given component, the log level for the default component of this logger is returned.
Param | Type | DefaultValue | Description |
---|---|---|---|
sComponent | string |
Name of the component to retrieve the log level for |
Creates a new info-level entry in the log with the given message, details and calling component.
Param | Type | DefaultValue | Description |
---|---|---|---|
sMessage | string |
Message text to display |
|
sDetails | string | '' |
Details about the message, might be omitted |
sComponent | string | '' |
Name of the component that produced the log entry |
fnSupportInfo | function |
Callback that returns an additional support object to be logged in support mode. This function is only called if support info mode is turned on with |
Checks whether logging is enabled for the given log level, depending on the currently effective log level for the given component.
If no component is given, the default component of this logger will be taken into account.
Param | Type | DefaultValue | Description |
---|---|---|---|
iLevel | int | Level.DEBUG |
The log level in question |
sComponent | string |
Name of the component to check the log level for |
Defines the maximum jQuery.sap.log.Level
of log entries that will be recorded. Log entries with a higher (less important) log level will be omitted from the log. When a component name is given, the log level will be configured for that component only, otherwise the log level for the default component of this logger is set. For the global logger, the global default level is set.
Note: Setting a global default log level has no impact on already defined component log levels. They always override the global default log level.
Param | Type | DefaultValue | Description |
---|---|---|---|
iLogLevel | jQuery.sap.log.Level |
The new log level |
|
sComponent | string |
The log component to set the log level for |
Creates a new trace-level entry in the log with the given message, details and calling component.
Param | Type | DefaultValue | Description |
---|---|---|---|
sMessage | string |
Message text to display |
|
sDetails | string | '' |
Details about the message, might be omitted |
sComponent | string | '' |
Name of the component that produced the log entry |
fnSupportInfo | function |
Callback that returns an additional support object to be logged in support mode. This function is only called if support info mode is turned on with |
Creates a new warning-level entry in the log with the given message, details and calling component.
Param | Type | DefaultValue | Description |
---|---|---|---|
sMessage | string |
Message text to display |
|
sDetails | string | '' |
Details about the message, might be omitted |
sComponent | string | '' |
Name of the component that produced the log entry |
fnSupportInfo | function |
Callback that returns an additional support object to be logged in support mode. This function is only called if support info mode is turned on with |