public class LogUtil extends Object
Constructor and Description |
---|
LogUtil() |
Modifier and Type | Method and Description |
---|---|
static String |
fromLevel(int level)
* Converts from a numeric log severity level to a string.
|
static String |
fromLevel(int level,
int length)
* Converts from a numeric log severity level to a left justified * string
of at least the given length.
|
static int |
toLevel(String level,
int def)
* Converts a string representing a log severity level to an int.
|
public static String fromLevel(int level)
level
- is the log severity level.public static String fromLevel(int level, int length)
level
- is the log severity level. *length
- the minimum length of the resulting string.public static int toLevel(String level, int def)
level
- The string to convert. *def
- Default value to use if the string is not * recognized as a
log level. *Copyright © 2016. All rights reserved.