Class XmlBeanDefinitionStoreException
- java.lang.Object
- java.lang.Throwable
- java.lang.Exception
- java.lang.RuntimeException
- org.springframework.core.NestedRuntimeException
- org.springframework.beans.BeansException
- org.springframework.beans.FatalBeanException
- org.springframework.beans.factory.BeanDefinitionStoreException
- org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException
- All Implemented Interfaces:
Serializable
public class XmlBeanDefinitionStoreException extends BeanDefinitionStoreException
XML-specific BeanDefinitionStoreException subclass that wraps aSAXException
, typically aSAXParseException
which contains information about the error location.- Since:
- 2.0.2
- Author:
- Juergen Hoeller
- See Also:
getLineNumber()
,SAXParseException
, Serialized Form
Constructor Summary
Constructors Constructor Description XmlBeanDefinitionStoreException(String resourceDescription, String msg, SAXException cause)
Create a new XmlBeanDefinitionStoreException.
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getLineNumber()
Return the line number in the XML resource that failed.Methods inherited from class org.springframework.beans.factory.BeanDefinitionStoreException
getBeanName, getResourceDescription
Methods inherited from class org.springframework.core.NestedRuntimeException
contains, getMessage, getMostSpecificCause, getRootCause
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
Constructor Detail
XmlBeanDefinitionStoreException
public XmlBeanDefinitionStoreException(String resourceDescription, String msg, SAXException cause)
Create a new XmlBeanDefinitionStoreException.- Parameters:
resourceDescription
- description of the resource that the bean definition came frommsg
- the detail message (used as exception message as-is)cause
- the SAXException (typically a SAXParseException) root cause- See Also:
SAXParseException
Method Detail
getLineNumber
public int getLineNumber()
Return the line number in the XML resource that failed.- Returns:
- the line number if available (in case of a SAXParseException); -1 else
- See Also:
SAXParseException.getLineNumber()