public class Report extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
Report.ReportBuilder
Must be constructed through the factory method in Report.
|
| Modifier | Constructor and Description |
|---|---|
protected |
Report(ReportType type,
Throwable exception,
Object[] messageParameters,
Object[] callerParameters)
Construct a new report with the given type and parameters.
|
protected |
Report(ReportType type,
Throwable exception,
Object[] messageParameters,
Object[] callerParameters,
long rateLimit)
Construct a new report with the given type and parameters.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
Object[] |
getCallerParameters()
Retrieve the parameters of the caller method.
|
Throwable |
getException()
Retrieve the associated exception, or NULL if not found.
|
Object[] |
getMessageParameters()
Retrieve the message parameters that will be used to construc the report message.
|
long |
getRateLimit()
Retrieve desired minimum number of nanoseconds until a report of the same type and parameters should be reprinted.
|
String |
getReportMessage()
Format the current report type with the provided message parameters.
|
ReportType |
getType()
Retrieve the report type.
|
boolean |
hasCallerParameters()
Determine if we have any caller parameters.
|
int |
hashCode() |
boolean |
hasMessageParameters()
Determine if we have any message parameters.
|
static Report.ReportBuilder |
newBuilder(ReportType type)
Construct a new report builder.
|
protected Report(ReportType type, @Nullable Throwable exception, @Nullable Object[] messageParameters, @Nullable Object[] callerParameters)
exception - - exception that occured in the caller method.type - - the report type that will be used to construct the message.messageParameters - - parameters used to construct the report message.callerParameters - - parameters from the caller method.protected Report(ReportType type, @Nullable Throwable exception, @Nullable Object[] messageParameters, @Nullable Object[] callerParameters, long rateLimit)
exception - - exception that occurred in the caller method.type - - the report type that will be used to construct the message.messageParameters - - parameters used to construct the report message.callerParameters - - parameters from the caller method.rateLimit - - minimum number of nanoseconds to wait until a report of equal type and parameters is allowed to be printed again.public static Report.ReportBuilder newBuilder(ReportType type)
type - - the initial report type.public String getReportMessage()
public Object[] getMessageParameters()
This should not be confused with the method parameters of the caller method.
public Object[] getCallerParameters()
public ReportType getType()
public Throwable getException()
public boolean hasMessageParameters()
public boolean hasCallerParameters()
public long getRateLimit()
Note that this may be ignored or modified by the error reporter. Zero indicates no rate limit.
Copyright © 2012–2017 Comphenix and dmulloy2. Licensed under the GNU GPL v2.