org.enhydra.shark.api.internal.working
Interface CallbackUtilities


public interface CallbackUtilities

CallbackUtilities interface contains properties used for configuration in Shark.

Version:
0.2
Author:
Sasa Bojanic, Vladimir Puskas

Method Summary
 void debug(WMSessionHandle shandle, java.lang.String msg)
          Log a message object with the DEBUG level.
 void debug(WMSessionHandle shandle, java.lang.String msg, java.lang.Exception ex)
          Log a message object with the DEBUG level.
 void debug(WMSessionHandle shandle, java.lang.String channel, java.lang.String msg)
          Log a message object with the DEBUG level.
 void debug(WMSessionHandle shandle, java.lang.String channel, java.lang.String msg, java.lang.Exception ex)
          Log a message object with the DEBUG level.
 void error(WMSessionHandle shandle, java.lang.String msg)
          Log a message object with the ERROR Level.
 void error(WMSessionHandle shandle, java.lang.String msg, java.lang.Exception ex)
          Log a message object with the ERROR Level.
 void error(WMSessionHandle shandle, java.lang.String channel, java.lang.String msg)
          Log a message object with the ERROR Level.
 void error(WMSessionHandle shandle, java.lang.String channel, java.lang.String msg, java.lang.Exception ex)
          Log a message object with the ERROR Level.
 java.util.Properties getProperties()
          Returns all properties used for Shark configuration.
 java.lang.String getProperty(java.lang.String propertyName)
          Returns value of property propertyName used for Shark configuration.
 java.lang.String getProperty(java.lang.String propertyName, java.lang.String defaultValue)
          Returns value of property propertyName used for Shark configuration.
 java.lang.String getUserId(WMSessionHandle shandle)
          Method to extract User Id from WMSessionHandle
 void info(WMSessionHandle shandle, java.lang.String msg)
          Log a message object with the INFO Level.
 void info(WMSessionHandle shandle, java.lang.String msg, java.lang.Exception ex)
          Log a message object with the INFO Level.
 void info(WMSessionHandle shandle, java.lang.String channel, java.lang.String msg)
          Log a message object with the INFO Level.
 void info(WMSessionHandle shandle, java.lang.String channel, java.lang.String msg, java.lang.Exception ex)
          Log a message object with the INFO Level.
 boolean isEnabled(WMSessionHandle shandle, int level)
          Returns if the specified logging level is enabled for the default channel.
 boolean isEnabled(WMSessionHandle shandle, java.lang.String channel, int level)
          Returns if the specified logging level is enabled for the specified channel.
 void methodEnd(WMSessionHandle shandle, long stamp, java.lang.String location, java.lang.Object o)
           
 void methodEnd(WMSessionHandle shandle, long stamp, java.lang.String location, java.lang.Object o, java.lang.String channel)
           
 long methodStart(WMSessionHandle shandle, java.lang.String location)
           
 void setProperties(java.util.Properties props)
          Sets properties for Shark configuration.
 void warn(WMSessionHandle shandle, java.lang.String msg)
          Log a message object with the WARN Level.
 void warn(WMSessionHandle shandle, java.lang.String msg, java.lang.Exception ex)
          Log a message object with the WARN Level.
 void warn(WMSessionHandle shandle, java.lang.String channel, java.lang.String msg)
          Log a message object with the WARN Level.
 void warn(WMSessionHandle shandle, java.lang.String channel, java.lang.String msg, java.lang.Exception ex)
          Log a message object with the WARN Level.
 

Method Detail

getProperty

java.lang.String getProperty(java.lang.String propertyName)
Returns value of property propertyName used for Shark configuration.

Parameters:
propertyName - property name.
Returns:
Value of property propertyName.

getProperty

java.lang.String getProperty(java.lang.String propertyName,
                             java.lang.String defaultValue)
Returns value of property propertyName used for Shark configuration. If doesn't exist the default value is returned.

Parameters:
propertyName - property name.
defaultValue - default property value.
Returns:
Value of property propertyName or default value.

getProperties

java.util.Properties getProperties()
Returns all properties used for Shark configuration.

Returns:
Properties object.

setProperties

void setProperties(java.util.Properties props)
Sets properties for Shark configuration.

Parameters:
props - Properties object.

isEnabled

boolean isEnabled(WMSessionHandle shandle,
                  int level)
                  throws java.lang.Exception
Returns if the specified logging level is enabled for the default channel.

