Hear from Salesforce leaders on how to create and deploy Agentforce agents.
Contact Us 1-800-596-4880

XML to Object Transformer Reference

You can use an XML to Object transformer to transform XML data to a Java Object (also referred to as Java Bean graphs) using XStream.

Minimum Configuration: The name of the XStream driver class.

An XML-to-Object transformer transforms XML data using the specified XStream driver class.

In addition to the properties common to all transformers, you can also specify class aliases and converters.

Configuring XML to Object

Tabs:

  • General - Specify or browse to the XStream driver class:

    XML2Object
  • Advanced - Optionally configure the properties standard to all transformers, plus add or change class aliases and class converters.

    XML2ObjectAdv
    • Use the Aliases pane to create, edit, or delete aliases for specific classes.

    • Use the Converters pane to create, edit, or delete class converters.

Code Example

The following example converts XML to Object passed to Groovy for processing. The results are logged.

xml to object ref