Creating a channel description document

Create a channel description document when your service provider application uses a channel interface with many containers.

About this task

Use an XML editor to create the channel description document. The schema for the channel description is called channel.xsd and is in the /usr/lpp/cicsts/ cicsts54 /schemas/channel directory (where /usr/lpp/cicsts/ cicsts54 is the default install directory for CICS files on CICS® UNIX).

Procedure

  1. Create an XML document with a <channel> element and the CICS channel namespace:
    <channel name="myChannel"
    xmlns="http://www.ibm.com/xmlns/prod/CICS/channel">
    </channel>
  2. Add a <container> element for every container that the application program interface uses on the channel.
    You must use name, type and use attributes to describe each container.
    The following example shows six containers with different attribute values:
    <container name="cont1" type="char" use="required"/>
    <container name="cont2" type="char" use="optional"/>
    <container name="cont3" type="bit" use="required"/>
    <container name="cont4" type="bit" use="optional"/>
    <container name="cont5" type="bit" use="required">
    <structure location="//HLQ.PDSNAME(MEMBER)"/>
    </container>
    <container name="cont6" type="bit" use="optional">
    <structure location="//HLQ.PDSNAME(MEMBER2)"/>
    </container> 
    The structure element indicates that the content is defined in a language structure located in a partitioned data set member.
  3. Save the XML document in z/OS UNIX.

Channel schema

The channel description document must conform to the following schema:

				<schema xmlns="http://www.w3.org/2001/XMLSchema"
				targetNamespace="http://www.ibm.com/xmlns/prod/CICS/channel"
				xmlns:tns="http://www.ibm.com/xmlns/prod/CICS/channel"
				elementFormDefault="qualified">
				<element name="channel">
				 1 
				<complexType>
				<sequence>
				<element name="container" maxOccurs="unbounded" "unbounded" minOccurs="0">
				 2 
				<complexType>
				<sequence>
				<element name="structure" minOccurs="0">
				 3 
				<complexType>
				<attribute name="location" type="string" use="required"/>
				<attribute name="structure" type="string" use="optional"/>
				</complexType>
				</element>
				</sequence>
				<attribute name="name" type="tns:name16Type" use="required"/>
				<attribute name="type" type="tns:typeType" use="required"/>
				<attribute name="use" type="tns:useType" use="required"/>
				</complexType>
				</element>
				</sequence>
				<attribute name="name" type="tns:name16Type" use="optional" />
				</complexType>
				</element>
				<simpleType name="name16Type">
				<restriction base="string">
				<maxLength value="16"/>
				</restriction>
				</simpleType>
				<simpleType name="typeType">
				<restriction base="string">
				<enumeration value="char"/>
				<enumeration value="bit"/>
				</restriction>
				</simpleType>
				<simpleType name="useType">
				<restriction base="string">
				<enumeration value="required"/>
				<enumeration value="optional"/>
				</restriction>
				</simpleType>
				</schema>
			
  1. This element represents a CICS channel.
  2. This element represents a CICS container within the channel.
  3. A structure can only be used with 'bit' mode containers. The 'location' attribute indicates the location of a file that maps the contents of container. The 'structure' attribute may be used in C and C++ to indicate the name of structure.

What to do next

Run DFHLS2JS to create the mappings and JSON schema for the web service provider application. DFHLS2JS puts the mappings for the channel in the JSON schema in the order that the containers are specified in the channel description document.