org.xins.server
Class ResultCode

java.lang.Object
  extended byorg.xins.server.ResultCode

public final class ResultCode
extends Object

Abstraction of an error code returned by a function. Result codes are either generic or API-specific.

Result codes do not automatically apply to all functions of an API if they have been defined for that API. Instead they are associated with each individual function.

Since:
XINS 1.0.0
Version:
$Revision: 1.22 $ $Date: 2006/08/28 09:12:33 $
Author:
Ernst de Haan

Constructor Summary
ResultCode(API api, String name, String value)
          Constructs a new ResultCode for the specified API.
 
Method Summary
 String getName()
          Returns the symbolic name of this result code.
 String getValue()
          Returns the value of this result code.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResultCode

public ResultCode(API api,
                  String name,
                  String value)
           throws IllegalArgumentException
Constructs a new ResultCode for the specified API.

Parameters:
api - the API to which this result code belongs, not null.
name - the symbolic name, can be null.
value - the actual value of this code, not null.
Throws:
IllegalArgumentException - if api == null || value == null.
Method Detail

getName

public final String getName()
Returns the symbolic name of this result code.

Returns:
the symbolic name, can be null.

getValue

public final String getValue()
Returns the value of this result code.

Returns:
the value, not null.


See http://www.xins.org/.