public class CharacterEvent extends DummyEvent implements Characters
fLocationATTRIBUTE, CDATA, CHARACTERS, COMMENT, DTD, END_DOCUMENT, END_ELEMENT, ENTITY_DECLARATION, ENTITY_REFERENCE, NAMESPACE, NOTATION_DECLARATION, PROCESSING_INSTRUCTION, SPACE, START_DOCUMENT, START_ELEMENT| Constructor and Description |
|---|
CharacterEvent() |
CharacterEvent(String data) |
CharacterEvent(String data,
boolean flag) |
CharacterEvent(String data,
boolean flag,
boolean isIgnorableWhiteSpace) |
| Modifier and Type | Method and Description |
|---|---|
String |
getData() |
protected void |
init() |
boolean |
isCData() |
boolean |
isIgnorableWhiteSpace()
Return true if this is ignorableWhiteSpace.
|
boolean |
isWhiteSpace()
Returns true if this set of Characters
is all whitespace.
|
void |
setData(String data) |
String |
toString() |
protected void |
writeAsEncodedUnicodeEx(Writer writer)
This method will write the XMLEvent as per the XML 1.0 specification as Unicode characters.
|
asCharacters, asEndElement, asStartElement, charEncode, getEventType, getLocation, getSchemaType, isAttribute, isCharacterData, isCharacters, isEndDocument, isEndElement, isEntityReference, isNamespace, isProcessingInstruction, isStartDocument, isStartElement, setEventType, writeAsEncodedUnicodeclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitasCharacters, asEndElement, asStartElement, getEventType, getLocation, getSchemaType, isAttribute, isCharacters, isEndDocument, isEndElement, isEntityReference, isNamespace, isProcessingInstruction, isStartDocument, isStartElement, writeAsEncodedUnicodepublic CharacterEvent()
public CharacterEvent(String data)
data - Character Data.public CharacterEvent(String data, boolean flag)
data - Character Data.flag - true if CDatapublic CharacterEvent(String data, boolean flag, boolean isIgnorableWhiteSpace)
data - Character Data.flag - true if CDataisIgnorableWhiteSpace - true if data is ignorable whitespace.protected void init()
public String getData()
getData in interface Characterspublic void setData(String data)
String - datapublic boolean isCData()
isCData in interface Characterspublic String toString()
protected void writeAsEncodedUnicodeEx(Writer writer) throws IOException
writeAsEncodedUnicodeEx in class DummyEventwriter - The writer that will output the dataXMLStreamException - if there is a fatal error writing the eventIOException - if there is an IO errorpublic boolean isIgnorableWhiteSpace()
isIgnorableWhiteSpace in interface Characterspublic boolean isWhiteSpace()
isWhiteSpace in interface CharactersCopyright © 2018–2021 mhoffrogge. All rights reserved.