Event transformation rules change an event from one type to another. They are processed in a slightly different order according to the channel, but the names of the attributes and classes are in the eDirectory name space.
There are no required transformations that an event transformation style sheet must perform. They can be used for the following:
The DirXML engine processes the event transformation rule according to the channel:
The event transformation rules are kept in an DirXML-Rule object and associated with your driver through the DirXML-EventTransformationRule attribute of your driver's DirXML-Publisher and DirXML-Subscriber objects.
The following sample is and event transformation for the subscriber channel that limits the scope of events.
<?xml version="1.0" encoding="UTF-8"?><!--
This stylesheet is and event transformation for the
subscriber channel that limits the scope of events.
-->
<xsl:transform version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="input/*[@src-dn]">
<xsl:variable name="src-dn" select="string(@src-dn)"/>
<xsl:if test= "starts-with($src-dn,’\TREE\novell\Provo\’) or
starts-with($src-dn,’\TREE\novell\San Jose\’) or
starts-with($src-dn,’\TREE\novell\Orem\’) or
starts-with($src-dn,’\TREE\novell\Unknown Location\’) ">
<xsl:copy>
<xsl:apply-templates select="@*|node()"/>
</xsl:copy>
</xsl:if>
</xsl:template>
<!-- identity template for everything we don’t specifically handle -->
<xsl:template match="node()|@*">
<xsl:copy>
<xsl:apply-templates select="@*|node()"/>
</xsl:copy>
</xsl:template>
</xsl:transform>