org.wso2.carbon.rule.kernel.internal.util
Class DataBindUtil
java.lang.Object
org.wso2.carbon.rule.kernel.internal.util.DataBindUtil
public class DataBindUtil
- extends Object
|
Method Summary |
static Object |
getValue(org.apache.axiom.om.OMElement omElement,
Class type)
utility method convert the OMElements to java objects. |
static org.apache.axiom.om.OMElement |
toOM(Object object,
QName parentQname)
Utility method to convert the java objects to OMElements |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DataBindUtil
public DataBindUtil()
toOM
public static org.apache.axiom.om.OMElement toOM(Object object,
QName parentQname)
- Utility method to convert the java objects to OMElements
- Parameters:
object - - POJO object to be converted to an OMElementparentQname - - Top element QName for this POJO object
- Returns:
- - corresponding OMElement for POJO Object
getValue
public static Object getValue(org.apache.axiom.om.OMElement omElement,
Class type)
throws org.wso2.carbon.rule.common.exception.RuleRuntimeException
- utility method convert the OMElements to java objects.
- Parameters:
omElement - - OMElement to be used to get the POJO object valuetype - - class name of the POJO element to be created
- Returns:
- - the created fact object
- Throws:
org.wso2.carbon.rule.common.exception.RuleRuntimeException - - if there is a problem in creating POJO object
Copyright © 2015 WSO2. All rights reserved.