All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.mixer2.jaxb.exception.Mixer2JAXBException Maven / Gradle / Ivy

There is a newer version: 1.4.2
Show newest version
package org.mixer2.jaxb.exception;

import javax.xml.bind.JAXBException;
import javax.xml.bind.UnmarshalException;

import org.xml.sax.SAXParseException;

public class Mixer2JAXBException extends JAXBException {

    private static final long serialVersionUID = 8467912128175039180L;

    public Mixer2JAXBException(String message) {
        super(message);
    }

    public Mixer2JAXBException(Throwable exception) {
        super(exception);
    }

    public Mixer2JAXBException(String message, String errorCode) {
        super(message, errorCode);
    }

    public Mixer2JAXBException(String message, String errorCode,
            Throwable exception) {
        super(message, errorCode, exception);
    }

    public Mixer2JAXBException(String message, Throwable exception) {
        super(message, exception);
    }

    /**
     * 

* return true if this Exception links SAXParseException instance. *

* * @return */ public boolean hasSAXParseException() { if (getSAXParseException() == null) { return false; } else { return true; } } /** *

* return SAXParseException.getMessage() .
* return null if exception has not link to SAXParseException. *

* * @return */ public String getSAXParseExceptionMessage() { if (hasSAXParseException()) { return getSAXParseException().getMessage(); } else { return null; } } /** *

* return SAXParseException.
* return null if exception has not link to SAXParseException. *

* @return */ public SAXParseException getSAXParseException() { SAXParseException ex = null; Throwable linkedException = this.getLinkedException(); if (linkedException instanceof javax.xml.bind.UnmarshalException) { UnmarshalException ue = (UnmarshalException) linkedException; linkedException = ue.getLinkedException(); if (linkedException instanceof org.xml.sax.SAXParseException) { ex = (SAXParseException) linkedException; } } return ex; } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy