LinkedIn
Copied!

Table of Contents

More about XML Stream rules

Results

Pega Platform does not check whether a document produced from applying an XML stream rule is well-formed, nor does it validate the document against a DTD or XSDL.

Accordingly, the document might contain simple text, and not contain angle bracket characters (< >) or other XML syntax. For example, you can create and write out a text file using an XML Stream rule, the Property-Set-XML method, and the WriteFileOutput() function.

XML editor

To include the value of a property, use the <pega:reference > JSP tag. In most cases, include the normal mode in each reference JSP tag. For example:

<pega:reference name="pyWorkpage.pyStatusWork" mode="normal" />

This causes stream processing to replace any < and > characters that may appear the corresponding entities &lt; and &gt;, and (unlike the default display mode) does not add a space before and after the property value.

If the property value contains XML markup, use the literal directive:

{literal TheXMLdoc }

or the equivalent literal mode for the reference tag:

<pega:reference name=".TheXMLdoc" mode="literal" />

These suppress stream processing of the value.

You can use other JSP tags (such as include, Java, and foreach) within the XML text. Processing of JSP tags in XML is identical to JSP tags in HTML.

Viewing the Java code of a rule

Click Actions > View Java to view the generated Java of a rule. You can use the Java code to debug your application or to examine how rules are implemented.

Parent class

The Rule-Obj-XML class is not derived from the Rule-Obj- abstract class. The immediate parent class of the Rule-Obj-XML class is the Rule-Stream class.

Example

For an example use of the XML form, see the Pega Community article How to create an XML document using XML Stream rules.

Related Content

Article

Introducing JavaServer Page tags
Did you find this content helpful?

Have a question? Get answers now.

Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.