Topic
2 replies Latest Post - ‏2013-05-06T07:06:39Z by skc5559
skc5559
skc5559
13 Posts
ACCEPTED ANSWER

Pinned topic How to get the name of Files under a datapower Directory

‏2013-05-02T05:21:22Z |

Hi,

I have a requirement wherein I need to get the names of file (not the content) present under a directory in datapower.

Could you please let me know if any XSL function or datapower extension function can do this?

As we know DP doesn't support XSL 2.0 so I can go for any EXSLT functions.

 

  • HermannSW
    HermannSW
    4138 Posts
    ACCEPTED ANSWER

    Re: How to get the name of Files under a datapower Directory

    ‏2013-05-02T10:07:18Z  in response to skc5559

    Hi,

    this SOMA request gives you the complete "local:" filestore:

    $ cat get-filestore-local.xml
    <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
      <env:Body>
        <dp:request domain="default"
          xmlns:dp="http://www.datapower.com/schemas/management">
          <dp:get-filestore location="local:"/>
        </dp:request>
      </env:Body>
    </env:Envelope>
    $
     

    If you apply XPath expression "/*/*/*/*/location" on the response you will get all directory and file information.

     

    Hermann<myXsltBlog/> <myXsltTweets/> <myCE/>

    • skc5559
      skc5559
      13 Posts
      ACCEPTED ANSWER

      Re: How to get the name of Files under a datapower Directory

      ‏2013-05-06T07:06:39Z  in response to HermannSW
      Thanx a ton Hermann !, It works and rocks !!!