Class SAXParseException
Encapsulate an XML parse error or warning.
Namespace: Sax
Assembly: Lucene.Net.Benchmark.dll
Syntax
public class SAXParseException : SAXException
Remarks
This module, both source code and documentation, is in the Public Domain, and comes with NO WARRANTY. Seehttp://www.saxproject.org for further information.
This exception may include information for locating the error
in the original XML document, as if it came from a ILocator
object. Note that although the application
will receive a SAXParseException as the argument to the handlers
in the IError
Since this exception is a subclass of SAXException, it inherits the ability to wrap another exception.
Constructors
| Improve this Doc View SourceSAXParseException(String, ILocator)
Create a new SAXParse
Declaration
public SAXParseException(string message, ILocator locator)
Parameters
Type | Name | Description |
---|---|---|
System. |
message | The error or warning message. |
ILocator | locator | The locator object for the error or warning (may be null). |
Remarks
This constructor is especially useful when an application is
creating its own exception from within a IContent
See Also
| Improve this Doc View SourceSAXParseException(String, ILocator, Exception)
Wrap an existing exception in a SAXParseException.
Declaration
public SAXParseException(string message, ILocator locator, Exception e)
Parameters
Type | Name | Description |
---|---|---|
System. |
message | The error or warning message, or null to use the message from the embedded exception. |
ILocator | locator | The locator object for the error or warning (may be null). |
Exception | e | Any exception. |
Remarks
This constructor is especially useful when an application is
creating its own exception from within a IContent
See Also
| Improve this Doc View SourceSAXParseException(String, String, String, Int32, Int32)
Create a new SAXParseException.
Declaration
public SAXParseException(string message, string publicId, string systemId, int lineNumber, int columnNumber)
Parameters
Type | Name | Description |
---|---|---|
System. |
message | The error or warning message. |
System. |
publicId | The public identifier of the entity that generated the error or warning. |
System. |
systemId | The system identifier of the entity that generated the error or warning. |
System. |
lineNumber | The line number of the end of the text that caused the error or warning. |
System. |
columnNumber | The column number of the end of the text that cause the error or warning. |
Remarks
This constructor is most useful for parser writers.
All parameters except the message are as if they were provided by a ILocator. For example, if the system identifier is a URL (including relative filename), the caller must resolve it fully before creating the exception.
SAXParseException(String, String, String, Int32, Int32, Exception)
Create a new SAXParse
Declaration
public SAXParseException(string message, string publicId, string systemId, int lineNumber, int columnNumber, Exception e)
Parameters
Type | Name | Description |
---|---|---|
System. |
message | The error or warning message, or null to use the message from the embedded exception. |
System. |
publicId | The public identifier of the entity that generated the error or warning. |
System. |
systemId | The system identifier of the entity that generated the error or warning. |
System. |
lineNumber | The line number of the end of the text that caused the error or warning. |
System. |
columnNumber | The column number of the end of the text that cause the error or warning. |
Exception | e | Another exception to embed in this one. |
Remarks
This constructor is most useful for parser writers who need to wrap an exception that is not a subclass of SAXException.
All parameters except the message and exception are as if they were provided by a ILocator. For example, if the system identifier is a URL (including relative filename), the caller must resolve it fully before creating the exception.
Properties
| Improve this Doc View SourceColumnNumber
The column number of the end of the text where the exception occurred.
The first column in a line is position 1.
An integer representing the column number, or -1 if none is available.
Declaration
public int ColumnNumber { get; }
Property Value
Type | Description |
---|---|
System. |
See Also
| Improve this Doc View SourceLineNumber
The line number of the end of the text where the exception occurred.
The first line is line 1.
An integer representing the line number, or -1 if none is available.
Declaration
public int LineNumber { get; }
Property Value
Type | Description |
---|---|
System. |
See Also
| Improve this Doc View SourcePublicId
Get the public identifier of the entity where the exception occurred. Returns a string containing the public identifier, or null if none is available.
Declaration
public string PublicId { get; }
Property Value
Type | Description |
---|---|
System. |
See Also
| Improve this Doc View SourceSystemId
Get the system identifier of the entity where the exception occurred.
If the system identifier is a URL, it will have been resolved fully.
A string containing the system identifier, or null if none is available.
Declaration
public string SystemId { get; }
Property Value
Type | Description |
---|---|
System. |