org.opcfoundation.ua.common
Class ServiceResultException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by org.opcfoundation.ua.common.ServiceResultException
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
DecodingException, EncodingException, ServiceFaultException

public class ServiceResultException
extends Exception

Generic Exception

See Also:
StatusCodes, Serialized Form

Field Summary
protected  StatusCode statusCode
           
protected  String text
           
 
Constructor Summary
ServiceResultException(int statusCode)
          Constructor for ServiceResultException.
ServiceResultException(int statusCode, String text)
          Constructor for ServiceResultException.
ServiceResultException(StatusCode statusCode)
          Constructor for ServiceResultException.
ServiceResultException(StatusCode statusCode, String text)
          Constructor for ServiceResultException.
ServiceResultException(StatusCode statusCode, Throwable reason)
          Constructor for ServiceResultException.
ServiceResultException(StatusCode statusCode, Throwable reason, String text)
          Constructor for ServiceResultException.
ServiceResultException(String message)
          Constructor for ServiceResultException.
ServiceResultException(Throwable reason)
          Constructor for ServiceResultException.
ServiceResultException(UnsignedInteger statusCode)
          Constructor for ServiceResultException.
ServiceResultException(UnsignedInteger statusCode, String text)
          Constructor for ServiceResultException.
ServiceResultException(UnsignedInteger statusCode, Throwable reason)
          Constructor for ServiceResultException.
ServiceResultException(UnsignedInteger statusCode, Throwable reason, String text)
          Constructor for ServiceResultException.
 
Method Summary
 String getAdditionalTextField()
          getAdditionalTextField.
 String getMessage()
          
 StatusCode getStatusCode()
          Getter for the field statusCode.
 ServiceResult toServiceResult()
          Converts the error into a service result
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

statusCode

protected final StatusCode statusCode

text

protected final String text
Constructor Detail

ServiceResultException

public ServiceResultException(String message)

Constructor for ServiceResultException.

Parameters:
message - a String object.

ServiceResultException

public ServiceResultException(int statusCode)

Constructor for ServiceResultException.

Parameters:
statusCode - a int.

ServiceResultException

public ServiceResultException(int statusCode,
                              String text)

Constructor for ServiceResultException.

Parameters:
statusCode - a int.
text - a String object.

ServiceResultException

public ServiceResultException(UnsignedInteger statusCode)

Constructor for ServiceResultException.

Parameters:
statusCode - a UnsignedInteger object.

ServiceResultException

public ServiceResultException(UnsignedInteger statusCode,
                              String text)

Constructor for ServiceResultException.

Parameters:
statusCode - a UnsignedInteger object.
text - a String object.

ServiceResultException

public ServiceResultException(UnsignedInteger statusCode,
                              Throwable reason,
                              String text)

Constructor for ServiceResultException.

Parameters:
statusCode - a UnsignedInteger object.
reason - a Throwable object.
text - a String object.

ServiceResultException

public ServiceResultException(StatusCode statusCode)

Constructor for ServiceResultException.

Parameters:
statusCode - a StatusCode object.

ServiceResultException

public ServiceResultException(StatusCode statusCode,
                              String text)

Constructor for ServiceResultException.

Parameters:
statusCode - a StatusCode object.
text - a String object.

ServiceResultException

public ServiceResultException(StatusCode statusCode,
                              Throwable reason,
                              String text)

Constructor for ServiceResultException.

Parameters:
statusCode - a StatusCode object.
reason - a Throwable object.
text - a String object.

ServiceResultException

public ServiceResultException(UnsignedInteger statusCode,
                              Throwable reason)

Constructor for ServiceResultException.

Parameters:
statusCode - a UnsignedInteger object.
reason - a Throwable object.

ServiceResultException

public ServiceResultException(StatusCode statusCode,
                              Throwable reason)

Constructor for ServiceResultException.

Parameters:
statusCode - a StatusCode object.
reason - a Throwable object.

ServiceResultException

public ServiceResultException(Throwable reason)

Constructor for ServiceResultException.

Parameters:
reason - a Throwable object.
Method Detail

getMessage

public String getMessage()

Overrides:
getMessage in class Throwable

getStatusCode

public StatusCode getStatusCode()

Getter for the field statusCode.

Returns:
a StatusCode object.

getAdditionalTextField

public String getAdditionalTextField()

getAdditionalTextField.

Returns:
a String object.

toServiceResult

public ServiceResult toServiceResult()
Converts the error into a service result

Returns:
a new service result object


Copyright © 2018. All rights reserved.