org.apache.synapse.config.xml
Class MediatorPropertySerializer

java.lang.Object
  extended by org.apache.synapse.config.xml.MediatorPropertySerializer

public class MediatorPropertySerializer
extends Object

A utility class for serializing instances of MediatorProperty objects by reading through a given XML configuration

 <element>
    <property name="string" (value="literal" | expression="xpath")/>*
 </element>
 


Field Summary
protected static OMFactory fac
           
protected static OMNamespace nullNS
           
protected static QName PROP_Q
           
protected static OMNamespace synNS
           
 
Constructor Summary
MediatorPropertySerializer()
           
 
Method Summary
static void serializeMediatorProperties(OMElement parent, Collection<MediatorProperty> props)
          Serialize all the properties to the given paren element.
static void serializeMediatorProperties(OMElement parent, Collection<MediatorProperty> props, QName childElementName)
          Serialize all the properties to the given paren element.
static void serializeMediatorProperty(OMElement parent, MediatorProperty mp)
          Serialize the property to the given paren element.
static void serializeMediatorProperty(OMElement parent, MediatorProperty mp, QName childElementName)
          Serialize the property to the given paren element.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

fac

protected static final OMFactory fac

synNS

protected static final OMNamespace synNS

nullNS

protected static final OMNamespace nullNS

PROP_Q

protected static final QName PROP_Q
Constructor Detail

MediatorPropertySerializer

public MediatorPropertySerializer()
Method Detail

serializeMediatorProperties

public static void serializeMediatorProperties(OMElement parent,
                                               Collection<MediatorProperty> props)
Serialize all the properties to the given paren element. For each and every property ther will be a seperate property element created inside the parent element.

Parameters:
parent - element to which property elements should be added
props - Collection of propertis

serializeMediatorProperties

public static void serializeMediatorProperties(OMElement parent,
                                               Collection<MediatorProperty> props,
                                               QName childElementName)
Serialize all the properties to the given paren element. For each and every property ther will be a seperate element with the given name created inside the parent element.

Parameters:
parent - element to which property elements should be added
props - Collection of propertis
childElementName - QNmae of the property element to be created

serializeMediatorProperty

public static void serializeMediatorProperty(OMElement parent,
                                             MediatorProperty mp)
Serialize the property to the given paren element. There will be a element created with the name property inside the parent element.

Parameters:
parent - element to which property elements should be added
mp - a property to be serialized

serializeMediatorProperty

public static void serializeMediatorProperty(OMElement parent,
                                             MediatorProperty mp,
                                             QName childElementName)
Serialize the property to the given paren element. There will be a element created with given name inside the parent element.

Parameters:
parent - element to which property elements should be added
mp - a property to be serialized
childElementName - QName of the element to be created


Copyright © 2005-2012 Apache Software Foundation. All Rights Reserved.