org.openrdf.rio
Class StatementHandlerException

java.lang.Object
  extended byjava.lang.Throwable
      extended byjava.lang.Exception
          extended byorg.openrdf.rio.StatementHandlerException
All Implemented Interfaces:
Serializable

public class StatementHandlerException
extends Exception

An exception that can be thrown by a StatementHandler when it encounters an application specific error that should cause the parser to stop. If an exception is associated with the error then this exception can be stored in a StatementHandlerException and can later be retrieved from it when the StatementHandlerException is catched, e.g.:

 try {
   parser.parse(myInputStream, myBaseURI);
 }
 catch (StatementHandlerException e) {
   Exception myException = e.getSource();
   ...
 }
 

See Also:
Serialized Form

Constructor Summary
StatementHandlerException(Exception source)
          Creates a new StatementHandlerException wrapping another exception.
StatementHandlerException(String msg)
          Creates a new StatementHandlerException.
StatementHandlerException(String msg, Exception source)
          Creates a new StatementHandlerException wrapping another exception.
 
Method Summary
 Exception getSource()
          Gets the source of this exception.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

StatementHandlerException

public StatementHandlerException(String msg)
Creates a new StatementHandlerException.

Parameters:
msg - An error message.

StatementHandlerException

public StatementHandlerException(String msg,
                                 Exception source)
Creates a new StatementHandlerException wrapping another exception.

Parameters:
msg - An error message.
source - The source exception.

StatementHandlerException

public StatementHandlerException(Exception source)
Creates a new StatementHandlerException wrapping another exception. The StatementHandlerException will inherit its message from the supplied source exception.

Parameters:
source - The source exception.
Method Detail

getSource

public Exception getSource()
Gets the source of this exception.

Returns:
The source of this exception.


Copyright © 2002-2006 Aduna BV, GNU LGPL License applies.