Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

alma::acs::entityutil::EntitySerializer Class Reference

Collaboration diagram for alma::acs::entityutil::EntitySerializer:

Collaboration graph
[legend]
List of all members.

Public Member Functions

void setXmlEntityFactory (XmlEntityStructFactory esf)
XmlEntityStruct serializeEntity (Object entityObject, EntityT entityMeta) throws EntityException
XmlEntityStruct serializeEntity (Object entityObject) throws EntityException
String serializeEntityPart (Object entityPart) throws EntityException
void setVerbose (boolean verbose)

Static Public Member Functions

EntitySerializer getEntitySerializer (Logger logger)

Private Member Functions

 EntitySerializer (Logger logger)

Private Attributes

Logger m_logger
boolean m_verbose
XmlEntityStructFactory m_esf
EntityTFinder m_finder

Static Private Attributes

EntitySerializer s_entitySerializer

Detailed Description

Serializes entity objects. These are instances of binding classes that represent the XML data in a type-safe Java API. Currently all binding classes are generated using the Castor tool.

Author:
hsommer May 6, 2003 5:31:48 PM


Constructor & Destructor Documentation

alma::acs::entityutil::EntitySerializer::EntitySerializer Logger  logger  )  [inline, private]
 


Member Function Documentation

EntitySerializer alma::acs::entityutil::EntitySerializer::getEntitySerializer Logger  logger  )  [inline, static]
 

Singleton accessor.

Parameters:
logger Logger to be used (may be null in subsequent invocations since only one instance of EntitySerializer is constructed and then reused)
Returns:
single instance

XmlEntityStruct alma::acs::entityutil::EntitySerializer::serializeEntity Object  entityObject  )  throws EntityException [inline]
 

Marshals an entity object to the CORBA struct used for transport. Unlike in serializeEntity(Object, EntityT), the child of type EntityT that has the administrational information about the entity object, is not given as a parameter. It will be accessed dynamically using EntityTFinder, which makes this method slightly slower than its 2-parameter companion. It's meant to be used rather by generic code that doesn't know about particular entity classes.

Parameters:
entityObject the entity object as a binding class
Returns:
the struct that contains the stringified xml and some other data; null if entityObject is null.

XmlEntityStruct alma::acs::entityutil::EntitySerializer::serializeEntity Object  entityObject,
EntityT  entityMeta
throws EntityException [inline]
 

Marshals an entity object to the CORBA struct used for transport.

Parameters:
entityObject the entity object as a binding class, currently generated by castor.
entityMeta usually subtype of EntityT.
Returns:
the struct that contains the stringified xml and some other data; null if entityObject is null.

String alma::acs::entityutil::EntitySerializer::serializeEntityPart Object  entityPart  )  throws EntityException [inline]
 

Serializes a binding class object which is a part (child node) of some other full Entity object.

Parameters:
entityPart the binding object, e.g. of type alma.entity.xmlbinding.schedblock.CorrelatorConfigT.
Returns:
a plain XML String that represents the data of entityPart.
Exceptions:
EntityException if the operation could not be performed
See also:
serializeEntity(Object)

serializeEntity(Object, EntityT)

void alma::acs::entityutil::EntitySerializer::setVerbose boolean  verbose  )  [inline]
 

void alma::acs::entityutil::EntitySerializer::setXmlEntityFactory XmlEntityStructFactory  esf  )  [inline]
 

Makes this EntitySerializer use a client-supplied factory for XmlEntityStruct objects.

You should use this method if you wish to get a subclass of alma.xmlentity.XmlEntityStruct returned from the serializeEntity methods.

Parameters:
esf the factory to be used


Member Data Documentation

XmlEntityStructFactory alma::acs::entityutil::EntitySerializer::m_esf [private]
 

EntityTFinder alma::acs::entityutil::EntitySerializer::m_finder [private]
 

Logger alma::acs::entityutil::EntitySerializer::m_logger [private]
 

boolean alma::acs::entityutil::EntitySerializer::m_verbose [private]
 

EntitySerializer alma::acs::entityutil::EntitySerializer::s_entitySerializer [static, private]
 


The documentation for this class was generated from the following file:
Generated on Thu Apr 30 02:52:35 2009 for ACS Java API by doxygen 1.3.8