All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.sgi.sysadm.ui.event.TaskResult

java.lang.Object
   |
   +----java.util.EventObject
           |
           +----com.sgi.sysadm.ui.event.TaskResult

public class TaskResult
extends EventObject
An event that provides information about whether a task succeeded or was cancelled by the User. If a task fails, the Task interface remains displayed so that the User may make changes to the data entered and try again. Ultimately the User will cancel the task if it cannot be performed for some reason.


Variable Index

 o CANCELLED
Results of type TaskResult.CANCELLED are generated when a task is cancelled by the user.
 o SUCCEEDED
Results of type TaskResult.SUCCEEDED are generated when the task privileged command(s) complete(s) successfully.

Constructor Index

 o TaskResult(Task, int)
Constructor.

Method Index

 o getErrorText()
Get the error text associated with a SUCCEEDED result.
 o getOutputText()
Get the output text associated with a SUCCEEDED result.
 o getResultType()
Get the type of this result.
 o getTask()
Get the Task that generated this result.
 o setErrorText(String)
Set the error text associated with a SUCCEEDED result.
 o setOutputText(String)
Set the output text associated with a SUCCEEDED result.

Variables

 o SUCCEEDED
 public static final int SUCCEEDED
Results of type TaskResult.SUCCEEDED are generated when the task privileged command(s) complete(s) successfully. Even if the task is successful, there may be warnings or other text sent either to stdout or stderr. Use TaskResult.getOutputText() and TaskResult.getErrorText() to get the output and error data from the privileged command(s).

 o CANCELLED
 public static final int CANCELLED
Results of type TaskResult.CANCELLED are generated when a task is cancelled by the user.

Constructors

 o TaskResult
 public TaskResult(Task task,
                   int resultType)
Constructor.

Parameters:
task - The Task that generated this result.
type - The type of result generated. One of: TaskResult.SUCCEEDED or TaskResult.CANCELLED.

Methods

 o getTask
 public Task getTask()
Get the Task that generated this result.

Returns:
The Task that generated this result.
 o getResultType
 public int getResultType()
Get the type of this result.

Returns:
The type of this result. One of: TaskResult.SUCCEEDED or TaskResult.CANCELLED.
 o setOutputText
 public void setOutputText(String outputText)
Set the output text associated with a SUCCEEDED result.

Parameters:
outputText - The output data generated by the privileged command(s).
 o getOutputText
 public String getOutputText()
Get the output text associated with a SUCCEEDED result.

Returns:
The output data generated by the privileged command(s).
 o setErrorText
 public void setErrorText(String errorText)
Set the error text associated with a SUCCEEDED result.

Parameters:
errorText - The error data generated by the privileged command(s).
 o getErrorText
 public String getErrorText()
Get the error text associated with a SUCCEEDED result.

Returns:
The error data generated by the privileged command(s).

All Packages  Class Hierarchy  This Package  Previous  Next  Index