ISO/IEC TR 24716:2007
(Main)Information technology — Programming languages, their environment and system software interfaces — Native COBOL Syntax for XML Support
Information technology — Programming languages, their environment and system software interfaces — Native COBOL Syntax for XML Support
ISO/IEC TR 24716:2007 specifies the syntax and semantics for XML support in COBOL. The purpose of ISO/IEC TR 24716:2007 is to promote a high degree of portability in implementations, even though some elements are subject to trial before completion of a final design suitable for standardization. This specification builds on the syntax and semantics defined in ISO/IEC 1989:2002.
Technologies de l'information — Langages de programmation, leur environnement et interfaces du logiciel système — Syntaxe COBOL native pour support XML
General Information
Standards Content (Sample)
TECHNICAL ISO/IEC
REPORT TR
First edition
2007-12-15
Information technology — Programming
languages, their environment and system
software interfaces — Native COBOL
Syntax for XML Support
Technologies de l'information — Langages de programmation, leur
environnement et interfaces du logiciel système — Syntaxe COBOL
native pour support XML
Reference number
©
ISO/IEC 2007
PDF disclaimer
This PDF file may contain embedded typefaces. In accordance with Adobe's licensing policy, this file may be printed or viewed but
shall not be edited unless the typefaces which are embedded are licensed to and installed on the computer performing the editing. In
downloading this file, parties accept therein the responsibility of not infringing Adobe's licensing policy. The ISO Central Secretariat
accepts no liability in this area.
Adobe is a trademark of Adobe Systems Incorporated.
Details of the software products used to create this PDF file can be found in the General Info relative to the file; the PDF-creation
parameters were optimized for printing. Every care has been taken to ensure that the file is suitable for use by ISO member bodies. In
the unlikely event that a problem relating to it is found, please inform the Central Secretariat at the address given below.
© ISO/IEC 2007
All rights reserved. Unless otherwise specified, no part of this publication may be reproduced or utilized in any form or by any means,
electronic or mechanical, including photocopying and microfilm, without permission in writing from either ISO at the address below or
ISO's member body in the country of the requester.
ISO copyright office
Case postale 56 • CH-1211 Geneva 20
Tel. + 41 22 749 01 11
Fax + 41 22 749 09 47
E-mail copyright@iso.org
Web www.iso.org
Published in Switzerland
ii © ISO/IEC 2007 – All rights reserved
Contents Page
Foreword. iv
Introduction . v
1 Scope.1
2 Normative references.1
3 Conformance to this Technical Report .1
4 Terms and definitions .1
5 Description techniques.2
6 Changes to ISO/IEC 1989:2002.2
6.1 Changes to 8, Language fundamentals .2
6.2 Changes to 9, I-O, objects, and user-defined functions.3
6.3 Changes to 12, Environment division .6
6.4 Changes to 13, Data division.8
6.5 Changes to 14, Procedure division.14
6.6 Changes to Annex F (informative) Substantive changes list .31
Annex A (normative) Language element lists .32
Annex B (informative) Unresolved technical issues.34
Annex C (informative) XML processing concepts .35
Bibliography .45
© ISO/IEC 2007 – All rights reserved iii
Foreword
ISO (the International Organization for Standardization) and IEC (the International Electrotechnical
Commission) form the specialized system for worldwide standardization. National bodies that are members of
ISO or IEC participate in the development of International Standards through technical committees
established by the respective organization to deal with particular fields of technical activity. ISO and IEC
technical committees collaborate in fields of mutual interest. Other international organizations, governmental
and non-governmental, in liaison with ISO and IEC, also take part in the work. In the field of information
technology, ISO and IEC have established a joint technical committee, ISO/IEC JTC 1.
International Standards are drafted in accordance with the rules given in the ISO/IEC Directives, Part 2.
The main task of the joint technical committee is to prepare International Standards. Draft International
Standards adopted by the joint technical committee are circulated to national bodies for voting. Publication as
an International Standard requires approval by at least 75 % of the national bodies casting a vote.
In exceptional circumstances, the joint technical committee may propose the publication of a Technical Report
of one of the following types:
— type 1, when the required support cannot be obtained for the publication of an International Standard,
despite repeated efforts;
— type 2, when the subject is still under technical development or where for any other reason there is the
future but not immediate possibility of an agreement on an International Standard;
— type 3, when the joint technical committee has collected data of a different kind from that which is
normally published as an International Standard (“state of the art”, for example).
Technical Reports of types 1 and 2 are subject to review within three years of publication, to decide whether
they can be transformed into International Standards. Technical Reports of type 3 do not necessarily have to
be reviewed until the data they provide are considered to be no longer valid or useful.
Attention is drawn to the possibility that some of the elements of this document may be the subject of patent
rights. ISO and IEC shall not be held responsible for identifying any or all such patent rights.
ISO/IEC TR 24716, which is a Technical Report of type 2, was prepared by Joint Technical Committee
ISO/IEC JTC 1, Information technology, Subcommittee SC 22, Programming languages, their environments
and system software interfaces, in collaboration with INCITS Techmical Committee J4, Programming
language COBOL.
iv © ISO/IEC 2007 – All rights reserved
Introduction
This Technical Report provides extensions so that COBOL can process XML documents as easily as it can
read files. The new syntax to process XML documents,
⎯ is based on the familiar approach used with COBOL I/O support,
⎯ provides Document Object Model (DOM) style parsing,
⎯ handles multiple input sources to handle XML in an extremely flexible manner,
⎯ reads, updates, and writes XML documents,
⎯ checks that XML documents are well-formed, and
⎯ provides an optional validity check of an XML document against a schema or Document Type Definition
(DTD).
Technical Report ISO/IEC 24716 extends the COBOL specification defined in ISO/IEC 1989:2002, Information
technology — Programming languages — COBOL. It provides new syntax to read, write, and update XML
documents in COBOL.
Annex A forms a normative part of this Technical Report. Annex B and Annex C and the Bibliography are for
information only.
© ISO/IEC 2007 – All rights reserved v
TECHNICAL REPORT ISO/IEC TR 24716:2007(E)
Information technology — Programming languages, their
environment and system software interfaces — Native COBOL
Syntax for XML Support
1 Scope
This Technical Report specifies the syntax and semantics for XML support in COBOL. The purpose of this
Technical Report is to promote a high degree of portability in implementations, even though some elements
are subject to trial before completion of a final design suitable for standardization.
This specification builds on the syntax and semantics defined in ISO/IEC 1989:2002.
2 Normative references
The following referenced documents are indispensable for the application of this document. For dated
references, only the edition cited applies. For undated references, the latest edition of the referenced
document (including any amendments) applies.
ISO/IEC 1989:2002, Information technology — Programming languages — COBOL
Extensible Markup Language (XML) 1.0 (Fourth Edition), W3C Recommendation, 16 August 2006
Extensible Markup Language (XML) 1.1 (Second Edition), W3C Recommendation, 16 August 2006
Namespaces in XML 1.1, W3C Recommendation, 4 February 2004
XML Schema Part 1: Structures, W3C Recommendation, 28 October 2004
XML Schema Part 2: Datatypes, W3C Recommendation, 28 October 2004
3 Conformance to this Technical Report
This Technical Report is based on ISO/IEC 1989:2002. Conformance to this Technical Report does not
require a full implementation of ISO/IEC 1989:2002. The interaction of the features of this technical report with
features that are not provided by an implementation of ISO/IEC 1989:2002 is processor dependent.
4 Terms and definitions
For the purposes of this document, the following terms and definitions apply.
4.1
document type definition
DTD
specification of the markup language that defines the elements, attributes, comments, and entities that a
document may contain and specifies the relationships among them within the document
4.2
external document type definition
external DTD
DTD that is outside the file containing the XML document
© ISO/IEC 2007 – All rights reserved 1
4.3
internal document type definition
internal DTD
DTD that is in the same file as the XML document
4.4
XML document
unit of data that is well-formed as defined either in XML 1.0 or XML 1.1
4.5
XML element
portion of an XML document, the boundaries of which are either delimited by start-tags and end-tags, or, for
empty elements, by an empty-element tag
NOTE Each element has a type, identified by name, and may have a set of attribute specifications.
4.6
XML file
file with XML organization
4.7
XML Schema
XML language for constructing schemas that describe the syntax of XML documents. Each schema defines a
class of XML documents by constraining the structures and data types of instance documents that conform to
the schema
5 Description techniques
Description techniques and language fundamentals are the same as those described in ISO/IEC 1989:2002.
6 Changes to ISO/IEC 1989:2002
These changes refer to clause and rule numbers in ISO/IEC 1989:2002.
6.1 Changes to 8, Language fundamentals
[a] Add the following reserved words to the list in 8.9, Reserved Words
DOCUMENT
END-OPEN
IDENTIFIED
VERSION-XML
[b] In 8.10, Context-sensitive words, change the context for ATTRIBUTE to read:
"IDENTIFIED clause, DELETE statement, READ statement, REWRITE statement, SET statement,
START statement, and WRITE statement"
[c] In 8.10, Context-sensitive words, change the context for ONLY to read:
"Object-view, SHARING clause of the file control entry, SHARING phrase of the OPEN statement,
USAGE clause, READ statement, REWRITE statement, and WRITE statement"
[d] Add the following context-sensitive words to the list in 8.10, Context-sensitive words
CHECK TYPE clause of the file control entry
DISCARD CLOSE statement
DTD TYPE clause of the file control entry
ELEMENT DELETE statement, READ statement, REWRITE statement, START
statement, and WRITE statement
2 © ISO/IEC 2007 – All rights reserved
NAMESPACE IDENTIFIED clause
RAW IDENTIFIED clause
SCHEMA TYPE clause of the file control entry
STACK OPEN statement
VALIDITY TYPE clause of the file control entry
XML ACCESS clause and ORGANIZATION clause
6.2 Changes to 9, I-O, objects, and user-defined functions
[a] 9.1.3, File connector, second paragraph, second sentence, add "XML" to the end of the list of types of file
organization in the parenthetical and to the end of the list of access modes in the parenthetical.
[b] 9.1.6, Fixed file attributes, change the third sentence to read:
"The file organizations are sequential, relative, indexed, and XML."
[c] 9.1.7, Organization,
[1] Change the first sentence to read:
"The file organizations are sequential, relative, indexed, and XML."
[2] add 9.1.7.4, XML, as follows:
"9.1.7.4 XML
XML is a file organization used for data that is in the format of an XML document or a sequence of XML
documents. An XML document can be on a traditional file medium or it can be in memory. An XML document
is a string of text that is given a structure by the presence of tags, which separate the document into elements.
XML documents are organized in a hierarchical manner, similar to a COBOL record structure, where an
element may contain other elements. Within the context of its superordinate elements, each subordinate
element may be stored, retrieved, or deleted based on its tag name. The element position vector for an XML
file associates an element position or an attribute position with each data item for which an IDENTIFIED
clause is specified.
COBOL allows multiple documents in a file that is open in the input, output, or extend mode. COBOL allows
only one document in a file that is open in the i-o mode. The XML 1.0 and 1.1 recommendations do not
consider the processing of anything beyond a single document. Therefore, many XML processors might not
consider multiple-document files to be well-formed.
The file format OPEN statement for an XML file establishes a connection to the phys
...
Questions, Comments and Discussion
Ask us and Technical Secretary will try to provide an answer. You can facilitate discussion about the standard in here.