com.crystaldecisions.sdk.occa.report.data
Class XMLDataSet

java.lang.Object
  extended by com.crystaldecisions.sdk.occa.report.data.XMLDataSet
All Implemented Interfaces:
IXMLDataSet

public class XMLDataSet
extends java.lang.Object
implements IXMLDataSet

The XMLDataSet object is a runtime data source that determines the set of data that is displayed by a report. You must access the XML data and convert it to a java.io.InputStream and then read from the stream object into the byte array. Once the data set has been created, you can set the data source with the DatabaseController object’s setDataSource method. The DatabaseController object's replaceConnection method can then be used to replace one data set with another.

The data structure and the data in this object will persist with the report if the setEnableSaveDataWithReport is set to true. The report cannot reconnect to the original data source, since the XMLDataSet object and other objects that are used to construct it only exist at run-time. To reconnect to the original data source, you must create these objects and call the DatabaseController object’s setDataSource method again.

Supported schemas are those that are supported by the current XML data driver, which allows access to the XML data as a local file, a URL, or a web service.

Use the IXMLDataSet interface to manipulate this object.


Constructor Summary
XMLDataSet()
           
XMLDataSet(IByteArray xmlData, IByteArray xmlSchema)
           
 
Method Summary
 java.lang.Object createMember(java.lang.String eleName, org.xml.sax.Attributes attrs, XMLSerializationContext ctxt, java.util.Map objState, boolean[] bLoaded)
           For internal use only.
 void endElement(java.lang.String eleName, java.util.Map objState)
           For internal use only.
 IByteArray getXMLData()
           Gets the XML data that is used as the source of the data set.
 IByteArray getXMLSchema()
           Gets the XML Schema for the XML data that is used as the source of the data set.
 void readElement(java.lang.String eleName, java.lang.String sVal, org.xml.sax.Attributes attrs, java.util.Map objState)
           For internal use only.
 void save(XMLWriter writer, java.lang.String sTag, XMLSerializationContext ctxt)
           For internal use only.
 void save(XMLWriter writer, XMLSerializationContext ctxt)
           For internal use only.
 void saveContents(XMLWriter writer, XMLSerializationContext ctxt)
           For internal use only.
 void setXMLData(IByteArray xmlData)
           Sets the XML data that is used as the source of the data set.
 void setXMLSchema(IByteArray xmlSchema)
           Sets the XML Schema for the XML data that is used as the source of the data set.
 void startElement(java.lang.String eleName, java.util.Map objState, org.xml.sax.Attributes attrs)
           For internal use only.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XMLDataSet

public XMLDataSet()

XMLDataSet

public XMLDataSet(IByteArray xmlData,
                  IByteArray xmlSchema)
Method Detail

setXMLData

public void setXMLData(IByteArray xmlData)
Description copied from interface: IXMLDataSet

Sets the XML data that is used as the source of the data set.

Specified by:
setXMLData in interface IXMLDataSet
Parameters:
xmlData - the IByteArray object that specifies the XML data that is used as the source of the data set

getXMLData

public IByteArray getXMLData()
Description copied from interface: IXMLDataSet

Gets the XML data that is used as the source of the data set.

Specified by:
getXMLData in interface IXMLDataSet
Returns:
A IByteArray object that specifies the XML data that is used as the source of the data set.

setXMLSchema

public void setXMLSchema(IByteArray xmlSchema)
Description copied from interface: IXMLDataSet

Sets the XML Schema for the XML data that is used as the source of the data set.

Specified by:
setXMLSchema in interface IXMLDataSet
Parameters:
xmlSchema - the IByteArray object that specifies the XML schema that is used as the source of the data set

getXMLSchema

public IByteArray getXMLSchema()
Description copied from interface: IXMLDataSet

Gets the XML Schema for the XML data that is used as the source of the data set.

Specified by:
getXMLSchema in interface IXMLDataSet
Returns:
A IByteArray object that specifies the XML Schema for the XML data that is used as the source of the data set.

createMember

public java.lang.Object createMember(java.lang.String eleName,
                                     org.xml.sax.Attributes attrs,
                                     XMLSerializationContext ctxt,
                                     java.util.Map objState,
                                     boolean[] bLoaded)

For internal use only.


endElement

public void endElement(java.lang.String eleName,
                       java.util.Map objState)

For internal use only.


readElement

public void readElement(java.lang.String eleName,
                        java.lang.String sVal,
                        org.xml.sax.Attributes attrs,
                        java.util.Map objState)

For internal use only.


save

public void save(XMLWriter writer,
                 XMLSerializationContext ctxt)
          throws java.io.IOException

For internal use only.

Throws:
java.io.IOException

save

public void save(XMLWriter writer,
                 java.lang.String sTag,
                 XMLSerializationContext ctxt)
          throws java.io.IOException

For internal use only.

Throws:
java.io.IOException

saveContents

public void saveContents(XMLWriter writer,
                         XMLSerializationContext ctxt)
                  throws java.io.IOException

For internal use only.

Throws:
java.io.IOException

startElement

public void startElement(java.lang.String eleName,
                         java.util.Map objState,
                         org.xml.sax.Attributes attrs)

For internal use only.