Changeset 3516


Ignore:
Timestamp:
09/03/13 14:20:59 (11 years ago)
Author:
andmor
Message:

Using sloot.dpml.resolve-arguments endpoint to resolve the dpml arguments.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cats/SCHEMAcat/trunk/urn.org.isocat.schemacat.access.data/access/user.dpml

    r3514 r3516  
    1010        <!-- resolve the references in arg:arguments -->
    1111        <request assignment="arguments">
    12                 <identifier>active:xslt2</identifier>
    13                 <argument name="operand">arg:arguments</argument>
    14                 <argument name="operator">
    15                         <literal type="xml">
    16                                 <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    17                                         version="2.0">
    18                                         <xsl:param name="debug"/>
    19                                         <xsl:template match="@*|node()">
    20                                                 <xsl:copy>
    21                                                         <xsl:apply-templates select="@*|node()"/>
    22                                                 </xsl:copy>
    23                                         </xsl:template>
    24                                         <!-- skip over sloot-operator, which is this DPML script -->
    25                                         <xsl:template match="sloot-operator" priority="1"/>
    26                                         <xsl:template match="arguments/*">
    27                                                 <xsl:copy>
    28                                                         <xsl:apply-templates select="@*"/>
    29                                                         <xsl:variable name="val" select="unparsed-text(.)"/>
    30                                                         <xsl:if test="$debug">
    31                                                                 <xsl:message>DBG: <xsl:value-of select="name()"/>[<xsl:value-of select="."/>][<xsl:value-of select="$val"/>]</xsl:message>
    32                                                         </xsl:if>
    33                                                         <xsl:choose>
    34                                                                 <!-- snif if the value is XML -->
    35                                                                 <xsl:when test="matches(normalize-space($val),'&lt;.*&gt;')">
    36                                                                         <xsl:copy-of select="doc(.)"/>
    37                                                                 </xsl:when>
    38                                                                 <xsl:otherwise>
    39                                                                         <xsl:copy-of select="$val"/>
    40                                                                 </xsl:otherwise>
    41                                                         </xsl:choose>
    42                                                 </xsl:copy>
    43                                         </xsl:template>
    44                                 </xsl:stylesheet>
    45                         </literal>
    46                 </argument>
    47                 <argument name="debug">this:sloot-debug</argument>
     12                <identifier>active:sloot.dpml.resolve-arguments</identifier>
     13                <argument name="arguments">arg:arguments</argument>
    4814        </request>
    4915        <sloot-debug>
Note: See TracChangeset for help on using the changeset viewer.