Class ContentWriterAdapter
java.lang.Object
org.x4o.sax3.io.ContentWriterAdapter
- All Implemented Interfaces:
Closeable
,AutoCloseable
,ContentWriter
,ContentHandler
,LexicalHandler
- Direct Known Subclasses:
ScopicManifest5ContentParser
ContentWriterAdapter is base ContentHandler for writing SAX3 events.
- Version:
- 1.0 Dec 27, 2024
- Author:
- Willem Cazander
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
characters
(char c) Writes a single character in the body body.void
characters
(char[] ch, int start, int length) void
comment
(char[] ch, int start, int length) void
Writes a String as xml comment.void
endCDATA()
void
endDTD()
void
void
endPrefixMapping
(String arg0) void
ignorableWhitespace
(char c) Writes a whitespace character to the body.void
ignorableWhitespace
(char[] ch, int start, int length) void
ignorableWhitespace
(String text) Writes a whitespace String to the body.void
processingInstruction
(String arg0, String arg1) void
setDocumentLocator
(Locator arg0) void
skippedEntity
(String arg0) void
void
void
startElementEnd
(String uri, String localName, String name, Attributes atts) Starts and ends an element in one call.void
startEntity
(String arg0) void
startPrefixMapping
(String arg0, String arg1) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.xml.sax.ContentHandler
declaration, endDocument, endElement, startDocument, startElement
Methods inherited from interface org.x4o.sax3.io.ContentWriter
characters
-
Constructor Details
-
ContentWriterAdapter
public ContentWriterAdapter()
-
-
Method Details
-
comment
- Specified by:
comment
in interfaceLexicalHandler
- Throws:
SAXException
-
ignorableWhitespace
- Specified by:
ignorableWhitespace
in interfaceContentHandler
- Throws:
SAXException
-
ignorableWhitespace
Description copied from interface:ContentWriter
Writes a whitespace character to the body.- Specified by:
ignorableWhitespace
in interfaceContentWriter
- Parameters:
c
- The character to write.- Throws:
SAXException
- On error;
-
startElementEnd
public void startElementEnd(String uri, String localName, String name, Attributes atts) throws SAXException Description copied from interface:ContentWriter
Starts and ends an element in one call.- Specified by:
startElementEnd
in interfaceContentWriter
- Parameters:
uri
- The uri of the element.localName
- The localName of the element.name
- The name of the element.atts
- The attributes of the element.- Throws:
SAXException
- When IOException is thrown.
-
characters
Description copied from interface:ContentWriter
Writes a single character in the body body.- Specified by:
characters
in interfaceContentWriter
- Parameters:
c
- The character to write.- Throws:
SAXException
- On error.
-
characters
- Specified by:
characters
in interfaceContentHandler
- Throws:
SAXException
-
endCDATA
- Specified by:
endCDATA
in interfaceLexicalHandler
- Throws:
SAXException
-
endDTD
- Specified by:
endDTD
in interfaceLexicalHandler
- Throws:
SAXException
-
endEntity
- Specified by:
endEntity
in interfaceLexicalHandler
- Throws:
SAXException
-
startCDATA
- Specified by:
startCDATA
in interfaceLexicalHandler
- Throws:
SAXException
-
startDTD
- Specified by:
startDTD
in interfaceLexicalHandler
- Throws:
SAXException
-
startEntity
- Specified by:
startEntity
in interfaceLexicalHandler
- Throws:
SAXException
-
endPrefixMapping
- Specified by:
endPrefixMapping
in interfaceContentHandler
- Throws:
SAXException
-
processingInstruction
- Specified by:
processingInstruction
in interfaceContentHandler
- Throws:
SAXException
-
setDocumentLocator
- Specified by:
setDocumentLocator
in interfaceContentHandler
-
skippedEntity
- Specified by:
skippedEntity
in interfaceContentHandler
- Throws:
SAXException
-
startPrefixMapping
- Specified by:
startPrefixMapping
in interfaceContentHandler
- Throws:
SAXException
-
comment
Description copied from interface:ContentWriter
Writes a String as xml comment.- Specified by:
comment
in interfaceContentWriter
- Parameters:
text
- The text to have embedded as comment in xml.- Throws:
SAXException
- On error.
-
ignorableWhitespace
Description copied from interface:ContentWriter
Writes a whitespace String to the body.- Specified by:
ignorableWhitespace
in interfaceContentWriter
- Parameters:
text
- The String of whitespace to write.- Throws:
SAXException
- On error.
-