org.jboss.seam.exception.control
Class ExceptionStack

java.lang.Object
  extended by org.jboss.seam.exception.control.ExceptionStack
All Implemented Interfaces:
Serializable

public class ExceptionStack
extends Object
implements Serializable

Information about the current exception and exception cause container. This object is not immutable.

See Also:
Serialized Form

Constructor Summary
ExceptionStack()
           
ExceptionStack(Collection<Throwable> causeChainElements, int currentElementIndex)
          Deprecated. There shouldn't be a use for this, please use the other constructor
ExceptionStack(Throwable exception)
          Builds the stack from the given exception.
 
Method Summary
protected  void dropCause()
           
 Collection<Throwable> getCauseElements()
           
 Throwable getCurrent()
           
 Throwable getNext()
           
 Deque<ExceptionStackItem> getOrigExceptionStackItems()
           
 Collection<Throwable> getRemaining()
           
 boolean isLast()
           
 boolean isRoot()
           
 void setCauseElements(Collection<Throwable> elements)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExceptionStack

public ExceptionStack()

ExceptionStack

public ExceptionStack(Throwable exception)
Builds the stack from the given exception.

Parameters:
exception - Caught exception

ExceptionStack

@Deprecated
public ExceptionStack(Collection<Throwable> causeChainElements,
                                 int currentElementIndex)
Deprecated. There shouldn't be a use for this, please use the other constructor

Basic constructor.

Parameters:
causeChainElements - collection of all causing elements for an exception from top to bottom (not unwrapped).
currentElementIndex - index of current element within the causeChainElements.
Throws:
IllegalArgumentException - if causeChainElements is empty or null.
Method Detail

getCauseElements

public Collection<Throwable> getCauseElements()

isLast

public boolean isLast()

getNext

public Throwable getNext()

getRemaining

public Collection<Throwable> getRemaining()

isRoot

public boolean isRoot()

getCurrent

public Throwable getCurrent()

setCauseElements

public void setCauseElements(Collection<Throwable> elements)

getOrigExceptionStackItems

public Deque<ExceptionStackItem> getOrigExceptionStackItems()

dropCause

protected void dropCause()


Copyright © 2011 Seam Framework. All Rights Reserved.