com.metamatrix.common.types
Class XMLType

java.lang.Object
  extended by com.metamatrix.common.types.XMLType
All Implemented Interfaces:
Streamable, java.io.Serializable, java.sql.SQLXML

public final class XMLType
extends java.lang.Object
implements Streamable, java.sql.SQLXML

This class represents the SQLXML object along with the Streamable interface. This is class used everywhere in the MetaMatrix framework, but clients are restricted to use only SQLXML interface on top of this.

See Also:
Serialized Form

Field Summary
 
Fields inherited from interface com.metamatrix.common.types.Streamable
FORCE_STREAMING, STREAMING_BATCH_SIZE_IN_BYTES
 
Constructor Summary
XMLType()
           
XMLType(java.sql.SQLXML xml)
           
 
Method Summary
 boolean equals(java.lang.Object o)
           
 void free()
           
 java.io.InputStream getBinaryStream()
           
 java.io.Reader getCharacterStream()
           
 java.lang.String getPersistenceStreamId()
          Persitence Stream ID in the server
 java.lang.String getReferenceStreamId()
          Reference Stream ID in the server
<T extends javax.xml.transform.Source>
T
getSource(java.lang.Class<T> sourceClass)
           
 java.sql.SQLXML getSourceSQLXML()
           
 java.lang.String getString()
           
 java.io.OutputStream setBinaryStream()
           
 java.io.Writer setCharacterStream()
           
 void setPersistenceStreamId(java.lang.String id)
          Persitence Stream ID in the server
 void setReferenceStreamId(java.lang.String id)
          Reference Stream ID in the server
<T extends javax.xml.transform.Result>
T
setResult(java.lang.Class<T> resultClass)
           
 void setString(java.lang.String value)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

XMLType

public XMLType()

XMLType

public XMLType(java.sql.SQLXML xml)
Method Detail

getSourceSQLXML

public java.sql.SQLXML getSourceSQLXML()

getReferenceStreamId

public java.lang.String getReferenceStreamId()
Description copied from interface: Streamable
Reference Stream ID in the server

Specified by:
getReferenceStreamId in interface Streamable
Returns:
string - this is buffer managers tuple source id.

setReferenceStreamId

public void setReferenceStreamId(java.lang.String id)
Description copied from interface: Streamable
Reference Stream ID in the server

Specified by:
setReferenceStreamId in interface Streamable
Parameters:
id - this is buffer managers tuple source id.

getPersistenceStreamId

public java.lang.String getPersistenceStreamId()
Description copied from interface: Streamable
Persitence Stream ID in the server

Specified by:
getPersistenceStreamId in interface Streamable
Returns:
string - this is buffer managers tuple source id.

setPersistenceStreamId

public void setPersistenceStreamId(java.lang.String id)
Description copied from interface: Streamable
Persitence Stream ID in the server

Specified by:
setPersistenceStreamId in interface Streamable
Parameters:
id - this is buffer managers tuple source id.

getBinaryStream

public java.io.InputStream getBinaryStream()
                                    throws java.sql.SQLException
Specified by:
getBinaryStream in interface java.sql.SQLXML
Throws:
java.sql.SQLException

getCharacterStream

public java.io.Reader getCharacterStream()
                                  throws java.sql.SQLException
Specified by:
getCharacterStream in interface java.sql.SQLXML
Throws:
java.sql.SQLException

getSource

public <T extends javax.xml.transform.Source> T getSource(java.lang.Class<T> sourceClass)
                                               throws java.sql.SQLException
Specified by:
getSource in interface java.sql.SQLXML
Throws:
java.sql.SQLException

getString

public java.lang.String getString()
                           throws java.sql.SQLException
Specified by:
getString in interface java.sql.SQLXML
Throws:
java.sql.SQLException

setBinaryStream

public java.io.OutputStream setBinaryStream()
                                     throws java.sql.SQLException
Specified by:
setBinaryStream in interface java.sql.SQLXML
Throws:
java.sql.SQLException

setCharacterStream

public java.io.Writer setCharacterStream()
                                  throws java.sql.SQLException
Specified by:
setCharacterStream in interface java.sql.SQLXML
Throws:
java.sql.SQLException

setString

public void setString(java.lang.String value)
               throws java.sql.SQLException
Specified by:
setString in interface java.sql.SQLXML
Throws:
java.sql.SQLException

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

free

public void free()
          throws java.sql.SQLException
Specified by:
free in interface java.sql.SQLXML
Throws:
java.sql.SQLException

setResult

public <T extends javax.xml.transform.Result> T setResult(java.lang.Class<T> resultClass)
                                               throws java.sql.SQLException
Specified by:
setResult in interface java.sql.SQLXML
Throws:
java.sql.SQLException


Copyright © 2009. All Rights Reserved.