Example usage for javax.management InvalidAttributeValueException getStackTrace

List of usage examples for javax.management InvalidAttributeValueException getStackTrace

Introduction

In this page you can find the example usage for javax.management InvalidAttributeValueException getStackTrace.

Prototype

public StackTraceElement[] getStackTrace() 

Source Link

Document

Provides programmatic access to the stack trace information printed by #printStackTrace() .

Usage

From source file:com.cyberway.issue.crawler.Heritrix.java

protected String addCrawlJob(final File order, final String name, final String description, final String seeds)
        throws FatalConfigurationException, IOException {
    CrawlJob addedJob = null;/*from  w  w  w  .ja v a 2 s  .  co  m*/
    if (this.jobHandler == null) {
        throw new NullPointerException("Heritrix jobhandler is null.");
    }
    try {
        if (order.getName().toLowerCase().endsWith(JAR_SUFFIX)) {
            return addCrawlJobBasedonJar(order, name, description, seeds);
        }
        addedJob = this.jobHandler.addJob(createCrawlJob(this.jobHandler, order, name));
    } catch (InvalidAttributeValueException e) {
        FatalConfigurationException fce = new FatalConfigurationException(
                "Converted InvalidAttributeValueException on " + order.getAbsolutePath() + ": "
                        + e.getMessage());
        fce.setStackTrace(e.getStackTrace());
    }
    return addedJob != null ? addedJob.getUID() : null;
}