raccoon.tibco.tibrv.badhnati.ae
Class JavaToMessage

java.lang.Object
  extended by raccoon.tibco.tibrv.badhnati.ae.AbsParser
      extended by raccoon.tibco.tibrv.badhnati.ae.JavaToMessage

public class JavaToMessage
extends AbsParser

Converts a Java Bean instance to a TIB/Rendezvous message that complies with the Active Enterprise format.

Required Raccoon components:

Raccoon API Property (link to setter)
IBeanAnalyzer analyzer
IRepoGenerator repoGenerator
IFactory factory
IUtils utils

Since:
Raccoon v0.4, refactored in Raccoon v0.5, v0.7
Version:
$Id: JavaToMessage.java,v 1.3 2003/07/01 17:42:14 crouvrais Exp $
Author:
Cedric ROUVRAIS

Field Summary
 
Fields inherited from class raccoon.tibco.tibrv.badhnati.ae.AbsParser
mAnalyzer, mFactory, mLog, mRepoGenerator, mUtils
 
Constructor Summary
JavaToMessage()
          Default constructor, required for dynamic instanciation.
 
Method Summary
 IMessage generatePrefix(Message pObjects)
          Builds the prefix list for an Active Enterprise v3.0 compliant message.
 IMessage marshal(java.lang.Object pJavaBean)
          Converts a given java bean into an IBusMessage instance
 IMessage marshal(java.lang.Object pJavaBean, Message pObjects)
          Introspects the bean properties of a given object and puts the associated values into a TibrvMsg instance.
 
Methods inherited from class raccoon.tibco.tibrv.badhnati.ae.AbsParser
getAnalyzer, getFactory, getLog, getRepoGenerator, getUtils, setAnalyzer, setFactory, setLog, setRepoGenerator, setUtils
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JavaToMessage

public JavaToMessage()
Default constructor, required for dynamic instanciation.

Method Detail

marshal

public IMessage marshal(java.lang.Object pJavaBean)
                 throws RaccoonException
Converts a given java bean into an IBusMessage instance

Parameters:
pJavaBean - the java bean to convert.
Returns:
the IBusMessage corresponding to the java bean.
Throws:
RaccoonException - if the process fails.

marshal

public IMessage marshal(java.lang.Object pJavaBean,
                        Message pObjects)
                 throws RaccoonException
Introspects the bean properties of a given object and puts the associated values into a TibrvMsg instance.

Parameters:
pJavaBean - the java object instance to introspect.
pObjects - the list of objects referenced by the java object, filled in by this method.
Returns:
the TIB/Rendezvous message corresponding to the java object.
Throws:
RaccoonException - if the construction process fails.

generatePrefix

public IMessage generatePrefix(Message pObjects)
                        throws RaccoonException
Builds the prefix list for an Active Enterprise v3.0 compliant message.

Parameters:
pObjects - the list of referenced TIB/Repository directories (where the objects are located)
Returns:
the TibrvMsg message containing the prefix list.
Throws:
RaccoonException - if the construction process fails.


Copyright null null. All Rights Reserved.