GXL1QXD (GXL4QXD) — query an XML document

Description

This service allows a caller to obtain the XML characteristics of a document. The XML characteristics are either the default values, the values contained in an XML declaration or a combination of both.

Performance Implications

There are no performance implications.

Syntax

call gxl1qxd,(work_area,
             work_area_length,
             input_buffer,
             input_buffer_length,
             return_data,
             return_code,
             reason_code)   

Parameters

work_area
Supplied parameter
Type:
Character string
Length:
Variable

The name of a work area. The work area must be aligned on a doubleword boundary. If not on a doubleword boundary, results are unpredictable. See the Usage notes below for additional details on the use of this area.

work_area_len
Supplied parameter
Type:
Integer
Length:
Fullword (Doubleword)

The name of an area containing the length of the work area. The minimum length of this area is declared as a constant XEC_MIN_QXDWORK_SIZE in macro GXLYXEC. This service validates the length of this area against this minimum length value.

input_buffer
Supplied parameter
Type:
Character string
Length:
Variable

The name of an input buffer containing the beginning of the XML document to process. See the Usage notes below for details.

input_buffer_length
Supplied parameter
Type:
Integer
Length:
Fullword (Doubleword)

The name of an area containing the length of the input buffer.

return_data
Returned parameter
Type:
Address
Length:
Fullword (Doubleword)

The name of a fullword (doubleword) where the service will return the address of the data which describes the XML document characteristics. This return information will contain values that are either extracted from the XML declaration or defaulted according to the XML standard. This return area is mapped by macro GXLYQXD (see gxlhqxd.h (GXLYQXD) - mapping of the output from the query XML declaration service), and is located within the work area specified by the work_area parameter. The caller must not free the work_area until it is done referencing the data returned from this service.

return_code
Returned parameter
Type:
Integer
Length:
Fullword

The name of a fullword where the service stores the return code.

reason_code
Returned parameter
Type:
Integer
Length:
Fullword

The name of a fullword where the service stores the reason code. The reason code is only relevant if the return code is not XRC_SUCCESS.

All parameters in the parameter list are required.

Return and Reason Codes:

On return from a call to this service, register 15 will contain the return code. The return and reason code are both set as output parameters. The value of the reason code is undefined when the return code has no associated reasons. Return and reason codes are defined in macro GXLYXR (see gxlhxr.h (GXLYXR) - defines the return codes and reason codes). For reason code descriptions, also see Reason codes listed by value.

Example

Usage notes