Page last modified 16:48, 24 Mar 2022 by Jussi

.xmlData()

    Table of contents

    Description of the method

     

    Description: xmlData method returns all data from element children, with XML-tags stripped out.
    Available for: any
    Parameters: -
    Return type: string

    Example

     

    Context: HeaderType1
    OCL: self.xmlData().contains('2015')
    Description: The example rule checks whether any element within the header contains value "2015".

     

    The XML snippet below would pass this check.

    <Header>
      <Id>aId</Id>
      <TimeStamp>2015-07-03T12:17:50</TimeStamp>
      <ControlSum>2</ControlSum>
      <NumberOfTransactions>1</NumberOfTransactions>
    </Header>


    Method xmlData seels the following XML as follors:

    aId
    2015-07-03T12:17:50
    2
    1
    Menu