Example usage for java.util.concurrent ExecutionException setStackTrace

List of usage examples for java.util.concurrent ExecutionException setStackTrace

Introduction

In this page you can find the example usage for java.util.concurrent ExecutionException setStackTrace.

Prototype

public void setStackTrace(StackTraceElement[] stackTrace) 

Source Link

Document

Sets the stack trace elements that will be returned by #getStackTrace() and printed by #printStackTrace() and related methods.

Usage

From source file:org.limewire.mojito.handler.response.AbstractResponseHandler.java

/**
 * Sets the Exception which will be thrown by the
 * call() method./*from  ww  w.  jav a  2 s  .  c  o m*/
 */
protected void setException(DHTException ex) {
    ExecutionException e = new ExecutionException(ex);
    e.setStackTrace(ex.getStackTrace());
    exchanger.setException(e);
}