public class Tool4Throwable
extends java.lang.Object
Tool4Throwable
the class creates a log string for exception log with stack trace.Constructor and Description |
---|
Tool4Throwable()
The constructor
Tool4Throwable creates a new instance(object) of the class. |
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
getCallStackOut(java.lang.Throwable error)
The method
getCallStackOut creates the log string with stack trace of an exception. |
static java.lang.String |
getMessage4Log(java.lang.String message)
The method
getMessage4Log creates the log string with a given message. |
static java.lang.String |
saveThrowableFile(java.lang.String path,
java.lang.String errMess)
The method
saveThrowableFile saves an exception file to the file system. |
public Tool4Throwable()
Tool4Throwable
creates a new instance(object) of the class.public static java.lang.String getCallStackOut(java.lang.Throwable error)
getCallStackOut
creates the log string with stack trace of an exception.error
- the throwable/exception.public static java.lang.String getMessage4Log(java.lang.String message)
getMessage4Log
creates the log string with a given message.message
- the message.public static java.lang.String saveThrowableFile(java.lang.String path, java.lang.String errMess)
saveThrowableFile
saves an exception file to the file system.path
- the system path to write to.errMess
- the error message (e.g. the stack trace).