org.apache.cocoon.util.location
Interface LocatableException

All Superinterfaces:
Locatable
All Known Implementing Classes:
BindingException, ConnectionResetException, DuplicateIdException, FormsException, FormsRuntimeException, IncompletenessException, InvalidContinuationException, LibraryException, LibraryException, LocatedException, LocatedRuntimeException, ProcessingException, ResourceNotFoundException

public interface LocatableException
extends Locatable

Extension of Locatable for exceptions.

In order to dump location information in the stacktrace, the getMessage() method of a Locatable exception should return a concatenation of the raw message (given in the constructor) and the exception's location, e.g. "foo failed (file.xml:12:3)". However, Locatable-aware classes will want to handle the raw message (i.e. "foo failed") and location separately. This interface gives access to the raw message.

Note: care should be taken for locatable exceptions to use only immutable and serializable implementations of Location

Since:
2.1.8
Version:
$Id: LocatableException.html 1304258 2012-03-23 10:09:27Z ilgrosso $
See Also:
LocationImpl.get(Location)

Method Summary
 String getRawMessage()
          Get the raw message of the exception (the one used in the constructor)
 
Methods inherited from interface org.apache.cocoon.util.location.Locatable
getLocation
 

Method Detail

getRawMessage

String getRawMessage()
Get the raw message of the exception (the one used in the constructor)

Returns:
the raw message


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