public final class TaskExecutionResult extends Object
| Modifier and Type | Method and Description |
|---|---|
static TaskExecutionResult |
error(String errorMessage,
Exception ex)
Creates an instance of this class denoting an unsuccessful task execution.
|
String |
getErrorMessage()
Gets the error message, if any.
|
Exception |
getException()
Gets the exception contained in this result, if any.
|
String |
getSuccessMessage()
Gets the success message in this result, if any.
|
static TaskExecutionResult |
success(String successMessage)
Creates an instance of this class denoting a successful task execution.
|
public static TaskExecutionResult success(String successMessage)
successMessage - The success message.public static TaskExecutionResult error(String errorMessage, Exception ex)
errorMessage - The error message.ex - The exception reported by the task.public Exception getException()
public String getSuccessMessage()
public String getErrorMessage()
Copyright © 2016. All rights reserved.