Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.synaptics.elvis
Class ElvisResult  view ElvisResult download ElvisResult.java

java.lang.Object
  extended bycom.synaptics.elvis.ElvisResult

public class ElvisResult
extends java.lang.Object


Field Summary
private  java.lang.String data
          This is the data associated with this particular result.
private  ElvisResponse response
          The ok/fail part of the result.
 
Constructor Summary
private ElvisResult(ElvisResponse response, java.lang.String data)
          Create a new result with the corresponding response and data.
 
Method Summary
static ElvisResult fail(java.lang.String data)
          Return a ElvisResult with a response of ElvisResponse.FAIL and the specified data string.
 java.lang.String getData()
          Return the data associated with this result.
 ElvisResponse getResponse()
          Returns the ElvisResponse for this result.
static ElvisResult succeed(java.lang.String data)
          Return a ElvisResult with a response of ElvisResponse.OK and the specified data string.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

response

private ElvisResponse response
The ok/fail part of the result.


data

private java.lang.String data
This is the data associated with this particular result.

Constructor Detail

ElvisResult

private ElvisResult(ElvisResponse response,
                    java.lang.String data)
Create a new result with the corresponding response and data. Private to keep clients from inadvertantly creating invalid ElvisResults.

Method Detail

getResponse

public ElvisResponse getResponse()
Returns the ElvisResponse for this result. This may be one of a limited number of values - see ElvisResponse for more details.


getData

public java.lang.String getData()
Return the data associated with this result. This is a client dependent value, and may be null or empty.


fail

public static final ElvisResult fail(java.lang.String data)
Return a ElvisResult with a response of ElvisResponse.FAIL and the specified data string.


succeed

public static final ElvisResult succeed(java.lang.String data)
Return a ElvisResult with a response of ElvisResponse.OK and the specified data string.