RXS_STR()

This subprocedure should be used inside an RXS_Parse() parsing subprocedure to convert the parsed data pointer into a character data field.

Subprocedure Prototype

     D RXS_STR         PR                  Extproc('RXS_STR') Opdesc
     D                                     Like(RXS_Var16Mv_t) Rtnparm

Returns the character data field extracted from the Pointer parameter.

     D   Pointer                       *   Const

Pointer containing character data parsed using an RXS_Parse() parsing subprocedure.

     D   PointerLen                  10I 0 Const

Length of the parsed character data contained in the Pointer parameter.

     D RXS_STR         PR                  Extproc('RXS_STR') Opdesc

     D   String                            Like(RXS_Var16Mv_t) Options(*Varsize)

The character data field extracted from the Pointer parameter.

     D   Pointer                       *   Const

Pointer containing character data parsed using an RXS_Parse() parsing subprocedure.

     D   PointerLen                  10I 0 Const

Length of the parsed character data contained in the Pointer parameter.

Example Code

      *--------------------------------------------------------------
      * This example code converts the contents of the pData pointer to character
      *  data and stores it in the field gCelcius.
      * This process may be used in a RXS_Parse() parsing subprocedure to convert data
      *  retrieved from an XML element to character data for further processing.
      *--------------------------------------------------------------
     H DFTACTGRP(*NO) BNDDIR('RXSBND') ACTGRP(*CALLER)

      /copy QRPGLECPY,RXSCB

     D gCelcius        S              5A   Varying
     D pData                           *   Value
     D pDataLen                      10I 0 Value
      /free
       gCelsius = RXS_STR( pData : pDataLen );

       *INLR = *ON;
      /end-free
      *--------------------------------------------------------------
      * This example code converts the contents of the pData pointer to character
      *  data and stores it in the field gCelcius.
      * This process may be used in a RXS_Parse() parsing subprocedure to convert data
      *  retrieved from an XML element to character data for further processing.
      *--------------------------------------------------------------
     H DFTACTGRP(*NO) BNDDIR('RXSBND') ACTGRP(*CALLER)

      /copy QRPGLECPY,RXSCB

     D gCelcius        S              5A   Varying
     D pData                           *   Value
     D pDataLen                      10I 0 Value
      /free
       RXS_STR( gCelcius : pData : pDataLen );

       *INLR = *ON;
      /end-free