public final class Log extends Object implements Serializable
Modifier and Type | Field and Description |
---|---|
static int |
LEVEL_DEBUG
Constant for DEBUG log level.
|
static int |
LEVEL_ERROR
Constant for ERROR log level.
|
static int |
LEVEL_INFO
Constant for INFO log level.
|
static int |
LEVEL_WARNING
Constant for WARNING log level.
|
Modifier | Constructor and Description |
---|---|
protected |
Log()
Creates new instance.
|
|
Log(long id,
Long modelInstanceId,
Date date,
int level,
String description)
Creates new instance.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
Date |
getDate()
Returns the log timestamp.
|
String |
getDescription()
Returns the log description.
|
long |
getId()
Returns the id.
|
int |
getLevel()
Returns the log level.
|
static String |
getLevelName(int level) |
String |
getLevelText()
Returns the log level as a formatted text in the format:
|
Long |
getModelInstanceId()
Returns the model instance id.
|
int |
hashCode() |
public static final int LEVEL_DEBUG
public static final int LEVEL_INFO
public static final int LEVEL_WARNING
public static final int LEVEL_ERROR
protected Log()
public Log(long id, Long modelInstanceId, Date date, int level, String description)
id
- modelInstanceId
- date
- level
- description
- NullPointerException
- if timestamp
is nullpublic long getId()
public Long getModelInstanceId()
public Date getDate()
public String getDescription()
public int getLevel()
public static String getLevelName(int level)
level
- null
if the level does not
correspond to a known levelpublic String getLevelText()
level (level name).
Copyright © 2007-2020 Whitestein Technologies. All Rights Reserved.