Skip to content

/AWS1/IF_SGM=>DESCRIBEJOBSCHEMAVERSION()

About DescribeJobSchemaVersion

Returns the JSON schema for a specified job category and schema version. Use this schema to validate your JobConfigDocument before calling CreateJob. If you don't specify a schema version, the latest version is returned. The schema defines required fields, allowed values, and constraints for the job configuration.

The following operations are related to DescribeJobSchemaVersion:

  • ListJobSchemaVersions

  • CreateJob

Method Signature

METHODS /AWS1/IF_SGM~DESCRIBEJOBSCHEMAVERSION
  IMPORTING
    !IV_JOBCATEGORY TYPE /AWS1/SGMJOBCATEGORY OPTIONAL
    !IV_JOBCONFIGSCHEMAVERSION TYPE /AWS1/SGMJOBSCHEMAVERSION OPTIONAL
  RETURNING
    VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_sgmdescrjobschvrsrsp
  RAISING
    /AWS1/CX_SGMRESOURCENOTFOUND
    /AWS1/CX_SGMCLIENTEXC
    /AWS1/CX_SGMSERVEREXC
    /AWS1/CX_RT_TECHNICAL_GENERIC
    /AWS1/CX_RT_SERVICE_GENERIC.

IMPORTING

Required arguments:

iv_jobcategory TYPE /AWS1/SGMJOBCATEGORY /AWS1/SGMJOBCATEGORY

The category of the job schema to describe.

Optional arguments:

iv_jobconfigschemaversion TYPE /AWS1/SGMJOBSCHEMAVERSION /AWS1/SGMJOBSCHEMAVERSION

The version of the schema to retrieve. If not specified, the latest version is returned.

RETURNING

oo_output TYPE REF TO /aws1/cl_sgmdescrjobschvrsrsp /AWS1/CL_SGMDESCRJOBSCHVRSRSP

Examples

Syntax Example

This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.

DATA(lo_result) = lo_client->describejobschemaversion(
  iv_jobcategory = |string|
  iv_jobconfigschemaversion = |string|
).

This is an example of reading all possible response values

lo_result = lo_result.
IF lo_result IS NOT INITIAL.
  lv_jobcategory = lo_result->get_jobcategory( ).
  lv_jobschemaversion = lo_result->get_jobconfigschemaversion( ).
  lv_jobconfigdocument = lo_result->get_jobconfigschema( ).
ENDIF.