Package org.jivesoftware.openfire.net
Class XMLSocketWriter
- java.lang.Object
-
- org.xml.sax.helpers.XMLFilterImpl
-
- org.jivesoftware.util.XMLWriter
-
- org.jivesoftware.openfire.net.XMLSocketWriter
-
- All Implemented Interfaces:
ContentHandler
,DTDHandler
,EntityResolver
,ErrorHandler
,LexicalHandler
,XMLFilter
,XMLReader
public class XMLSocketWriter extends XMLWriter
XMLWriter whose writer is actually sending data on a socket connection. Since sending data over a socket may have particular type of errors this class tries to deal with those errors.
-
-
Field Summary
-
Fields inherited from class org.jivesoftware.util.XMLWriter
DEFAULT_FORMAT, lastOutputNodeType, LEXICAL_HANDLER_NAMES, preserve, writer
-
-
Constructor Summary
Constructors Constructor Description XMLSocketWriter(Writer writer, SocketConnection connection)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
flush()
Flushes the underlying writer making sure that if the connection is dead then the thread that is flushing does not end up in an endless wait.-
Methods inherited from class org.jivesoftware.util.XMLWriter
characters, close, comment, createWriter, defaultMaximumAllowedCharacter, endCDATA, endDocument, endDTD, endElement, endEntity, endPrefixMapping, escapeAttributeEntities, escapeElementEntities, getLexicalHandler, getMaximumAllowedCharacter, getOutputFormat, getProperty, handleException, ignorableWhitespace, indent, installLexicalHandler, isElementSpacePreserved, isEscapeText, isExpandEmptyElements, isNamespaceDeclaration, notationDecl, parse, println, processingInstruction, resolveEntityRefs, setDocumentLocator, setEscapeText, setIndentLevel, setLexicalHandler, setMaximumAllowedCharacter, setOutputStream, setProperty, setResolveEntityRefs, setWriter, shouldEncodeChar, startCDATA, startDocument, startDTD, startElement, startEntity, startPrefixMapping, unparsedEntityDecl, write, write, write, write, write, write, write, write, write, write, write, write, write, writeAttribute, writeAttribute, writeAttributes, writeAttributes, writeCDATA, writeClose, writeClose, writeComment, writeDeclaration, writeDocType, writeDocType, writeElement, writeElementContent, writeEmptyElementClose, writeEntity, writeEntityRef, writeEscapeAttributeEntities, writeNamespace, writeNamespace, writeNamespaces, writeNode, writeNodeText, writeOpen, writePrintln, writeProcessingInstruction, writeString
-
Methods inherited from class org.xml.sax.helpers.XMLFilterImpl
error, fatalError, getContentHandler, getDTDHandler, getEntityResolver, getErrorHandler, getFeature, getParent, parse, resolveEntity, setContentHandler, setDTDHandler, setEntityResolver, setErrorHandler, setFeature, setParent, skippedEntity, warning
-
-
-
-
Constructor Detail
-
XMLSocketWriter
public XMLSocketWriter(Writer writer, SocketConnection connection)
-
-
Method Detail
-
flush
public void flush() throws IOException
Flushes the underlying writer making sure that if the connection is dead then the thread that is flushing does not end up in an endless wait.- Overrides:
flush
in classXMLWriter
- Throws:
IOException
- if an I/O error occurs while flushing the writer.
-
-