Class TaggedIOException

  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by
              extended by
                  extended by
All Implemented Interfaces:

public class TaggedIOException
extends IOExceptionWithCause

An IOException wrapper that tags the wrapped exception with a given object reference. Both the tag and the wrapped original exception can be used to determine further processing when this exception is caught.

See Also:
Serialized Form

Constructor Summary
TaggedIOException( original, java.lang.Object tag)
          Creates a tagged wrapper for the given exception.
Method Summary getCause()
          Returns the wrapped exception.
 java.lang.Object getTag()
          Returns the object reference used as the tag this exception.
Methods inherited from class java.lang.Throwable
fillInStackTrace, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

Constructor Detail


public TaggedIOException( original,
                         java.lang.Object tag)
Creates a tagged wrapper for the given exception.

original - the exception to be tagged
tag - tag object
Method Detail


public java.lang.Object getTag()
Returns the object reference used as the tag this exception.

tag object


public getCause()
Returns the wrapped exception. The only difference to the overridden Throwable.getCause() method is the narrower return type.

getCause in class java.lang.Throwable
wrapped exception

Copyright © 2007-2010 The Apache Software Foundation. All Rights Reserved.