Throws:
java.lang.Exception

isEnabled

boolean isEnabled(WMSessionHandle shandle,
                  java.lang.String channel,
                  int level)
                  throws java.lang.Exception
Returns if the specified logging level is enabled for the specified channel.

Throws:
java.lang.Exception

error

void error(WMSessionHandle shandle,
           java.lang.String msg)
Log a message object with the ERROR Level.

Parameters:
msg - the message to log.

error

void error(WMSessionHandle shandle,
           java.lang.String msg,
           java.lang.Exception ex)
Log a message object with the ERROR Level.

Parameters:
msg - the message to log.
ex - the exception to log, including its stack trace.

error

void error(WMSessionHandle shandle,
           java.lang.String channel,
           java.lang.String msg)
Log a message object with the ERROR Level.

Parameters:
channel - the log channel to be used for logging.
msg - the message to log.

error

void error(WMSessionHandle shandle,
           java.lang.String channel,
           java.lang.String msg,
           java.lang.Exception ex)
Log a message object with the ERROR Level.

Parameters:
channel - the log channel to be used for logging.
msg - the message to log.
ex - the exception to log, including its stack trace.

warn

void warn(WMSessionHandle shandle,
          java.lang.String msg)
Log a message object with the WARN Level.

Parameters:
msg - the message to log.

warn

void warn(WMSessionHandle shandle,
          java.lang.String msg,
          java.lang.Exception ex)
Log a message object with the WARN Level.

Parameters:
msg - the message to log.
ex - the exception to log, including its stack trace.

warn

void warn(WMSessionHandle shandle,
          java.lang.String channel,
          java.lang.String msg)
Log a message object with the WARN Level.

Parameters:
channel - the log channel to be used for logging.
msg - the message to log.

warn

void warn(WMSessionHandle shandle,
          java.lang.String channel,
          java.lang.String msg,
          java.lang.Exception ex)
Log a message object with the WARN Level.

Parameters:
channel - the log channel to be used for logging.
msg - the message to log.
ex - the exception to log, including its stack trace.

info

void info(WMSessionHandle shandle,
          java.lang.String msg)
Log a message object with the INFO Level.

Parameters:
msg - the message to log.

info

void info(WMSessionHandle shandle,
          java.lang.String msg,
          java.lang.Exception ex)
Log a message object with the INFO Level.

Parameters:
msg - the message to log.
ex - the exception to log, including its stack trace.

info

void info(WMSessionHandle shandle,
          java.lang.String channel,
          java.lang.String msg)
Log a message object with the INFO Level.

Parameters:
channel - the log channel to be used for logging.
msg - the message to log.

info

void info(WMSessionHandle shandle,
          java.lang.String channel,
          java.lang.String msg,
          java.lang.Exception ex)
Log a message object with the INFO Level.

Parameters:
channel - the log channel to be used for logging.
msg - the message to log.
ex - the exception to log, including its stack trace.

debug

void debug(WMSessionHandle shandle,
           java.lang.String msg)
Log a message object with the DEBUG level.

Parameters:
msg - the message to log.

debug

void debug(WMSessionHandle shandle,
           java.lang.String msg,
           java.lang.Exception ex)
Log a message object with the DEBUG level.

Parameters:
msg - the message to log.
ex - the exception to log, including its stack trace.

debug

void debug(WMSessionHandle shandle,
           java.lang.String channel,
           java.lang.String msg)
Log a message object with the DEBUG level.

Parameters:
channel - the log channel to be used for logging.
msg - the message to log.

debug

void debug(WMSessionHandle shandle,
           java.lang.String channel,
           java.lang.String msg,
           java.lang.Exception ex)
Log a message object with the DEBUG level.

Parameters:
channel - the log channel to be used for logging.
msg - the message to log.
ex - the exception to log, including its stack trace.

getUserId

java.lang.String getUserId(WMSessionHandle shandle)
Method to extract User Id from WMSessionHandle

Parameters:
shandle -
Returns:
User Id

methodStart

long methodStart(WMSessionHandle shandle,
                 java.lang.String location)

methodEnd

void methodEnd(WMSessionHandle shandle,
               long stamp,
               java.lang.String location,
               java.lang.Object o)

methodEnd

void methodEnd(WMSessionHandle shandle,
               long stamp,
               java.lang.String location,
               java.lang.Object o,
               java.lang.String channel)