Class ErrorBean
- java.lang.Object
-
- no.priv.bang.modeling.modelstore.services.ErrorBean
-
public class ErrorBean extends Object
An immutable bean that is used to hold error messages logged when modelstore catches (and represses) exceptions.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Date
getDate()
Error time stampException
getException()
The exception that was caught and caused the error to be logged.String
getFileOrStream()
The File orInputStream
/OutputStream
object involved in the error.String
getMessage()
Human readable error message
-
-
-
Constructor Detail
-
ErrorBean
public ErrorBean(Date date, String message, Object fileOrStream, Exception exception)
Create an ErrorBean instances.- Parameters:
date
- the date and time when the error occurred, with millisecond accuracymessage
- a human readable message describing where in the code the exception occurredfileOrStream
- a string description of the File orInputStream
/OutputStream
object involved, or null if no such object was involvedexception
- the caught exception causing this error to be logged
-
-
Method Detail
-
getDate
public Date getDate()
Error time stamp- Returns:
- a
Date
object describing a date and time with millisecond accuracy
-
getMessage
public String getMessage()
Human readable error message- Returns:
- a
String
describing the error message
-
getFileOrStream
public String getFileOrStream()
The File orInputStream
/OutputStream
object involved in the error.- Returns:
- a
String
description of the file/stream object involved in the error, or null if none are involved
-
-