fm.liveswitch.LogEvent Class Reference

Details about a specific log event. More...

Public Member Functions

fm.liveswitch.LogContext getContext ()
 Gets the event context. More...
 
java.lang.Exception getException ()
 Gets the event exception, if one exists. More...
 
fm.liveswitch.LogLevel getLevel ()
 Gets the event level. More...
 
fm.liveswitch.LogLevel getLogLevel ()
 Gets the level of this log event. More...
 
String getMessage ()
 Gets the event message. More...
 
String getScope ()
 Gets the event scope. More...
 
String getTag ()
 Gets the event tag. More...
 
long getThreadId ()
 Gets the ID of the thread generating the event. More...
 
java.util.Date getTimestamp ()
 Gets the event timestamp. More...
 
 LogEvent (java.util.Date timestamp, String tag, String scope, fm.liveswitch.LogLevel level, fm.liveswitch.LogContext context, String message, java.lang.Exception exception, long threadId)
 Initializes a new instance of the fm.liveswitch.LogEvent class. More...
 
void setContext (fm.liveswitch.LogContext value)
 Sets the event context. More...
 
void setException (java.lang.Exception value)
 Sets the event exception, if one exists. More...
 
void setLevel (fm.liveswitch.LogLevel value)
 Sets the event level. More...
 
void setMessage (String value)
 Sets the event message. More...
 
void setScope (String value)
 Sets the event scope. More...
 
void setTag (String value)
 Sets the event tag. More...
 
void setThreadId (long value)
 Sets the ID of the thread generating the event. More...
 
void setTimestamp (java.util.Date value)
 Sets the event timestamp. More...
 
String toJson ()
 Serializes this instance to JSON. More...
 
String toString ()
 

Static Public Member Functions

static fm.liveswitch.LogEvent fromJson (String logEventJson)
 Deserializes a log event from JSON. More...
 
static String toJson (final fm.liveswitch.LogEvent logEvent)
 Serializes a log event to JSON. More...
 

Detailed Description

Details about a specific log event.

Constructor & Destructor Documentation

◆ LogEvent()

fm.liveswitch.LogEvent.LogEvent ( java.util.Date  timestamp,
String  tag,
String  scope,
fm.liveswitch.LogLevel  level,
fm.liveswitch.LogContext  context,
String  message,
java.lang.Exception  exception,
long  threadId 
)

Initializes a new instance of the fm.liveswitch.LogEvent class.

Parameters
timestampThe event timestamp.
tagThe event tag.
scopeThe event scope.
levelThe event level.
contextThe event context.
messageThe event message.
exceptionThe event exception, if one exists.
threadIdThe ID of the thread generating the event.

Member Function Documentation

◆ fromJson()

static fm.liveswitch.LogEvent fm.liveswitch.LogEvent.fromJson ( String  logEventJson)
static

Deserializes a log event from JSON.

Parameters
logEventJsonThe log event JSON.

◆ getContext()

fm.liveswitch.LogContext fm.liveswitch.LogEvent.getContext ( )

Gets the event context.

◆ getException()

java.lang.Exception fm.liveswitch.LogEvent.getException ( )

Gets the event exception, if one exists.

◆ getLevel()

fm.liveswitch.LogLevel fm.liveswitch.LogEvent.getLevel ( )

Gets the event level.

◆ getLogLevel()

fm.liveswitch.LogLevel fm.liveswitch.LogEvent.getLogLevel ( )

Gets the level of this log event.

Alias for fm.liveswitch.LogEvent#getLevel.

◆ getMessage()

String fm.liveswitch.LogEvent.getMessage ( )

Gets the event message.

◆ getScope()

String fm.liveswitch.LogEvent.getScope ( )

Gets the event scope.

◆ getTag()

String fm.liveswitch.LogEvent.getTag ( )

Gets the event tag.

◆ getThreadId()

long fm.liveswitch.LogEvent.getThreadId ( )

Gets the ID of the thread generating the event.

◆ getTimestamp()

java.util.Date fm.liveswitch.LogEvent.getTimestamp ( )

Gets the event timestamp.

◆ setContext()

void fm.liveswitch.LogEvent.setContext ( fm.liveswitch.LogContext  value)

Sets the event context.

◆ setException()

void fm.liveswitch.LogEvent.setException ( java.lang.Exception  value)

Sets the event exception, if one exists.

◆ setLevel()

void fm.liveswitch.LogEvent.setLevel ( fm.liveswitch.LogLevel  value)

Sets the event level.

◆ setMessage()

void fm.liveswitch.LogEvent.setMessage ( String  value)

Sets the event message.

◆ setScope()

void fm.liveswitch.LogEvent.setScope ( String  value)

Sets the event scope.

◆ setTag()

void fm.liveswitch.LogEvent.setTag ( String  value)

Sets the event tag.

◆ setThreadId()

void fm.liveswitch.LogEvent.setThreadId ( long  value)

Sets the ID of the thread generating the event.

◆ setTimestamp()

void fm.liveswitch.LogEvent.setTimestamp ( java.util.Date  value)

Sets the event timestamp.

◆ toJson() [1/2]

String fm.liveswitch.LogEvent.toJson ( )

Serializes this instance to JSON.

◆ toJson() [2/2]

static String fm.liveswitch.LogEvent.toJson ( final fm.liveswitch.LogEvent  logEvent)
static

Serializes a log event to JSON.

Parameters
logEventThe log event.

◆ toString()

String fm.liveswitch.LogEvent.toString ( )