diff --git a/file-formats/edoi/README.md b/file-formats/edoi/README.md new file mode 100644 index 000000000..4061063fc --- /dev/null +++ b/file-formats/edoi/README.md @@ -0,0 +1,5 @@ +# EDOI File Format + +File | Cardinality | Definition | Schema | Example +:--- | :--- | :--- | :--- | :--- +`.edoi.json` | 1 | [`zif_aff_edoi_v1.intf.abap`](./type/zif_aff_edoi_v1.intf.abap) | [`edoi-v1.json`](./edoi-v1.json) diff --git a/file-formats/edoi/edoi-v1.json b/file-formats/edoi/edoi-v1.json new file mode 100644 index 000000000..804b5c354 --- /dev/null +++ b/file-formats/edoi/edoi-v1.json @@ -0,0 +1,190 @@ +{ + "$comment": "This file is autogenerated, do not edit manually, see https://github.com/SAP/abap-file-formats for more information.", + "$schema": "https://json-schema.org/draft/2020-12/schema", + "$id": "https://github.com/SAP/abap-file-formats/blob/main/file-formats/edoi/edoi-v1.json", + "title": "eDocument Interface", + "description": "eDocument interface", + "type": "object", + "properties": { + "formatVersion": { + "title": "Format Version", + "description": "Format version", + "type": "string", + "const": "1" + }, + "header": { + "title": "Header", + "description": "Header", + "type": "object", + "properties": { + "description": { + "title": "Description", + "description": "Description of the ABAP object", + "type": "string", + "maxLength": 100 + }, + "originalLanguage": { + "title": "Original Language", + "description": "Original language of the ABAP object", + "type": "string", + "minLength": 2 + }, + "abapLanguageVersion": { + "title": "ABAP Language Version", + "description": "ABAP language version", + "type": "string", + "enum": [ + "standard", + "cloudDevelopment" + ], + "enumTitles": [ + "Standard", + "ABAP Cloud Development" + ], + "enumDescriptions": [ + "Standard", + "ABAP cloud development" + ], + "default": "standard" + } + }, + "additionalProperties": false, + "required": [ + "description", + "originalLanguage" + ] + }, + "generalInformation": { + "title": "General Information", + "description": "General information", + "type": "object", + "properties": { + "interfaceDirection": { + "title": "Interface Direction", + "description": "Interface direction.", + "type": "string", + "enum": [ + "outbound", + "inbound" + ], + "enumTitles": [ + "Outbound", + "Inbound" + ], + "enumDescriptions": [ + "Outbound", + "Inbound" + ], + "default": "outbound" + } + }, + "additionalProperties": false, + "required": [ + "interfaceDirection" + ] + }, + "interfaceVersion": { + "title": "Interface Version", + "description": "Interface version", + "type": "array", + "uniqueItems": true, + "items": { + "title": "Interface Version", + "description": "eDocument interface version", + "type": "object", + "properties": { + "interfaceVersion": { + "title": "Interface Version", + "description": "Interface version", + "type": "string", + "maxLength": 4 + }, + "interfaceVersionDescription": { + "title": "Interface Version Description", + "description": "Interface dersion description", + "type": "string", + "maxLength": 30 + }, + "activeFrom": { + "title": "Active From", + "description": "Active from", + "type": "string", + "format": "date-time" + } + }, + "additionalProperties": false, + "required": [ + "interfaceVersion", + "interfaceVersionDescription", + "activeFrom" + ] + } + }, + "edocSpecAdditionalTable": { + "title": "Attribute Determination for Communication with Cloud Edition", + "description": "Attribute determination for communication with cloud edition", + "type": "array", + "uniqueItems": true, + "items": { + "title": "Attribute Determination for Communication with Cloud Edition", + "description": "Attribute determination for communication with cloud edition", + "type": "object", + "properties": { + "processType": { + "title": "Process Type", + "description": "DRC process type", + "type": "string", + "maxLength": 50 + }, + "processVersion": { + "title": "Process Version", + "description": "DRC process version", + "type": "string", + "maxLength": 20 + }, + "processSubtype": { + "title": "Process Subtype", + "description": "DRC process subtype", + "type": "string", + "maxLength": 50 + }, + "drcAction": { + "title": "Action", + "description": "DRC process action", + "type": "string", + "maxLength": 30 + }, + "responseInterfaceId": { + "title": "Response Interface", + "description": "eDoc response interface", + "type": "string", + "maxLength": 30 + }, + "responseInterfaceVersion": { + "title": "Response Interface Version", + "description": "Response interface version", + "type": "string", + "maxLength": 4 + } + }, + "additionalProperties": false, + "required": [ + "processType", + "processVersion", + "processSubtype", + "drcAction", + "responseInterfaceId", + "responseInterfaceVersion" + ] + } + } + }, + "additionalProperties": false, + "required": [ + "formatVersion", + "header", + "generalInformation", + "interfaceVersion", + "edocSpecAdditionalTable" + ] +} diff --git a/file-formats/edoi/type/zif_aff_edoi_v1.intf.abap b/file-formats/edoi/type/zif_aff_edoi_v1.intf.abap new file mode 100644 index 000000000..c5cb6272e --- /dev/null +++ b/file-formats/edoi/type/zif_aff_edoi_v1.intf.abap @@ -0,0 +1,111 @@ +INTERFACE zif_aff_edoi_v1 PUBLIC. + + "!

