interaction.xslt 980 B

123456789101112131415161718192021222324252627
  1. <!--
  2. Licensed Materials - Property of IBM
  3. IBM Cognos Products: cpscrn
  4. (C) Copyright IBM Corp. 2005, 2011
  5. US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  6. -->
  7. <!--
  8. Copyright (C) 2008 Cognos ULC, an IBM Company. All rights reserved.
  9. Cognos (R) is a trademark of Cognos ULC, (formerly Cognos Incorporated).
  10. -->
  11. <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
  12. <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="no"/>
  13. <xsl:template match="/">
  14. <response>
  15. <state>
  16. <xsl:variable name="states" select="/root/input[@name='stateParams']/stateParams/param"/>
  17. <xsl:for-each select="/root/interactions/param[@name = $states/@name]">
  18. <xsl:copy-of select="."/>
  19. </xsl:for-each>
  20. <xsl:copy-of select="/root/state/param[not(@name = /root/interactions/param/@name)]"/>
  21. </state>
  22. </response>
  23. </xsl:template>
  24. </xsl:stylesheet>