com.epam.fixml.converter
Class AbstractFIXMLConverter

java.lang.Object
  extended by com.epam.fixml.converter.AbstractFIXMLConverter
All Implemented Interfaces:
FIXMLConverter
Direct Known Subclasses:
FIXML41Converter, FIXML42Converter, FIXML43Converter, FIXML44Converter, FIXML50Converter, FIXML50SP1Converter, FIXML50SP2Converter

public abstract class AbstractFIXMLConverter
extends Object
implements FIXMLConverter


Field Summary
 
Fields inherited from interface com.epam.fixml.converter.FIXMLConverter
DEFAULT_ENCODING
 
Constructor Summary
AbstractFIXMLConverter(FIXVersion fixVersion)
           
 
Method Summary
 com.epam.fixml.converter.FIXMLConverterData convertToFIX(InputStream inputStream)
          Converts byte stream of FIXML message to list of FIX messages.
 com.epam.fixml.converter.FIXMLConverterData convertToFIX(InputStream inputStream, String encoding)
          Converts byte stream of FIXML message to list of FIX messages.
 com.epam.fixml.converter.FIXMLConverterData convertToFIX(Reader reader)
          Converts char stream of FIXML message to list of FIX messages.
 com.epam.fixml.converter.FIXMLConverterData convertToFIX(Reader reader, String encoding)
          Converts char stream of FIXML message to list of FIX messages.
 com.epam.fixml.converter.FIXMLConverterData convertToFIX(String str)
          Converts FIXML message string to list of FIX messages.
 com.epam.fixml.converter.FIXMLConverterData convertToFIX(String str, String encoding)
          Converts FIXML message string to list of FIX messages.
 com.epam.fixml.converter.FIXMLConverterData convertToFIX(XMLReader xmlReader, InputSource inputSource)
          Converts FIXML message to list of FIX messages using specified instances of XML parser and input source.
 String convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData)
          Converts FIX messages to FIXML message string.
 void convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData, ContentHandler contentHandler)
          Converts FIX messages to FIXML message using specified XML serializer.
 void convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData, OutputStream outputStream)
          Converts FIX messages to FIXML message byte stream.
 void convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData, OutputStream outputStream, String encoding)
          Converts FIX messages to FIXML message byte stream.
 String convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData, String encoding)
          Converts FIX messages to FIXML message string.
 void convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData, Writer writer)
          Converts FIX messages to FIXML message char stream.
 void convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData, Writer writer, String encoding)
          Converts FIX messages to FIXML message char stream.
 FIXVersion getFIXVersion()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.epam.fixml.converter.FIXMLConverter
convertToFIX, convertToFIXML
 

Constructor Detail

AbstractFIXMLConverter

public AbstractFIXMLConverter(FIXVersion fixVersion)
Method Detail

getFIXVersion

public FIXVersion getFIXVersion()

convertToFIX

public com.epam.fixml.converter.FIXMLConverterData convertToFIX(String str)
                                                         throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts FIXML message string to list of FIX messages.

Specified by:
convertToFIX in interface FIXMLConverter
Parameters:
str - the string representation of the FIXML message.
Returns:
list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
Throws:
FIXMLConverterException - if FIXML message cannot be parsed of FIX message cannot be composed.

convertToFIX

public com.epam.fixml.converter.FIXMLConverterData convertToFIX(String str,
                                                                String encoding)
                                                         throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts FIXML message string to list of FIX messages.

Specified by:
convertToFIX in interface FIXMLConverter
Parameters:
str - the string representation of the FIXML message.
encoding - encoding of incoming content
Returns:
list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
Throws:
FIXMLConverterException - if FIXML message cannot be parsed of FIX message cannot be composed.

convertToFIX

public com.epam.fixml.converter.FIXMLConverterData convertToFIX(Reader reader)
                                                         throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts char stream of FIXML message to list of FIX messages.

Specified by:
convertToFIX in interface FIXMLConverter
Parameters:
reader - the char stream representation of the FIXML message.
Returns:
list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
Throws:
FIXMLConverterException - if FIXML message cannot be parsed of FIX message cannot be composed.

convertToFIX

public com.epam.fixml.converter.FIXMLConverterData convertToFIX(Reader reader,
                                                                String encoding)
                                                         throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts char stream of FIXML message to list of FIX messages.

Specified by:
convertToFIX in interface FIXMLConverter
Parameters:
reader - the char stream representation of the FIXML message.
encoding - encoding of incoming content
Returns:
list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
Throws:
FIXMLConverterException - if FIXML message cannot be parsed of FIX message cannot be composed.