Interface Direction

+ "! Interface direction + "! $values {@link zif_aff_edoi_v1.data:co_edoc_int_direction} + "! $default {@link zif_aff_edoi_v1.data:co_edoc_int_direction.outbound} + TYPES ty_int_direction TYPE c LENGTH 1. + TYPES: + "!

Interface Version

+ "! eDocument interface version + BEGIN OF ty_edoc_interface_version, + "!

Interface Version

+ "! Interface version + "! $required + interface_version TYPE c LENGTH 4, + "!

Interface Version Description

+ "! Interface dersion description + "! $required + interface_version_description TYPE c LENGTH 30, + "!

Active From

+ "! Active from + "! $required + active_from TYPE sy-datum, + END OF ty_edoc_interface_version. + "!

Interface Versions

+ "! eDocument interface versions + TYPES ty_edoc_interface_versions TYPE SORTED TABLE OF ty_edoc_interface_version WITH UNIQUE KEY interface_version. + TYPES: + "!

Attribute Determination for Communication with Cloud Edition

+ "! Attribute determination for communication with cloud edition + BEGIN OF ty_edoc_int_drc_attr, + "!

Process Type

+ "! DRC process type + "! $required + process_type TYPE c LENGTH 50, + "!

Process Version

+ "! DRC process version + "! $required + process_version TYPE c LENGTH 20, + "!

Process Subtype

+ "! DRC process subtype + "! $required + process_subtype TYPE c LENGTH 50, + "!

Action

+ "! DRC process action + "! $required + drc_action TYPE c LENGTH 30, + "!

Response Interface

+ "! eDoc response interface + "! $required + response_interface_id TYPE c LENGTH 30, + "!

Response Interface Version

+ "! Response interface version + "! $required + response_interface_version TYPE c LENGTH 4, + + END OF ty_edoc_int_drc_attr. + "!

Interface Versions

+ "! eDocument interface versions + TYPES ty_edoc_int_drc_attributes TYPE SORTED TABLE OF ty_edoc_int_drc_attr WITH UNIQUE KEY process_type. + + CONSTANTS: + "!

Interface Direction

+ "! Interface direction + BEGIN OF co_edoc_int_direction, + "!

Outbound

+ "! Outbound + outbound TYPE ty_int_direction VALUE 'O', + "!

Inbound

+ "! Inbound + inbound TYPE ty_int_direction VALUE 'I', + END OF co_edoc_int_direction. + + TYPES: + "!

General Information

+ "! General information + BEGIN OF ty_edoc_interface, + "!

Interface Direction

+ "! Interface direction. + "! $required + interface_direction TYPE ty_int_direction, + END OF ty_edoc_interface. + + TYPES: + "!

eDocument Interface

+ "! eDocument interface + BEGIN OF ty_main, + "!

Format Version

+ "! Format version + "! $required + format_version TYPE zif_aff_types_v1=>ty_format_version, + "!

Header

+ "! Header + "! $required + header TYPE zif_aff_types_v1=>ty_header_100_cloud, + "!

General Information

+ "! General information + "! $required + general_information TYPE ty_edoc_interface, + "!

Interface Version

+ "! Interface version + "! $required + interface_version TYPE ty_edoc_interface_versions, + "!

Attribute Determination for Communication with Cloud Edition

+ "! Attribute determination for communication with cloud edition + "! $required + edoc_spec_additional_table TYPE ty_edoc_int_drc_attributes, + + END OF ty_main. + +ENDINTERFACE. diff --git a/file-formats/edoi/type/zif_aff_edoi_v1.intf.json b/file-formats/edoi/type/zif_aff_edoi_v1.intf.json new file mode 100644 index 000000000..77d2b8841 --- /dev/null +++ b/file-formats/edoi/type/zif_aff_edoi_v1.intf.json @@ -0,0 +1,7 @@ +{ + "formatVersion": "1", + "header": { + "description": "Create eDocument Types", + "originalLanguage": "en" + } +}