|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.dynatrace.diagnostics.pdk.Status
public final class Status
A status that describes the result of the Plugin setup or execute method call.
The status contains:
Nested Class Summary | |
---|---|
static class |
Status.StatusCode
Standard Status Codes They contain: a status code the base status code a short message a message |
Constructor Summary | |
---|---|
Status()
constructs a Status (per default successful) |
|
Status(Status.StatusCode statusCode)
create a new Status with the supplied status code. message and short message will be defaults depending on the used code. |
|
Status(Status.StatusCode statusCode,
java.lang.String shortMessage)
create a new Status with the supplied status code and short message. extended message will have a default depending on the status code. |
|
Status(Status.StatusCode statusCode,
java.lang.String shortMessage,
java.lang.String message)
create a new Status with the supplied status code, short message and extended message |
|
Status(Status.StatusCode statusCode,
java.lang.String shortMessage,
java.lang.String message,
java.lang.Throwable throwable)
create a new Status with the supplied status code, short message and extended message |
Method Summary | |
---|---|
java.lang.String |
getExceptionClassName()
Returns the Class Name of the last Exception |
java.lang.String |
getExceptionMessage()
Returns the Message of the last Exception |
java.lang.String |
getMessage()
Returns a longer Message explaining the current Status |
java.lang.String |
getShortMessage()
Returns the short Message for this Status |
java.lang.String |
getStacktrace()
Returns the Stack Trace of the last run |
Status.StatusCode |
getStatusCode()
Returns the StatusCode of this run |
static Status.StatusCode |
getStatusCode(int code)
Returns the StatusCode enum for a specified code |
void |
setException(java.lang.Throwable throwable)
Sets the Stack Trace, Exception Message and Exception Class If null is passed, those values will be set to null |
void |
setExceptionClassName(java.lang.String exceptionClassName)
Sets the Class Name of the Exception that occurred during this run |
void |
setExceptionMessage(java.lang.String exceptionMessage)
Sets the Exception Message for this run |
void |
setMessage(java.lang.String message)
Sets the Message of the current Status |
void |
setShortMessage(java.lang.String shortMessage)
Sets the short Message for this Status |
void |
setStacktrace(java.lang.String stacktrace)
Sets the Stack Trace for this run |
void |
setStatusCode(Status.StatusCode statusCode)
Sets the StatusCode |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Status()
public Status(Status.StatusCode statusCode)
statusCode
- the code, must not be nullpublic Status(Status.StatusCode statusCode, java.lang.String shortMessage)
statusCode
- the code, must not be nullshortMessage
- may supply additional brief information for this statuspublic Status(Status.StatusCode statusCode, java.lang.String shortMessage, java.lang.String message)
statusCode
- the code, must not be nullshortMessage
- may supply additional brief information for this statusmessage
- an extended message for in depth information such as stack traces etc.public Status(Status.StatusCode statusCode, java.lang.String shortMessage, java.lang.String message, java.lang.Throwable throwable)
statusCode
- the code, must not be nullshortMessage
- may supply additional brief information for this statusmessage
- an extended message for in depth information such as stack traces etc.throwable
- an optional throwable which may have been caught. may be null.Method Detail |
---|
public Status.StatusCode getStatusCode()
public void setStatusCode(Status.StatusCode statusCode)
statusCode
- the StatusCode to setpublic java.lang.String getShortMessage()
public void setShortMessage(java.lang.String shortMessage)
shortMessage
- the short Message to setpublic java.lang.String getMessage()
public void setMessage(java.lang.String message)
message
- the message to setpublic java.lang.String getStacktrace()
public java.lang.String getExceptionMessage()
public java.lang.String getExceptionClassName()
public void setStacktrace(java.lang.String stacktrace)
stacktrace
- the Stack Trace to setpublic void setExceptionMessage(java.lang.String exceptionMessage)
exceptionMessage
- the Exception Message to setpublic void setExceptionClassName(java.lang.String exceptionClassName)
exceptionClassName
- the Class Name to setpublic void setException(java.lang.Throwable throwable)
throwable
- the Throwable that occurred during the last runpublic java.lang.String toString()
toString
in class java.lang.Object
public static Status.StatusCode getStatusCode(int code)
code
- the integer value of this code
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |