com.legstar.coxb.transform
Interface IHostXmlTransformers

All Known Implementing Classes:
AbstractXmlTransformers

public interface IHostXmlTransformers

Alternative to IHostTransformers which works on XML rather than java object.

Classes implementing this interface can transform XML to mainframe data streams and vice versa.


Method Summary
 byte[] toHost(Source source)
          Transforms XML source to host data.
 byte[] toHost(Source source, HostTransformStatus status)
          Transforms XML source to host data.
 byte[] toHost(Source source, String hostCharset)
          Transforms XML source to host data with a specific host character set.
 byte[] toHost(Source source, String hostCharset, HostTransformStatus status)
          Transforms XML source to host data with a specific host character set.
 void toXml(byte[] hostData, Writer writer)
          Transforms host data to XML.
 void toXml(byte[] hostData, Writer writer, HostTransformStatus status)
          Transforms host data to XML.
 void toXml(byte[] hostData, Writer writer, String hostCharset)
          Transforms host data to XML using a specific host character set.
 void toXml(byte[] hostData, Writer writer, String hostCharset, HostTransformStatus status)
          Transforms host data to XML using a specific host character set.
 

Method Detail

toHost

byte[] toHost(Source source,
              String hostCharset)
              throws HostTransformException
Transforms XML source to host data with a specific host character set.

Parameters:
source - the XML Source to unmarshal XML data from (such as SAXSource, DOMSource, and StreamSource)
hostCharset - the host character set
Returns:
a byte array with host data
Throws:
HostTransformException - if transformation fails

toHost

byte[] toHost(Source source)
              throws HostTransformException
Transforms XML source to host data.

Parameters:
source - the XML Source to unmarshal XML data from (such as SAXSource, DOMSource, and StreamSource)
Returns:
a byte array with host data
Throws:
HostTransformException - if transformation fails

toXml

void toXml(byte[] hostData,
           Writer writer,
           String hostCharset)
           throws HostTransformException
Transforms host data to XML using a specific host character set.

Parameters:
hostData - a byte array containing host data
writer - XML will be sent to this writer.
hostCharset - the host character set
Throws:
HostTransformException - if transformation fails

toXml

void toXml(byte[] hostData,
           Writer writer)
           throws HostTransformException
Transforms host data to XML.

Parameters:
hostData - a byte array containing host data
writer - XML will be sent to this writer.
Throws:
HostTransformException - if transformation fails

toHost

byte[] toHost(Source source,
              String hostCharset,
              HostTransformStatus status)
              throws HostTransformException
Transforms XML source to host data with a specific host character set.

Parameters:
source - the XML Source to unmarshal XML data from (such as SAXSource, DOMSource, and StreamSource)
hostCharset - the host character set
status - will contain information on the transformation after it is executed
Returns:
a byte array with host data
Throws:
HostTransformException - if transformation fails

toHost

byte[] toHost(Source source,
              HostTransformStatus status)
              throws HostTransformException
Transforms XML source to host data.

Parameters:
source - the XML Source to unmarshal XML data from (such as SAXSource, DOMSource, and StreamSource)
status - will contain information on the transformation after it is executed
Returns:
a byte array with host data
Throws:
HostTransformException - if transformation fails

toXml

void toXml(byte[] hostData,
           Writer writer,
           String hostCharset,
           HostTransformStatus status)
           throws HostTransformException
Transforms host data to XML using a specific host character set.

Parameters:
hostData - a byte array containing host data
writer - XML will be sent to this writer.
hostCharset - the host character set
status - will contain information on the transformation after it is executed
Throws:
HostTransformException - if transformation fails

toXml

void toXml(byte[] hostData,
           Writer writer,
           HostTransformStatus status)
           throws HostTransformException
Transforms host data to XML.

Parameters:
hostData - a byte array containing host data
writer - XML will be sent to this writer.
status - will contain information on the transformation after it is executed
Throws:
HostTransformException - if transformation fails


Copyright © 2015 LegSem. All Rights Reserved.