java.lang.Object
org.openehealth.ipf.platform.camel.ihe.xds.core.converters.XdsRenderingUtils

public abstract class XdsRenderingUtils extends Object
Utility class for rendering of ebXML stub POJOs and simplified XDS model classes into XML.
Author:
Dmytro Rud
  • Method Summary

    Modifier and Type
    Method
    Description
    static String
    doRender(Exchange exchange, Object body)
    Renders an XDS object (either ebXML POJO or an object from the simplified model).
    static String
    render(Exchange exchange)
    Renders an XDS object (either ebXML POJO or an object from the simplified model) contained in the input message of given Camel exchange.
    static String
    render(Exchange exchange, Closure<?> closure)
    Renders an XDS object (either ebXML POJO or an object from the simplified model) contained in the given Camel exchange.
    static String
    render(Exchange exchange, Expression expression)
    Renders an XDS object (either ebXML POJO or an object from the simplified model) contained in the given Camel exchange.
    static String
    Returns marshaled XML representation of the given ebXML POJO.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • render

      public static String render(Exchange exchange)
      Renders an XDS object (either ebXML POJO or an object from the simplified model) contained in the input message of given Camel exchange.
      Parameters:
      exchange - Camel exchange containing the XDS object in exchange.in.body.
      Returns:
      XML representation of the XDS object contained in the given Camel exchange.
    • render

      public static String render(Exchange exchange, Closure<?> closure)
      Renders an XDS object (either ebXML POJO or an object from the simplified model) contained in the given Camel exchange.
      Parameters:
      exchange - Camel exchange containing the XDS object.
      closure - Groovy closure to extract the XDS object from the exchange.
      Returns:
      XML representation of the XDS object contained in the given Camel exchange.
    • render

      public static String render(Exchange exchange, Expression expression)
      Renders an XDS object (either ebXML POJO or an object from the simplified model) contained in the given Camel exchange.
      Parameters:
      exchange - Camel exchange containing the XDS object.
      expression - Camel expression to extract the XDS object from the exchange.
      Returns:
      XML representation of the XDS object contained in the given Camel exchange.
    • doRender

      public static String doRender(Exchange exchange, Object body)
      Renders an XDS object (either ebXML POJO or an object from the simplified model).
      Parameters:
      exchange - Camel exchange.
      body - XDS object (either ebXML POJO or an object from the simplified model).
      Returns:
      XML representation of the given XDS object.
    • renderEbxml

      public static String renderEbxml(Object ebXml)
      Returns marshaled XML representation of the given ebXML POJO.
      Parameters:
      ebXml - ebXML POJO.
      Returns:
      XML string representing the given POJO.