Package de.businesscode.bcdui.wrs.load
Class WrsDataWriter
java.lang.Object
de.businesscode.bcdui.wrs.load.AbstractDataWriter
de.businesscode.bcdui.wrs.load.WrsDataWriter
- All Implemented Interfaces:
IDataWriter
The default implementation of the IDataWriter - write wrs-xml-format using xml-stream
Write an empty document if the resultSet is null.
Supports also the short refDataFormat.
Write an empty document if the resultSet is null.
Supports also the short refDataFormat.
-
Field Summary
FieldsFields inherited from class de.businesscode.bcdui.wrs.load.AbstractDataWriter
rowCounter -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()close the destination resourceprotected Writerprotected final XMLStreamWriterprotected voidwrite()replace the write method from interfaceprotected voidWrite empty document if no data was requestedprotected voidwriteWrs()writeWrsprotected voidwriteWrsDataprotected voidwriteWrsDataRow(int rowNum) writeWrsDataRowprotected voidwriteWrsDataRowAttributes(int rowNum) writeWrsDataRowAttributesprotected voidwriteWrsDataRowColumnprotected voidWrites the attributes corresponding to wrs:A sub-nodes of a wrs:C Attributes are not written if their value was nullprotected voidwriteWrsDataRowColumnValue(int jdbcColumnType, int colNum) writeWrsDataRowColumnValueprotected voidprotected voidwriteWrsHeaderColumnsprotected voidwriteWrsHeaderDebugprotected voidwriteWrsMaxRowsExceeded(int maxRows) writeWrsMaxRowsExceededprotected voidMethods inherited from class de.businesscode.bcdui.wrs.load.AbstractDataWriter
getColumnsCount, getDuration, getGenerator, getOptions, getRequestDocRoot, getResultSet, getResultSetMetaData, getRowCount, isEscapeXMLType, setEscapeXMLType, writeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface de.businesscode.bcdui.wrs.load.IDataWriter
getColumnsCount, getRowCount, write
-
Field Details
-
WRS_XML_NAMESPACE
- See Also:
-
-
Constructor Details
-
WrsDataWriter
public WrsDataWriter()WrsDataWriter. Create the writer without parameters - caller should overwrite the method getStream(). -
WrsDataWriter
WrsDataWriter- Parameters:
writer-
-
-
Method Details
-
getWriter
- Returns:
- the writer
-
getLazyStream
- Returns:
- the output writer.
The clients can overwrite this method like: return response.getWriter().
This method called only once by lazy creation of the xml-writer (if it was not sets from constructor parameters. - Throws:
Exception
-
close
Description copied from interface:IDataWriterclose the destination resource- Specified by:
closein interfaceIDataWriter- Throws:
Exception- See Also:
-
write
Description copied from class:AbstractDataWriterreplace the write method from interface- Specified by:
writein classAbstractDataWriter- Throws:
Exception- See Also:
-
writeEmptyDocument
Write empty document if no data was requested- Throws:
XMLStreamExceptionException
-
writeWrs
writeWrs- Throws:
Exception
-
writeWrsRequest
- Throws:
Exception
-
writeWrsHeaderColumns
writeWrsHeaderColumns- Throws:
Exception
-
writeWrsHeaderDebug
writeWrsHeaderDebug- Throws:
Exception
-
writeWrsData
writeWrsData- Throws:
Exception
-
writeWrsDataRow
writeWrsDataRow- Parameters:
rowNum-- Throws:
Exception
-
writeWrsDataRowAttributes
writeWrsDataRowAttributes- Parameters:
rowNum-- Throws:
Exception
-
writeWrsDataRowColumn
writeWrsDataRowColumn- Parameters:
item- - binding item- Throws:
Exception
-
writeWrsDataRowColumnValue
writeWrsDataRowColumnValue- Parameters:
jdbcColumnType-colNum- - starts with 1 (JDBC compliant)- Throws:
Exception
-
writeWrsDataRowColumnAttributes
Writes the attributes corresponding to wrs:A sub-nodes of a wrs:C Attributes are not written if their value was null- Parameters:
item-- Throws:
Exception
-
writeWrsErrorDuringQuery
- Throws:
XMLStreamException
-
writeWrsMaxRowsExceeded
writeWrsMaxRowsExceeded- Parameters:
maxRows-- Throws:
XMLStreamException
-