net.sf.xbus.protocol
Class TransformerFactory

java.lang.Object
  extended by net.sf.xbus.protocol.TransformerFactory

public class TransformerFactory
extends java.lang.Object


Constructor Summary
TransformerFactory()
           
 
Method Summary
static Transformer createTransformer(XBUSSystem source, XBUSSystem destination, Message sourceMessage, Message destinationMessage)
          The appropriate Transformer object which is needed to transform the request or response of one Message to the request or response of another Message will be created.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TransformerFactory

public TransformerFactory()
Method Detail

createTransformer

public static Transformer createTransformer(XBUSSystem source,
                                            XBUSSystem destination,
                                            Message sourceMessage,
                                            Message destinationMessage)
                                     throws XException
The appropriate Transformer object which is needed to transform the request or response of one Message to the request or response of another Message will be created. First it is checked whether there is a special transformer configured for the two systems, if not, the standard transformer from xbus.conf is used.

Parameters:
source - the name of the interface definition of the source message
destination - the name of the interface definition of the destination message
sourceMessage - the message holding the data to be transformed
destinationMessage - the message receiving the transformed data
Returns:
the appropriate Transformer object
Throws:
XException - if something goes wrong