convertToFIX

public com.epam.fixml.converter.FIXMLConverterData convertToFIX(InputStream inputStream)
                                                         throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts byte stream of FIXML message to list of FIX messages.

Specified by:
convertToFIX in interface FIXMLConverter
Parameters:
inputStream - the byte stream representation of the FIXML message.
Returns:
list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
Throws:
FIXMLConverterException - if FIXML message cannot be parsed of FIX message cannot be composed.

convertToFIX

public com.epam.fixml.converter.FIXMLConverterData convertToFIX(InputStream inputStream,
                                                                String encoding)
                                                         throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts byte stream of FIXML message to list of FIX messages.

Specified by:
convertToFIX in interface FIXMLConverter
Parameters:
inputStream - the byte stream representation of the FIXML message.
encoding - encoding of incoming content
Returns:
list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
Throws:
FIXMLConverterException - if FIXML message cannot be parsed of FIX message cannot be composed.

convertToFIX

public com.epam.fixml.converter.FIXMLConverterData convertToFIX(XMLReader xmlReader,
                                                                InputSource inputSource)
                                                         throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts FIXML message to list of FIX messages using specified instances of XML parser and input source. If the instance of the converter is shared between different threads then different instances of XML parser must be used.

Specified by:
convertToFIX in interface FIXMLConverter
Parameters:
xmlReader - the instance of SAX2 XML parser.
inputSource - the input source of FIXML message.
Returns:
list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
Throws:
FIXMLConverterException - if FIXML message cannot be parsed or FIX message cannot be composed.

convertToFIXML

public String convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData,
                             String encoding)
                      throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts FIX messages to FIXML message string.

Specified by:
convertToFIXML in interface FIXMLConverter
Parameters:
fixmlConverterData - the list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
encoding - encoding of incoming content
Returns:
the string representation of FIXML message.
Throws:
FIXMLConverterException - if message cannot be converted to the FIXML message.

convertToFIXML

public String convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData)
                      throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts FIX messages to FIXML message string.

Specified by:
convertToFIXML in interface FIXMLConverter
Parameters:
fixmlConverterData - the list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
Returns:
the string representation of FIXML message.
Throws:
FIXMLConverterException - if message cannot be converted to the FIXML message.

convertToFIXML

public void convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData,
                           Writer writer,
                           String encoding)
                    throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts FIX messages to FIXML message char stream.

Specified by:
convertToFIXML in interface FIXMLConverter
Parameters:
fixmlConverterData - the list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
writer - the writer of char stream representation of FIXML message.
encoding - encoding of incoming content
Throws:
FIXMLConverterException - if message cannot be converted to the FIXML message.

convertToFIXML

public void convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData,
                           Writer writer)
                    throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts FIX messages to FIXML message char stream.

Specified by:
convertToFIXML in interface FIXMLConverter
Parameters:
fixmlConverterData - the list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
writer - the writer of char stream representation of FIXML message.
Throws:
FIXMLConverterException - if message cannot be converted to the FIXML message.

convertToFIXML

public void convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData,
                           OutputStream outputStream,
                           String encoding)
                    throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts FIX messages to FIXML message byte stream.

Specified by:
convertToFIXML in interface FIXMLConverter
Parameters:
fixmlConverterData - the list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
outputStream - the writer of byte stream representation of FIXML message.
encoding - encoding of incoming content
Throws:
FIXMLConverterException - if message cannot be converted to the FIXML message.

convertToFIXML

public void convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData,
                           OutputStream outputStream)
                    throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts FIX messages to FIXML message byte stream.

Specified by:
convertToFIXML in interface FIXMLConverter
Parameters:
fixmlConverterData - the list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
outputStream - the writer of byte stream representation of FIXML message.
Throws:
FIXMLConverterException - if message cannot be converted to the FIXML message.

convertToFIXML

public void convertToFIXML(com.epam.fixml.converter.FIXMLConverterData fixmlConverterData,
                           ContentHandler contentHandler)
                    throws com.epam.fixml.converter.FIXMLConverterException
Description copied from interface: FIXMLConverter
Converts FIX messages to FIXML message using specified XML serializer.

Specified by:
convertToFIXML in interface FIXMLConverter
Parameters:
fixmlConverterData - the list of FIX messages with preparsed attributes for the FIXML and Batch elements and name spaces for the FIXML element.
contentHandler - the XML serializer.
Throws:
FIXMLConverterException - if FIX message is invalid or FIXML message cannot be composed.


Copyright © 2000-2012 EPAM Systems. All Rights Reserved.