Skip to end of metadata
Go to start of metadata

This object allows you to execute a variety of API calls directly to CICS.   It follows the structure and naming protocol of standard mainframe EXEC CICS API calls and returns the same information that you would get if you executed those commands in a mainframe program.

General Format

The general format for specifying this object is:

Cics.exec.method( o )

where method is the name of the actual EXEC CICS API in lowercase (example, EXEC CICS ASSIGN would equate to a method of assign) and o is a JavaScript object that contains the one argument: a list of input properties for the API call, also in lowercase.  When an API call is executed, the results are placed as properties in the same object.  

For specification of a method with more than one word, the standard JavaScript naming conventions are used (INQUIRE TERMINAL would be specified as inquireTerminal).

Following is a code sample that shows how to specify any of the calls:


/*
  The following example shows how to read a record in a VSAM ESDS (EXEC CICS READ) but can be adapted for any request
*/


var o = {};    // define the object that will contain the parameter list; this must be specified even if there are no input parameters

/*
  Following is a sample of how to fill out the input object for any request
  In this case the first line shows a string property, the second shows a Boolean property, and the third a numeric property
  The Boolean input property equates to specifying RBA in the EXEC CICS READ command; this is used for any property that does not have a value but is specified by name 
  Note that some of the numeric properties represent what is called a CVDA value by IBM documentation:  The number returned represents a specific state or condition, which  
  will be documented in the appropriate IBM manual and section (see links in the individual methods). 
*/

var o = {
  file : "ESDSSAMP",
  rba : true,
  ridfld : 0
};

var cics = new Cics();

try
{
	cics.exec.readFile ( o ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln ( e );
	writeln("(",e.respText,",",e.resp2,")");
	for ( i in e )
	{
		writeln( i,"=",e[i] );
	}
}

writeln( o.into ); // write out the value of an output property
writeln("**End of Sample**"),


The following summary gives a brief description of each method, the input and output properties that are valid for each, and a short example code snippet to show how each can be specified. 

For more detail on the meanings of each method and its properties, you should consult the IBM CICS documentation (Application Programming Reference and/or Systems Programming Reference) for the release of CICS that you are currently running.  You can also refer to the following table for valid CVDA values inputted or outputted by various methods: CICS CVDA values in numerical order.

In the following summary, only those methods and properties that are currently supported by HostBridge are included. If you need support for any additional Cics.exec methods and/or properties, you should contact HostBridge Support.

There are other methods that are handled with another object within HostBridge. They are asktime(), asktime1900(), asktime1970(), delay(), deleteTsQ(), eib(), readTdQ(), readTsQ(), writeTdQ(), and writeTsQ(). These methods are included in this document with a link to to the correct HostBridge object.


Method Summary 

Methods

asktime()

Description:  Request current date and time of day. 

Link to correct documentation:  Cics.asktime()  

asktime1900()

Description:  Request current date and time of day, based on the number of milliseconds since 12:00am on January 1, 1900.   

Link to correct documentation:  Cics.asktime1900()  

asktime1970()

Description:  Request current date and time of day, based on the number of milliseconds since 12:00am on January 1, 1900.   

Link to correct documentation: Cics.asktime1970()  

assign()  

Description:  Request values from outside the local environment of the application program.  

Properties:  

NameTypeMaximum LengthInput/Output
abcodeString4Output
abdumpString1Output
abprogramString8Output
applidString8Output
asraintrptString8Output
asrakeyCVDA
Output
asrapswString8Output
asraregsString64Output
asraspcCVDA
Output
asrastgCVDA
Output
bridgeString4Output
channelString16Output
cmdsecString1Output
cwalengNumeric
Output
delimiterString1Output
fciString1Output
initparmString60Output
invokingprogString8Output
langinuseString3Output
natlanginuseString1Output
opclaseString24Output
opidString3Output
orgabcodeString4Output
programString8Output
qnameString4Output
ressecString1Output
restartString1Output
returnprogString8Output
startcodeString2Output
sysidString4Output
taskpriorityNumeric
Output
tctualengNumeric
Output
termpriorityNumeric
Output
twalengNumeric
Output
useridString8Output
usernameString20Output
userpriorityNumeric
Output


Corresponding CICS Command Level API command reference:  EXEC CICS ASSIGN

Example: 


var o = {};

Cics.exec.assign( o );


/*
 * To access a single property 
 */

writeln('\tSys id = ', o.sysid, '\n');

/*
 * Iterate over all of the properties
 */
for (var prop in o) {
	writeln('\t', prop, ' = ', o[prop]);
}



When using the EXEC CICS ASSIGN command in a command level program, you are allowed to select what properties you wish returned. In the HB.js invocation, all supported properties are returned to the provided object and can be accessed as needed.


cancel()

Description:  Cancel interval control requests.

Propertiess:

NameTypeMaximum LengthInput/Output
reqidString8Input
sysidString4Input
transidString4Input

Corresponding CICS Command Level API command: EXEC CICS CANCEL

Example: 


var cancelProperties = { 
  reqid : "12345678",
  sysid = "ABCD",
  transid = "CEMT" 
}

Cics.exec.cancel ( cancelProperties ) ; 


changePassword()

Description:  Change the password recorded by an external security manager (ESM) for a specified user ID.

Properties:

NameType

Naximum Length

Input/Output
esmreasonNumeric
Output
esmrespNumeric
Output
newpasswordString8Input
passwordString8Input
useridString8Input

Corresponding CICS Command Level API command: EXEC CICS CHANGE PASSWORD

Example:

var changePasswordProperties = { 
  newpassword : "newpass",
  password = "oldpass",
  userid = "myuserid" 
}

Cics.exec.changePassword ( changePasswordProperties ) ; 


writeln( changePasswordProperties.esmreason ); 
writeln( changePasswordProperties.esmresp ); 


changePhrase()

Description:  Change the passphrase recorded by an external security manager (ESM) for a specified user ID.

Properties:

NameType

Naximum Length

Input/Output
esmreasonNumeric
Output
esmrespNumeric
Output
newphraseString100Input
newphraselenNumeric
Input
phraseString100Input
phraselenNumeric
Input
useridString8Input

Corresponding CICS Command Level API command: EXEC CICS CHANGE PHRASE

Example:

var changePhraseProperties = { 
  newphrase : "this is a new passphrase",
  phrase = "this is an old passphrase",
  userid = "myuserid" 
}

/*
 *  phraselen and newphraselen will be calculated if not specified
 */

Cics.exec.changePhrase ( changePasswordPhrase ) ; 


writeln( changePhraseProperties.esmreason ); 
writeln( changePhraseProperties.esmresp ); 


collectStatistics()

Description:  Retrieve the current statistics for a single resource, or global statistics for a class of resources.

Parameters:  See note below.

Corresponding CICS Command Level API command: EXEC CICS COLLECT STATISTICS

This method is CICS Release specific and requires intervention by HostBridge technical staff for you to use it; please contact HostBridge Support if you need to use this method.


createFile()

Description:  Defines a transient data queue in the local CICS region.

Properties:

NameTypeMaximum LengthInput/Output
attributesString32767Input
attrlenNumeric
Input
fileString8Input
logmessageCVDA
Input

Corresponding CICS Command Level API command: EXEC CICS CREATE FILE

Example: 

var cics = new Cics();
var createFile = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 * For logmessage, 54 indicates LOG and 55 indicates NOLOG
 */
var createFile = {
	 attributes : "DESCRIPTION(YOURFILE Description)",
	 attrlen : 33,
	 file : "YOURFILE",
	 logmessage : 55
}
/*
 * Create the file
 */
try
{
	cics.exec.createFile ( createFile ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}

createTDQueue()

Description:  Defines a transient data queue in the local CICS region.

Properties:

NameTypeMaximum LengthInput/Output
attributesString32767Input
attrlenNumeric
Input
logmessageCVDA
Input
tdqueueString4Input

Corresponding CICS Command Level API command: EXEC CICS CREATE TDQUEUE

Example: 

var cics = new Cics();
var createTDQ = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 * For logmessage, 54 indicates LOG and 55 indicates NOLOG 
 */
var createTDQ = {
	 attributes : "TYPE(INTRA)",
	 attrlen : 11,
	 tdqueue : "BLI4",
	 logmessage : 55
	}
/*
 * Create the TD QUEUE
 */
try
{
	cics.exec.createTDQueue ( createTDQ ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}

delay()

Description:  Delay the processing of a task.

Link to correct documentation: Cics.delay()  

deleteContainerChannel()

Description:  Delete a named channel container.

Properties:

NameTypeMaximum LengthInput/Output
channelString16Input
containerString16Input

Corresponding CICS Command Level API command: EXEC CICS DELETE CONTAINER

Example:

var cics = new Cics();
var deleteContainerChannel = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 */
var deleteContainerChannel = {
	 channel : "YOURCHANNELNAME",
	 container : "YOURCONTAINERNAM"
	}
/*
 * Delete the channel within the specified container
 */
try
{
	cics.exec.deleteContainerChannel ( deleteContainerChannel ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}

deleteFile()

Description:   Delete a record from a VSAM KSDS, VSAM RRDS or data table.

Properties:

NameTypeMaximum LengthInput/OutputNotes
fileString8Input
genericBoolean
InputKSDS only
keylengthNumeric
Input
nosuspendBoolean
InputData table only
numrecNumeric
InputKSDS only
rbaBoolean
InputKSDS only
ridfldString255InputNumeric for RRDS
rrnBoolean
InputRRDS only
sysidString4Input
tokenNumeric
Input

Corresponding CICS Command Level API command: EXEC CICS DELETE FILE

Example: 

var cics = new Cics();
var deleteFile = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 */
var deleteFile = { 
  file : "YOURDD",
  ridfld : "YOURKEY",
  keylength : 7,
  generic : true  
}
/*
 * Delete the record or records within a file
 */
try
{
	cics.exec.deleteFile ( deleteFile ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}

deleteTsQ()

Description:  Delete a temporary storage queue.

Link to correct documentation: Cics.deleteTsQ()  

deq()

Description:  Schedule use of a resource by a task (dequeue).

Propoerties:

NameTypeMaximum LengthInput/Output
lengthNumeric
Input
maxlifetimeCVDA
Input
resourceString255Input

Corresponding CICS Command Level API command: EXEC CICS DEQ

Example: 

var cics = new Cics();
var deq = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 * For maxlifetime, 233 indicates TASK and 246 indicates UOW
 */
var deq = {
	 length : 8,
	 maxlifetime : 233,
	 resource : "DEQNAME1"
}
/*
 * Dequeue the resource
 */
try
{
	cics.exec.deq ( deq ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}

discardAutinstmodel()

Description:  Remove a terminal autoinstall model definition.

Properties:

NameTypeMaximum LengthInput/Output
autinstmodelString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD AUTINSTMODEL

Example: 

var cics = new Cics();
var discardAutinstmodel = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardAutinstmodel = {
	 autinstmodel : "MODNAME1"
}
/*
 * Discard the autoinstall model
 */
try
{
	cics.exec.discardAutinstmodel ( discardAutinstmodel ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardConnection()

Description:  Remove a CONNECTION definition.

Properties:

NameTypeMaximum LengthInput/Output
connectionString4Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD CONNECTION

Example: 

var cics = new Cics();
var discardConnection = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardConnection = {
	 connection : "CON1"
}
/*
 * Discard the connection
 */
try
{
	cics.exec.discardConnection ( discardConnection ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardCorbaServer()

Description:  Remove the definition of a CorbaServer from the system, together with any associated deployed JAR files and beans.

Properties:

NameTypeMaximum LengthInput/Output
corbaserverString4Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD CORBASERVER

Example: 

var cics = new Cics();
var discardCorbaServer = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardCorbaServer = {
	 corbaserver : "COR1"
}
/*
 * Discard the CorbaServer
 */
try
{
	cics.exec.discardCorbaServer ( discardCorbaServer ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

This command is only valid for CICS TS release 4.2 and prior.

discardDb2conn()

Description:  Remove a DB2CONN definition.

Properties:

NameTypeMaximum LengthInput/Output
db2connString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD DB2CONN

Example: 

var cics = new Cics();
var discardDb2conn = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardDb2conn = {
	 db2conn : "DB2CONN1"
}
/*
 * Discard the DB2CONN
*/
try
{
	cics.exec.discardDb2conn ( discardDb2conn ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardDb2entry()

Description:  Remove a DB2ENTRY definition.

Properties:

NameTypeMaximum LengthInput/Output
db2entryString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD DB2ENTRY

Example: 

var cics = new Cics();
var discardDb2entry = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardDb2entry = {
	 db2entry : "DB2ENTR1"
}
/*
 * Discard the DB2ENTRY
*/
try
{
	cics.exec.discardDb2entry ( discardDb2entry ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardDb2Tran()

Description:  Remove a DB2TRAN definition.

Properties:

NameTypeMaximum LengthInput/Output
db2tranString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD DB2TRAN

Example: 

var cics = new Cics();
var discardDb2tran = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardDb2tran = {
	 db2tran : "DB2TRAN1"
}
/*
 * Discard the DB2TRAN
*/
try
{
	cics.exec.discardDb2tran ( discardDb2tran ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardDoctemplate()

Description:  Remove a document template.

Properties:

NameTypeMaximum LengthInput/Output
doctemplateString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD DOCTEMPLATE

Example: 

var cics = new Cics();
var discardDoctemplate = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardDoctemplate = {
	 doctemplate : "DOCTEMP1"
}
/*
 * Discard the DOCTEMPLATE
*/
try
{
	cics.exec.discardDoctemplate( discardDoctemplate ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardEnqmodel()

Description:  Remove an ENQMODEL resource definition.

Properties:

NameTypeMaximum LengthInput/Output
enqmodelString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD ENQMODEL

Example: 

var cics = new Cics();
var discardEnqmodel = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardEnqmodel = {
	 enqmodel : "ENQMOD1"
}
/*
 * Discard the ENQMODEL
*/
try
{
	cics.exec.discardEnqmodel ( discardEnqmodel ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardFile()

Description:  Remove a FILE definition.

Properties:

NameTypeMaximum LengthInput/Output
fileString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD FILE

Example: 

var cics = new Cics();
var discardFile = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardFile = {
	 file : "DDNAME01"
}
/*
 * Discard the file
*/
try
{
	cics.exec.discardFile ( discardFile ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}  

discardIpconn()

Description:  Remove an IPCONN definition.

Properties:

NameTypeMaximum LengthInput/Output
ipconnString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD IPCONN

Example: 

var cics = new Cics();
var discardIpconn = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardIpconn = {
	 ipconn : "IPCONN01"
}
/*
 * Discard the IPCONN
*/
try
{
	cics.exec.discardIpconn ( discardIpconn ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardJournalmodel()

Description:  Remove a journal model definition.

Properties:

NameTypeMaximum LengthInput/Output
journalmodelString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD JOURNALMODEL

Example: 

var cics = new Cics();
var discardJournalModel = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardJournalModel = {
	 journalmodel : "JOURNMOD"
}
/*
 * Discard the JOURNALMODEL
*/
try
{
	cics.exec.discardJournalmodel ( discardJournalModel ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardJournalname()

Description:  Remove a journal name from the journal names table.

Properties:

NameTypeMaximum LengthInput/Output
journalnameString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD JOURNALNAME

Example: 

var cics = new Cics();
var discardJournalName = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardJournalName = {
	 journalmodel : "JOURNNAM"
}
/*
 * Discard the JOURNALNAME
*/
try
{
	cics.exec.discardJournalname ( discardJournalName ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardLibrary()

Description:  Remove a specified LIBRARY from the running CICS system.

Properties:

NameTypeMaximum LengthInput/Output
libraryString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD LIBRARY

Example: 

var cics = new Cics();
var discardLibrary = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardLibrary = {
	 library : "LIBRARY1"
}
/*
 * Discard the LIBRARY
*/
try
{
	cics.exec.discardLibrary ( discardLibrary ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardPartner()

Description:  Remove a PARTNER definition.

Properties:

NameTypeMaximum LengthInput/Output
partnerString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD PARTNER

Example: 

var cics = new Cics();
var discardPartner = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardPartner = {
	 partner : "PARTNER1"
}
/*
 * Discard the PARTNER
*/
try
{
	cics.exec.discardPartner ( discardPartner ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardPipeline()

Description:  Remove a PIPELINE definition.

Properties:

NameTypeMaximum LengthInput/Output
pipelineString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD PIPELINE

Example: 

var cics = new Cics();
var discardPipeline = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardPipeline = {
	 pipeline : "PIPELIN1"
}
/*
 * Discard the PIPELINE
*/
try
{
	cics.exec.discardPipeline ( discardPipeline ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardProcesstype()

Description:  Remove a PROCESSTYPE definition.

Properties:

NameTypeMaximum LengthInput/Output
processtypeString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD PROCESSTYPE

Example: 

var cics = new Cics();
var discardProcesstype = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardProcesstype = {
	 processtype : "PROCTYP1"
}
/*
 * Discard the PROCESSTYPE
*/
try
{
	cics.exec.discardProcesstype ( discardProcesstype ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardProfile()

Description:  Remove a PROFILE definition.

Properties:

NameTypeMaximum LengthInput/Output
profileString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD PROFILE

Example: 

var cics = new Cics();
var discardProfile = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardProfile = {
	 db2tran : "PROFILE1"
}
/*
 * Discard the PROFILE
*/
try
{
	cics.exec.discardProfile ( discardProfile ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardProgram()

Description:  Remove the definition of a program, map set, or partition set.

Properties:

NameTypeMaximum LengthInput/Output
programString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD PROGRAM

Example: 

var cics = new Cics();
var discardProgram = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardProgram = {
	 db2tran : "PROGRAM1"
}
/*
 * Discard the PROGRAM
*/
try
{
	cics.exec.discardProgram ( discardProgram ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 


discardTcpipservice()

Description:  Remove a TCPIPSERVICE definition.

Properties:

NameTypeMaximum LengthInput/Output
tcpipserviceString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD TCPIPSERVICE

Example: 

var cics = new Cics();
var discardTcpipservice = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardTcpipservice = {
	 tcpipservice : "TCPSERV1"
}
/*
 * Discard the TCPIPSERVICE
*/
try
{
	cics.exec.discardTcpipservice ( discardTcpipservice ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardTdqueue()

Description:  Remove a transient data queue definition.

Properties:

NameTypeMaximum LengthInput/Output
tdqueueString4Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD TDQUEUE

Example: 

var cics = new Cics();
var discardTdqueue = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardTdqueue = {
	 tdqueue : "TDQ1"
}
/*
 * Discard the TDQUEUE
*/
try
{
	cics.exec.discardTdqueue ( discardTdqueue ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardTerminal()

Description:  Remove a TERMINAL definition.

Properties:

NameTypeMaximum LengthInput/Output
terminalString4Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD TERMINAL

Example: 

var cics = new Cics();
var discardTerminal = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardTerminal = {
	 terminal : "TRM1"
}
/*
 * Discard the TERMINAL
*/
try
{
	cics.exec.discardTerminal ( discardTerminal ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardTranclass()

Description:  Remove a transaction class definition.

Properties:

NameTypeMaximum LengthInput/Output
tranclassString8Input

In earlier releases of CICS, transaction classes were numbered from 1 through 10 rather than named, as they are now, and class definitions were implicit rather than explicit. For compatibility, CICS supplies definitions for the numbered classes, named ‘DFHTCLnn’, where nn is the 2-digit class number. You can discard a numbered class by using the associated name for the TRANCLASS value (DFHTCL01 for class 1, for example).


Corresponding CICS Command Level API command: EXEC CICS DISCARD TRANCLASS

Example: 

var cics = new Cics();
var discardTranclass = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardTranclass = {
	 tranclass : "DFHTCL01"
}
/*
 * Discard the TRANCLASS
*/
try
{
	cics.exec.discardTranclass ( discardTranclass ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardTransaction()

Description:  Remove a transaction definition.

Properties:

NameTypeMaximum LengthInput/Output
transactionString4Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD TRANSACTION

Example: 

var cics = new Cics();
var discardTransaction = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardTransaction = {
	 transaction : "ABCD"
}
/*
 * Discard the TRANSACTION
*/
try
{
	cics.exec.discardTransaction ( discardTransaction ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardTsmodel()

Description:  Remove a temporary storage model definition.

Properties:

NameTypeMaximum LengthInput/Output
tsmodelString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD TSMODEL

Example: 

var cics = new Cics();
var discardTsmodel = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardTsmodel = {
	 tsmodel : "TSMODEL1"
}
/*
 * Discard the TSMODEL
*/
try
{
	cics.exec.discardTsmodel ( discardTsmodel ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardUrimap()

Description:  Remove a URIMAP definition from the system.

Prooperties:

NameTypeMaximum LengthInput/Output
urimapString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD URIMAP

Example: 

var cics = new Cics();
var discardUrimap = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardUrimap = {
	 urimap : "URIMAP1"
}
/*
 * Discard the URIMAP
*/
try
{
	cics.exec.discardUrimap ( discardUrimap ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

discardWebservice()

Description:  Remove a WEBSERVICE definition.

Properties:

NameTypeMaximum LengthInput/Output
webserviceString8Input

Corresponding CICS Command Level API command: EXEC CICS DISCARD WEBSERVICE

Example: 

var cics = new Cics();
var discardWebservice = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
*/
var discardWebservice = {
	 webservice : "WEBSERV1"
}
/*
 * Discard the WEBSERVICE
*/
try
{
	cics.exec.discardWebservice ( discardWebservice ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
} 

documentCreate()

Description:  Create a document.

Properties:

NameTypeMaximum LengthInput/Output
doclengthNumeric
Output
doctokenString16Output
listlengthNumeric
Input
symbollistString>32KInput
templateString48Input

Corresponding CICS Command Level API command: EXEC CICS DOCUMENT CREATE

Example: 

var cics = new Cics();
var documentCreate = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 */
var documentCreate = 
	{template : "MyTemplate"		 
	}
/*
 * Create the DOCUMENT
 */
try
{
	cics.exec.documentCreate ( documentCreate ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tDocsize = ', documentCreate.docsize);
writeln('\tDoctoken = ', documentCreate.doctoken, '\n');
/*
 * All Done  
 */

documentRetrieve()

Description:  Copy a document into the application's own buffer.

Properties:

NameTypeMaximum LengthInput/Output
doctokenString16Input
intoString<32KOutput
lengthNumeric
Output
maxlengthNumericDefault is 8KInput
charactersetString40Input
dataonlyBoolean
Input

Corresponding CICS Command Level API command: EXEC CICS DOCUMENT RETRIEVE

Example: 

var cics = new Cics();
var documentCreate = new Object();
var documentRetrieve = new Object();
var intoarea = 'thisatest';
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 */
var documentCreate = 
	{template : "TEMPLAT1" 
	}
/*
 * Create the DOCUMENT
 */
try
{
	cics.exec.documentCreate ( documentCreate ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
writeln('\tDocsize = ', documentCreate.docsize);
writeln('\tDoctoken = ', documentCreate.doctoken, '\n');
/*
 * Now retrieve the document
 */
/*
 * Set up input
 */
var documentRetrieve = 
	{doctoken : documentCreate.doctoken,
	 into : intoarea,	
	 length : 1024,
	 maxlength : 1024
	}
/*
 * Create the DOCUMENT
 */
try
{
	cics.exec.documentRetrieve ( documentRetrieve ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
writeln('\tInto = ', documentRetrieve.into);
writeln('\tMaxlength = ', documentRetrieve.maxlength, '\n');
/*
 * All Done  
 */

eib()

Description:  Retrieve the contents of the EXEC inrterface block (EIB).

Link to correct documentation: Cics.eib()  

endBrowseContainer()

Description:  End a browse of the containers associated with a channel.

Properties:

NameTypeMaximum LengthInput/Output
browsetokenString4Input

Corresponding CICS Command Level API command: EXEC CICS ENDBROWSE CONTAINER

Example: 

var cics = new Cics();
var startBrowseContainer = new Object();
var endBrowseContainer = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 */
var startBrowseContainer = 
	{channel : "CHANNELNAME0001" 
	}
/*
 * Start the browse of the container
 */
try
{
	cics.exec.startBrowseContainer ( startBrowseContainer ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
writeln('\tBrowsetoken = ', startBrowseContainer.browsetoken, '\n');
/*
 * Now end the browse
 */
/*
 * Set up input
 */
var endBrowseContainer = 
	{browsetoken : startBrowseContainer.browsetoken 
	}
/*
 * End the browse
 */
try
{
	cics.exec.endBrowseContainer ( endBrowseContainer ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
/*
 * All Done  
 */

endBrowseFile()

Description:  End the browse of a file.

Properties:

NameTypeMaximum LengthInput/Output
fileString8Input
reqidString2Input
sysidString4Input

Corresponding CICS Command Level API command: EXEC CICS ENDBR

Example: 

var cics = new Cics();
var endBrowseFile = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 */
var endBrowseFile = 
	{file : "DDNAME01" 
	}
/*
 * End the browse
 */
try
{
	cics.exec.endBrowseFile ( endBrowseFile ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
/*
 * All Done  
 */

enterTracenum()

Description:  Write a trace entry.

Properties:

NameTypeMaximum LengthInput/Output
ExceptionBoolean
Input
FromString4000Input
FromlengthNumeric
Input
ResourceString8Input
TracenumNumeric
Input (0-199)

Corresponding CICS Command Level API command: EXEC CICS ENTER TRACENUM

Example: 

var cics = new Cics();
var enterTracenum = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 */
var enterTracenum = 
	{from : "THIS IS A TRACE ENTRY",
     fromlength : 21,
     exception : true   
	}
/*
 * End the browse
 */
try
{
	cics.exec.enterTracenum ( enterTracenum ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
/*
 * All Done  
 */

enq()

Description:  Schedule use of a resource by a task (enqueue).

Properties:

NameTypeMaximum LengthInput/Output
lengthNumeric
Input
maxlifetimeCVDA
Input
nosuspendBoolean
Input
resourceString255Input

Corresponding CICS Command Level API command: EXEC CICS ENQ

Example: 

var cics = new Cics();
var enq = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 * For maxlifetime, 233 indicates TASK and 246 indicates UOW
 */
var enq = {
	 length : 8,
	 maxlifetime : 233,
	 resource : "ENQNAME1",
     nosuspend : true 
}
/*
 * Enqueue the resource
 */
try
{
	cics.exec.enq ( enq ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}

extractTcpip()

Description:  Obtain information about TCP/IP characteristics of the current transaction.

Properties:

NameTypeMaximum LengthInput/Output
authenticateCVDA
Output
clientaddrstring15Output
clientnamestring255Output
maxdatalennumeric
Output
privacyCVDA
Output
portnumeric
Output
serveraddrstring15Output
servernamestring255Output
ssltypeCVDA
Output
tcpipservicestring8Output

Corresponding CICS Command Level API command: EXEC CICS EXTRACT TCPIP

Example: 

var cics = new Cics();
var extractTcpip = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

try
{
	cics.exec.extractTcpip ( extractTcpip ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Output returned
 * For authenticate, the output values are:
 *     1104 (ASSERTED)
 *     1095 (AUTOAUTH)
 *     1094 (AUTOREGISTER)
 *     1092 (BASICAUTH)
 *     1093 (CERTIFICAUTH)
 *     1091 (NOAUTHENTIC)
 * For privacy, the output values are:
 *       15 (NOTSUPPORTED)
 *      666 (REQUIRED)
 *     1106 (SUPPORTED)
 * For ssltype, the output values are:  
 *     1205 (ATTLSAWARE)
 *     1032 (CLIENTAUTH)
 *     1031 (NOSSL)
 *     1030 (SSL)   
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
writeln('\tAuthenticate = ', extractTcpip.authenticate);
writeln('\tClientaddr = ', extractTcpip.clientaddr);
writeln('\tClientname = ', extractTcpip.clientname);
writeln('\tMaxdatalen = ', extractTcpip.maxdatalen);
writeln('\tPrivacy = ', extractTcpip.privacy);
writeln('\tPort = ', extractTcpip.port);
writeln('\tServeraddr = ', extractTcpip.serveraddr);
writeln('\tServername = ', extractTcpip.servername);
writeln('\tSsltype = ', extractTcpip.ssltype);
writeln('\tTcpipservice = ', extractTcpip.tcpipservice, '\n');
/*
 * All Done  
 */

fepiInquireConnectionStart()

Description:  Inquire on a FEPI connection.

Properties:

NameTypeMaximum LengthInput/Output
acqnumnumeric
Output
acqstatusCVDA
Output
convnumnumeric
Output
instlstatusCVDA
Output
lastacqcodestring4Output
nodestring8Input
poolstring8Output
servstatusCVDA
Output
stateCVDA
Output
targetstring8Input
userdatastring64Output
waitconvnumnumeric
Output

Corresponding CICS Command Level API command: EXEC CICS FEPI INQUIRE CONNECTION START

Example: 

var cics = new Cics();
var fepiInquireConnection = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 */
var fepiInquireConnection = {
	 node : "FEPINDE1",
	 target : "FEPITGT1"
}

try
{
	cics.exec.fepiInquireConnection ( fepiInquireConnection ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Output returned
 * For acqstatus, the output values are:
 *       69 (ACQUIRED)
 *       71 (ACQUIRING)
 *       70 (RELEASED)
 *      549 (RELEASING)
 * For instlstatus, the output values are:
 *      550 (INSTALLED)
 *      551 (NOTINSTALLED)
 * For servstatus, the output values are:
 *      172 (GOINGOUT)  
 *       73 (INSERVICE)
 *       74 (OUTSERVICE)
 * For state, the output values are: 
 *      559 (APPLICATION)
 *      510 (BEGINSESSION)
 *       85 (FREE) 
 *      556 (NOCONV)
 *      558 (PENDBEGIN)
 *      560 (PENDDATA)
 *       86 (PENDFREE)
 *      565 (PENDPASS)
 *      562 (PENDRELEASE)
 *      561 (PENDSTART) 
 *      557 (PENDSTSN)
 *      564 (PENDUNSOL)
 *      563 (RELEASE)
 *      509 (STSN)  
 *      521 (UNSOLDATA)
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
writeln('\tAcqnum = ', extractTcpip.acqnum);
writeln('\tAcqstatus = ', extractTcpip.acqstatus);
writeln('\tConvnum = ', extractTcpip.convnum);
writeln('\tInstlstatus = ', extractTcpip.instlstatus);
writeln('\tLastacqcode = ', extractTcpip.lastacqcode);
writeln('\tNode = ', extractTcpip.node);
writeln('\tPool = ', extractTcpip.pool);
writeln('\tServstatus = ', extractTcpip.servstatus);
writeln('\tState = ', extractTcpip.state);
writeln('\tTarget = ', extractTcpip.target);
writeln('\tUserdata = ', extractTcpip.userdata);
writeln('\tWaitconvnum = ', extractTcpip.waitconvnum, '\n');
/*
 * All Done  
 */

fepiInquireConnectionNextNode()

Description:  Inquire on the next node of a FEPI connection.

Properties:

Name

Type

Maximum Length

Input/Output

acqnumnumeric
Output
acqstatusCVDA
Output
convnumnumeric
Output
instlstatusCVDA
Output
lastacqcodestring4Output
nodestring8Input
poolstring8Output
servstatusCVDA
Output
stateCVDA
Output
targetstring8Input
userdatastring64Output
waitconvnumnumeric
Output

Corresponding CICS Command Level API command: EXEC CICS FEPI INQUIRE CONNECTION NEXTNODE

Example: 

var cics = new Cics();
var fepiInquireConnectionNextNode = new Object();
var common = require('common''hbutils');
var debugging = require('debugging''hbutils');
 
/*
 * Set up input
 */
var fepiInquireConnectionNextNode = {
     node : "FEPINDE1",
     target : "FEPITGT1"
}
 
try
{
    cics.exec.fepiInquireConnectionNextNode ( fepiInquireConnectionNextNode ) ;  // execute the EXEC CICS API request
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Output returned
 * For acqstatus, the output values are:
 *       69 (ACQUIRED)
 *       71 (ACQUIRING)
 *       70 (RELEASED)
 *      549 (RELEASING)
 * For instlstatus, the output values are:
 *      550 (INSTALLED)
 *      551 (NOTINSTALLED)
 * For servstatus, the output values are:
 *      172 (GOINGOUT) 
 *       73 (INSERVICE)
 *       74 (OUTSERVICE)
 * For state, the output values are:
 *      559 (APPLICATION)
 *      510 (BEGINSESSION)
 *       85 (FREE)
 *      556 (NOCONV)
 *      558 (PENDBEGIN)
 *      560 (PENDDATA)
 *       86 (PENDFREE)
 *      565 (PENDPASS)
 *      562 (PENDRELEASE)
 *      561 (PENDSTART)
 *      557 (PENDSTSN)
 *      564 (PENDUNSOL)
 *      563 (RELEASE)
 *      509 (STSN) 
 *      521 (UNSOLDATA)
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
writeln('\tAcqnum = ', extractTcpip.acqnum);
writeln('\tAcqstatus = ', extractTcpip.acqstatus);
writeln('\tConvnum = ', extractTcpip.convnum);
writeln('\tInstlstatus = ', extractTcpip.instlstatus);
writeln('\tLastacqcode = ', extractTcpip.lastacqcode);
writeln('\tNode = ', extractTcpip.node);
writeln('\tPool = ', extractTcpip.pool);
writeln('\tServstatus = ', extractTcpip.servstatus);
writeln('\tState = ', extractTcpip.state);
writeln('\tTarget = ', extractTcpip.target);
writeln('\tUserdata = ', extractTcpip.userdata);
writeln('\tWaitconvnum = ', extractTcpip.waitconvnum, '\n');
/*
 * All Done 
 */


fepiInquireConnectionNextTarget()

Description:  Inquire on the next target in a FEPI connection.

Properties:

Name

Type

Maximum Length

Input/Output

acqnumnumeric
Output
acqstatusCVDA
Output
convnumnumeric
Output
instlstatusCVDA
Output
lastacqcodestring4Output
nodestring8Input
poolstring8Output
servstatusCVDA
Output
stateCVDA
Output
targetstring8Input
userdatastring64Output
waitconvnumnumeric
Output


Corresponding CICS Command Level API command: EXEC CICS FEPI INQUIRE CONNECTION NEXTTARGET

Example: 


var cics = new Cics();
var fepiInquireConnectionNextTarget = new Object();
var common = require('common''hbutils');
var debugging = require('debugging''hbutils');
 
/*
 * Set up input
 */
var fepiInquireConnectionNextTarget = {
     node : "FEPINDE1",
     target : "FEPITGT1"
}
 
try
{
    cics.exec.fepiInquireConnectionNextTarget ( fepiInquireConnectionNextTarget ) ;  // execute the EXEC CICS API request
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Output returned
 * For acqstatus, the output values are:
 *       69 (ACQUIRED)
 *       71 (ACQUIRING)
 *       70 (RELEASED)
 *      549 (RELEASING)
 * For instlstatus, the output values are:
 *      550 (INSTALLED)
 *      551 (NOTINSTALLED)
 * For servstatus, the output values are:
 *      172 (GOINGOUT) 
 *       73 (INSERVICE)
 *       74 (OUTSERVICE)
 * For state, the output values are:
 *      559 (APPLICATION)
 *      510 (BEGINSESSION)
 *       85 (FREE)
 *      556 (NOCONV)
 *      558 (PENDBEGIN)
 *      560 (PENDDATA)
 *       86 (PENDFREE)
 *      565 (PENDPASS)
 *      562 (PENDRELEASE)
 *      561 (PENDSTART)
 *      557 (PENDSTSN)
 *      564 (PENDUNSOL)
 *      563 (RELEASE)
 *      509 (STSN) 
 *      521 (UNSOLDATA)
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
writeln('\tAcqnum = ', extractTcpip.acqnum);
writeln('\tAcqstatus = ', extractTcpip.acqstatus);
writeln('\tConvnum = ', extractTcpip.convnum);
writeln('\tInstlstatus = ', extractTcpip.instlstatus);
writeln('\tLastacqcode = ', extractTcpip.lastacqcode);
writeln('\tNode = ', extractTcpip.node);
writeln('\tPool = ', extractTcpip.pool);
writeln('\tServstatus = ', extractTcpip.servstatus);
writeln('\tState = ', extractTcpip.state);
writeln('\tTarget = ', extractTcpip.target);
writeln('\tUserdata = ', extractTcpip.userdata);
writeln('\tWaitconvnum = ', extractTcpip.waitconvnum, '\n');
/*
 * All Done 
 */


fepiInquireConnectionEnd()

Description:  End an inquiry on a FEPI connection.

Properties:

Name

Type

Maximum Length

Input/Output

acqnumnumeric
Output
acqstatusCVDA
Output
convnumnumeric
Output
instlstatusCVDA
Output
lastacqcodestring4Output
nodestring8Input
poolstring8Output
servstatusCVDA
Output
stateCVDA
Output
targetstring8Input
userdatastring64Output
waitconvnumnumeric
Output


Corresponding CICS Command Level API command: EXEC CICS FEPI INQUIRE CONNECTION END

Example: 


var cics = new Cics();
var fepiInquireConnectionEnd = new Object();
var common = require('common''hbutils');
var debugging = require('debugging''hbutils');
 
/*
 * Set up input
 */
var fepiInquireConnectionEnd = {
     node : "FEPINDE1",
     target : "FEPITGT1"
}
 
try
{
    cics.exec.fepiInquireConnectionEnd ( fepiInquireConnectionEnd ) ;  // execute the EXEC CICS API request
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Output returned
 * For acqstatus, the output values are:
 *       69 (ACQUIRED)
 *       71 (ACQUIRING)
 *       70 (RELEASED)
 *      549 (RELEASING)
 * For instlstatus, the output values are:
 *      550 (INSTALLED)
 *      551 (NOTINSTALLED)
 * For servstatus, the output values are:
 *      172 (GOINGOUT) 
 *       73 (INSERVICE)
 *       74 (OUTSERVICE)
 * For state, the output values are:
 *      559 (APPLICATION)
 *      510 (BEGINSESSION)
 *       85 (FREE)
 *      556 (NOCONV)
 *      558 (PENDBEGIN)
 *      560 (PENDDATA)
 *       86 (PENDFREE)
 *      565 (PENDPASS)
 *      562 (PENDRELEASE)
 *      561 (PENDSTART)
 *      557 (PENDSTSN)
 *      564 (PENDUNSOL)
 *      563 (RELEASE)
 *      509 (STSN) 
 *      521 (UNSOLDATA)
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
writeln('\tAcqnum = ', extractTcpip.acqnum);
writeln('\tAcqstatus = ', extractTcpip.acqstatus);
writeln('\tConvnum = ', extractTcpip.convnum);
writeln('\tInstlstatus = ', extractTcpip.instlstatus);
writeln('\tLastacqcode = ', extractTcpip.lastacqcode);
writeln('\tNode = ', extractTcpip.node);
writeln('\tPool = ', extractTcpip.pool);
writeln('\tServstatus = ', extractTcpip.servstatus);
writeln('\tState = ', extractTcpip.state);
writeln('\tTarget = ', extractTcpip.target);
writeln('\tUserdata = ', extractTcpip.userdata);
writeln('\tWaitconvnum = ', extractTcpip.waitconvnum, '\n');
/*
 * All Done 
 */

fepiSetConnection()

Description:  Set a FEPI connection.

Properties:

NameTypeMaximum LengthInput/Output
acqstatusCVDA
Input
nodestring8Input
nodeliststring256Input
nodenumnumericmaximum value 2048Input
servstatusCVDA
Input
targetstring8Input
targetliststring256Input
targetnumnumericmaximum value 2048Input
userdatastring64Input

Corresponding CICS Command Level API command: EXEC CICS FEPI SET CONNECTION

Example: 

var cics = new Cics();
var fepiSetConnection = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 * For acqstatus, 69 indicates ACQUIRED and 70 indicates RELEASED
 * For servstatus, 73 indicates INSERVICE and 74 indicates OUTSERVICE
 */
var fepiSetConnection = {
	 acqstatus : 69,
	 node : "FEPINDE1",
	 servstatus : 73,
     target : "FEPITGT1" 
}
/*
 * Enqueue the resource
 */
try
{
	cics.exec.fepiSetConnection ( fepiSetConnection ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}

fetchAny()

Description:  The EXEC CICS FETCH ANY command is used by a parent task to inquire on the
status of any child task, and returns the status of any completed child task which
has not yet been fetched.

Properties:

NameTypeMaximum LengthInput/Output
abcodestring4Output
anystring16Output
channelstring16Output
compstatusCVDA
Output
nosuspendBoolean
Input
timeoutnumeric
Input

Corresponding CICS Command Level API command: EXEC CICS FETCH ANY

See the CVDA table (CICS CVDA values in numerical order) to find the meaning of a particular CVDA value.

Example: 

var cics = new Cics();
var runTransid = new Object();
var fetchAny = new Object();
var fetchChild = new Object();		
var freeChild = new Object(); 
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var runTransid =
    { channel : 'RUNTRANSIDTEST01',
      transid : 'HBNL'      
    }    
/*
 * Run a transaction
 */
try
{
    cics.exec.runTransid ( runTransid ) ;
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in runTransid) {
    writeln('\t', prop, ' = ', runTransid[prop]);
}
/*
 * Set up input
 */
var fetchAny =
   {  
     nosuspend : true      
   }
/*
 * Fetch any
 */
try
{
    cics.exec.fetchAny ( fetchAny ) ;
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in fetchAny) {
    writeln('\t', prop, ' = ', fetchAny[prop]);
}

fetchChild()

Description:  The EXEC CICS FETCH CHILD command is used by a parent task to inquire on the
status of a specific child task, and returns the status of the specified child task.

Properties:

NameTypeMaximum LengthInput/Output
abcodestring4Output
channelstring16Output
childstring16Input
compstatusCVDA
Output
nosuspendBoolean
Input
timeoutnumeric
Input

Corresponding CICS Command Level API command: EXEC CICS FETCH CHILD

See the CVDA table (CICS CVDA values in numerical order) to find the meaning of a particular CVDA value.

Example: 

var cics = new Cics();
var runTransid = new Object();
var fetchAny = new Object();
var fetchChild = new Object();		
var freeChild = new Object(); 
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var runTransid =
    { channel : 'RUNTRANSIDTEST01',
      transid : 'HBNL'      
    }    
/*
 * Run a transaction
 */
try
{
    cics.exec.runTransid ( runTransid ) ;
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in runTransid) {
    writeln('\t', prop, ' = ', runTransid[prop]);
}
/*
 * Set up input
 */
var fetchChild =
   { child : runTransid.token,   
     nosuspend : true      
   }
/*
 * Fetch child
 */
try
{
    cics.exec.fetchChild ( fetchChild ) ;
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in fetchChild) {
    writeln('\t', prop, ' = ', fetchChild[prop]);
}

freeChild()

Description:  The EXEC CICS FREE CHILD command frees a specified child token which has been
previously allocated by an EXEC CICS RUN TRANSID command. If a parent task no
longer requires the response of a child task, then using the FREE CHILD command
will free the resources associated with that child task when it completes, rather
than waiting for them to be fetched.

Properties:

NameTypeMaximum LengthInput/Output
childstring16Input

Corresponding CICS Command Level API command: EXEC CICS FREE CHILD

Example: 

var cics = new Cics();
var runTransid = new Object();
var fetchAny = new Object();
var fetchChild = new Object();		
var freeChild = new Object(); 
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var runTransid =
    { channel : 'RUNTRANSIDTEST01',
      transid : 'HBNL'      
    }    
/*
 * Run a transaction
 */
try
{
    cics.exec.runTransid ( runTransid ) ;
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in runTransid) {
    writeln('\t', prop, ' = ', runTransid[prop]);
}
/*
 * Set up input
 */
var freeChild =
   { 
     child : runTransid.token 
   }
/*
 * Free child
 */
try
{
    cics.exec.freeChild ( freeChild ) ;
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in freeChild) {
    writeln('\t', prop, ' = ', freeChild[prop]);
}

getContainerChannel()

Description:  Retrieve data from a named channel container.

Properties:

NameTypeMaximum LengthInput/Output
channelstring16Input
containerstring16Input
flengthnumeric
Output
intostring
Output
nodataboolean
Output

Corresponding CICS Command Level API command: EXEC CICS GET CONTAINER CHANNEL

Example: 

var cics = new Cics();
var putContainerChannel = new Object();
var getContainerChannel = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input  
 * For the datatype parameter, BIT is 1020 and CHAR is 1019
 */
var putContainerChannel = 
	{container : "FIRSTCON",
	 channel : "FIRSTCHN", 	
	 from: "BLAH",
	 flength : 4,
	 append : true,
	 datatype: 1020
	}
/*
 * Put data in a container   
 */
try
{
    cics.exec.putContainerChannel ( putContainerChannel ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tRespPut1 = ', cics.eib.eibresp);
writeln('\tResp2Put1 = ', cics.eib.eibresp2);
/*
 * Put data in a container again to test append  
 */
/*
 * Set up input  
 * For the datatype parameter, BIT is 1020 and CHAR is 1019
 */
var putContainerChannel = 
	{container : "FIRSTCON",
	 channel : "FIRSTCHN", 	
	 from: "BLA2",
	 flength : 4,
	 append : true,
	 datatype: 1020
	}
try
{
    cics.exec.putContainerChannel ( putContainerChannel ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tRespPut2 = ', cics.eib.eibresp);
writeln('\tResp2Put2 = ', cics.eib.eibresp2);
/*
 * Now get the channel container contents
 * Set up input
 */
var getContainerChannel = 
	{channel : "FIRSTCHN",
	 container: "FIRSTCON"
	}
/*
 * Get the container
 */
try
{
	cics.exec.getContainerChannel ( getContainerChannel ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tRespGet = ', cics.eib.eibresp);
writeln('\tResp2Get = ', cics.eib.eibresp2);
writeln('\tInto = ', getContainerChannel.into);
writeln('\tFlength = ', getContainerChannel.flength, '\n');
/*
 * All Done  
 */

getNextContainer()

Description:  Browse the containers associated with a channel.

Properties:

NameTypeMaximum LengthInput/Output
browsetokenString4Input
containerString16Output

Corresponding CICS Command Level API command: EXEC CICS GETNEXT CONTAINER

Example: 

var cics = new Cics();
var startBrowseContainer = new Object();
var getNextContainer = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 */
var startBrowseContainer = 
	{channel : "CHANNELNAME0001" 
	}
/*
 * Start the browse of the container
 */
try
{
	cics.exec.startBrowseContainer ( startBrowseContainer ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
writeln('\tBrowsetoken = ', startBrowseContainer.browsetoken, '\n');
/*
 * Now get the next container name
 * Set up input
 */
var getNextContainer = 
	{browsetoken : startBrowseContainer.browsetoken 
	}
/*
 * Get the next container
 */
try
{
	cics.exec.getNextContainer ( getNextContainer ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
writeln('\tContainer = ', getNextContainer.container, '\n');

inquireFile()

Description:  Retrieve information about a file.

Properties:

NameTypeMaximum LengthInput/Output
accessmethodCVDA
Output
addCVDA
Output
basedsnameString44Output
blockformatCVDA
Output
blockkeylenNumeric
Output
blocksizeNumeric
Output
browseCVDA
Output
cfdtpoolString8Output
changeagentCVDA
Output
changeagrelString4Output
changetimeNumericAbstimeOutput
changeusridString8Output
definesourceString8Output
definetimeNumericAbstimeOutput
deleteCVDA
Output
dispositionSCVDA
Output
dsnameString44Output
emptystatusCVDA
Output
enablestatusCVDA
Output
exclusiveCVDA
Output
fileString8Input
fwdrecstatusCVDA
Output
installagentCVDA
Output
installtimeNumericAbstimeOutput
installusridString8Output
journalnumNumeric
Output
keylengthNumeric
Output
keypositionNumeric
Output
loadtypeCVDA
Output
lsrpoolnumNumeric
Output
maxnumrecsNumeric
Output
objectCVDA
Output
openstatusCVDA
Output
rbatypeCVDA
Output
readCVDA
Output
readintegCVDA
Output
recordformatCVDA
Output
recordsizeNumeric
Output
recovstatusCVDA
Output
reltypeCVDA
Output
remotenameString8Output
remotesystemString4Output
remotetableCVDA
Output
rlsaccessCVDA
Output
stringsNumeric
Output
tableCVDA
Output
tablenameString8Output
typeCVDA
Output
updateCVDA
Output
updatemodelCVDA
Output



See the CVDA table (CICS CVDA values in numerical order) to find the meaning of a particular CVDA value.

Corresponding CICS Command Level API command: EXEC CICS INQUIRE FILE

Example: 

var cics = new Cics();
var inquireFile = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input  
 */
var inquireFile = 
	{file : "HBUTILS"
	}
/*
 * Inquire on the file   
 */
try
{
    cics.exec.inquireFile ( inquireFile ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireFile) {
	writeln('\t', prop, ' = ', inquireFile[prop]);
}
/*
 * All Done  
 */

inquireSystem()

Description:  Retrieve CICS system information.

Properties:

NameTypeMaximum LengthInput/Output
actopentcbsNumeric
Output
akpNumeric
Output
cdsasizeNumeric
Output
cicsstatusCVDA
Output
cicssysString1Output
cicstslevelString6Output
cmdprotectCVDA
Output
coldstatusCVDA
Output
db2connString8Output
debugtoolCVDA
Output
dfltuserString8Output
dsalimitNumeric
Output
dsrtprogramString8Output
dtrprogramString8Output
dumpingCVDA
Output
ecdsasizeNumeric
Output
edsasizeNumeric
Output
erdsasizeNumeric
Output
esdsasizeNumeric
Output
etdsasizeNumeric
Output
eudsasizeNumeric
Output
forceqrCVDA
Output
gcdsasizeNumeric
Output
gmmlengthNumeric
Output
gmmtextString246Output
gmmtranidString4Output
gsdsasizeNumeric
Output
gudsasizeNumeric
Output
initstatusCVDA
Output
jobnameString8Output
logdeferNumeric
Output
maxopentcbsNumeric
Output
maxtasksNumeric
Output
memlimitNumeric
Output
messagecaseCVDA
Output
mqconnString8Output
mrobatchNumeric
Output
mvssmfidString4Output
mvssysnameString8Output
oprelNumeric
Output
opsysString1Output
oslevelString6Output
progautoctlgCVDA
Output
progautoexitString8Output
progautoinstCVDA
Output
prtyagingNumeric
Output
rdsasizeNumeric
Output
reentprotectCVDA
Output
regionuseridString8Output
releaseString4Output
rlsstatusCVDA
Output
runawayNumeric
Output
scandelayNumeric
Output
sdsasizeNumeric
Output
sdtranString4Output
securitymgrCVDA
Output
shutstatusCVDA
Output
sosabovebarCVDA
Output
sosabovelineCVDA
Output
sosbelowlineCVDA
Output
sosstatusCVDA
Output
startupCVDA
Output
startupdateNumeric
Output
storeprotectCVDA
Output
timeNumeric
Output
tranisolateCVDA
Output
udsasizeNumeric
Output
xrfstatusCVDA
Output

See the CVDA table (CICS CVDA values in numerical order) to find the meaning of a particular CVDA value.

Corresponding CICS Command Level API command: EXEC CICS INQUIRE SYSTEM

Example: 

var cics = new Cics();
var inquireSystem = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Inquire on the file   
 */
try
{
    cics.exec.inquireSystem ( inquireSystem ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireSystem) {
	writeln('\t', prop, ' = ', inquireSystem[prop]);
}
/*
 * All Done  
 */

inquireTask()

Description:  Retrieve information about a user task.

Properties:

NameTypeMaximum LengthInput/Output
activityString16Output
activityidString52Output
attachtimeNumericAbstimeOutput
brfacilityString8Output
bridgeString4Output
cmdsecCVDA
Output
currentprogString8Output
db2planString8Output
dtimeoutNumeric
Output
dumpingCVDA
Output
facilityString4Output
facilitytypeCVDA
Output
identifierString48Output
indoubtCVDA
Output
indoubtminsNumeric
Output
indoubtwaitCVDA
Output
ipfacilitiesStringipflistsize / 4Output
ipflistsizeNumeric
Output
isolatestCVDA
Output
priorityNumeric
Output
processString36Output
processtypeString8Output
profileString8Output
programString8Output
purgeabilityCVDA
Output
remotenameString4Output
remotesystemString4Output
resnameString16Output
ressecCVDA
Output
routingCVDA
Output
rtimeoutNumeric
Output
runawayNumeric
Output
runstatusCVDA
Output
scrnsizeCVDA
Output
startcodeString2Output
storageclearCVDA
Output
suspendtimeNumeric
Output
suspendtype8
Output
suspendvalue8
Output
taskNumeric
Input
taskdatakeyCVDA
Output
taskdatalocCVDA
Output
tcbCVDA
Output
tclassNumeric
Output
tracingCVDA
Output
tranclassString8Output
tranpriorityNumeric
Output
transactionString4Output
trprofString8Output
twasizeNumeric
Output
uowString8Output
useridString8Output

See the CVDA table (CICS CVDA values in numerical order) to find the meaning of a particular CVDA value.

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TASK

Example: 

var cics = new Cics();
var inquireTask = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input (replace nnnn below with the task number you want to inquire on) 
 */
var inquireTask = 
	{task : nnnn
	}
/*
 * Inquire on the task   
 */
try
{
    cics.exec.inquireTask ( inquireTask ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTask) {
	writeln('\t', prop, ' = ', inquireTask[prop]);
}
/*
 * All Done  
 */

inquireTaskList()

Description:  Retrieve a list of tasks and their associated transactions from a region. 

Properties:

NameTypeMaximum LengthInput/Output
dispatchableBoolean
Input
listsizeNumeric
Output
runningBoolean
Input
setArraySee note belowOutput
settransidArraySee note belowOutput
suspendedBoolean
Input

set and settransid are arrays that show the task numbers and their associated transactions. There is a one-to-one correspondence between the items in each array; i.e. item 1 in the set array relates to item 1 in the settransid array, item 2 relates to item 2, and so on. The number of items in the arrays is provided by the listsize property.

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TASK LIST

Example: 

var cics = new Cics();
var inquireTaskList = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var inquireTaskList = 
	{ suspended : true,
	  dispatchable : true, 
	  running : true 
	}
/*
 * Inquire on the task list
 */
try
{
    cics.exec.inquireTaskList (	inquireTaskList) ; 	
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTaskList) {
	writeln('\t', prop, ' = ', inquireTaskList[prop]);
}

inquireTracedest()

Description:  Retrieve information about tracing.

Properties:

NameTypeMaximum LengthInput/Output
auxstatusCVDA
Output
curauxdsString1Output
gtfstatusCVDA
Output
intstatusCVDA
Output
switchstatusCVDA
Output
tablesizeNumeric
Output

See the CVDA table (CICS CVDA values in numerical order) to find the meaning of a particular CVDA value.


Corresponding CICS Command Level API command: EXEC CICS INQUIRE TRACEDEST

Example: 

var cics = new Cics();
var inquireTracedest = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Inquire on the trace destinations 
 */
try
{
    cics.exec.inquireTracedest ( inquireTracedest ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTracedest) {
	writeln('\t', prop, ' = ', inquireTracedest[prop]);
}
/*
 * All Done  
 */

inquireTraceflag()

Description:  Retrieve information about trace flags.

Properties:

NameTypeMaximum LengthInput/Output
singlestatusCVDA
Output
systemstatusCVDA
Output
tcexitstatusCVDA
Output
userstatusCVDA
Output

See the CVDA table (CICS CVDA values in numerical order) to find the meaning of a particular CVDA value.


Corresponding CICS Command Level API command: EXEC CICS INQUIRE TRACEFLAG

Example: 

var cics = new Cics();
var inquireTraceflag = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Inquire on the trace destinations 
 */
try
{
    cics.exec.inquireTraceflag ( inquireTraceflag ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTraceflag) {
	writeln('\t', prop, ' = ', inquireTraceflag[prop]);
}
/*
 * All Done  
 */

inquireTranclass()

Description:  Retrieve information about a transaction class.

Properties:

NameTypeMaximum LengthInput/Output
activeNumeric
Output
maxactiveNumeric
Output
purgethreshNumeric
Output
queuedNumeric
Output
tranclassString8Input

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TRANCLASS

Example: 

var cics = new Cics();
var inquireTranclass = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input  
 */
var inquireTranclass = 
	{tranclass : "DFHTCL01"
	}
/*
 * Inquire on the transaction class  
 */
try
{
    cics.exec.inquireTranclass( inquireTranclass ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTranclass) {
	writeln('\t', prop, ' = ', inquireTranclass[prop]);
}
/*
 * All Done  
 */ 

inquireTsqname()

Description: Retrieve information about a temporary storage queue.  

Use either inquireTsqname or inquireTsqueue to inquire about names up to 8 characters long; use inquireTsqname if you have queue names up to 16 characters long.

Properties:

NameTypeMaximum LengthInput/Output
expiryintNumeric
Output
expiryintminNumeric
Output
flengthNumeric
Output
lastusedintNumeric
Output
locationCVDA
Output
maxitemlenNumeric
Output
minitemlenNumeric
Output
numitemsNumeric
Output
qnameString16Input
recovstatusCVDA
Output
transidString4Output

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TSQNAME

Example: 

var cics = new Cics();
var inquireTsqname = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up inputs  
 */
var inquireTsqname = 
	{qname : "HBZCSOCKHBSWINFO"	
	}
/*
 * Inquire on the tsqname (16 characters) 
 */
try
{
    cics.exec.inquireTsqname( inquireTsqname ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 * For location, AUXILIARY is 247 and MAIN is 248
 * For recovstatus, RECOVERABLE is 29 and NOTRECOVERABLE is 30
 */
for (var prop in inquireTsqname) {
	writeln('\t', prop, ' = ', inquireTsqname[prop]);
}
/*
 * All Done  
 */ 

inquireTsqnameStart()

Description:  Start a browse of temporary storage queues.

Use either inquireTsqname or inquireTsqueue to inquire about names up to 8 characters long; use inquireTsqname if you have queue names up to 16 characters long.

Properties:

NameTypeMaximum LengthInput/Output
expiryintNumeric
Output
expiryintminNumeric
Output
flengthNumeric
Output
lastusedintNumeric
Output
locationCVDA
Output
maxitemlenNumeric
Output
minitemlenNumeric
Output
numitemsNumeric
Output
qnameString16Output
recovstatusCVDA
Output
transidString4Output

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TSQNAME START

Example: 

var cics = new Cics();
var inquireTsqname = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Inquire on the tsqname (16 characters) 
 */
try
{
    cics.exec.inquireTsqnameStart (inquireTsqname ) ; 
	cics.exec.inquireTsqnameNext( inquireTsqname ) ;  // execute the EXEC CICS API request	
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 * For location, AUXILIARY is 247 and MAIN is 248
 * For recovstatus, RECOVERABLE is 29 and NOTRECOVERABLE is 30
 */
for (var prop in inquireTsqname) {
	writeln('\t', prop, ' = ', inquireTsqname[prop]);
}
try
{
   	cics.exec.inquireTsqnameNext( inquireTsqname ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqname) {
	writeln('\t', prop, ' = ', inquireTsqname[prop]);
}
try
{
   	cics.exec.inquireTsqnameEnd( inquireTsqname ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqname) {
	writeln('\t', prop, ' = ', inquireTsqname[prop]);
}

inquireTsqnameStartAt()

Description: Start a browse of temporary storage queues from a specific starting point.

Properties:

NameTypeMaximum LengthInput/Output
atString16Input
expiryintNumeric
Output
expiryintminNumeric
Output
flengthNumeric
Output
lastusedintNumeric
Output
locationCVDA
Output
maxitemlenNumeric
Output
minitemlenNumeric
Output
numitemsNumeric
Output
qnameString16Output
recovstatusCVDA
Output
transidString4Output

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TSQNAME START AT

Example: 

var cics = new Cics();
var inquireTsqnameAt = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var inquireTsqnameAt = 
	{ at : "HBZCSOCK"		
	}

/*
 * Inquire on the tsqname (16 characters) 
 */
try
{
    cics.exec.inquireTsqnameStartAt (	inquireTsqnameAt ) ; 
	cics.exec.inquireTsqnameNext( inquireTsqnameAt ) ;  // execute the EXEC CICS API request	
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 * For location, AUXILIARY is 247 and MAIN is 248
 * For recovstatus, RECOVERABLE is 29 and NOTRECOVERABLE is 30
 */
for (var prop in inquireTsqnameAt) {
	writeln('\t', prop, ' = ', inquireTsqnameAt[prop]);
}
try
{
   	cics.exec.inquireTsqnameNext( inquireTsqnameAt ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqnameAt) {
	writeln('\t', prop, ' = ', inquireTsqnameAt[prop]);
}
try
{
   	cics.exec.inquireTsqnameEnd( inquireTsqnameAt ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqnameAt) {
	writeln('\t', prop, ' = ', inquireTsqnameAt[prop]);
}

inquireTsqnameNext()

Description:  Retrieve the next temporary storage queue.

Properties:

NameTypeMaximum LengthInput/Output
expiryintNumeric
Output
expiryintminNumeric
Output
flengthNumeric
Output
lastusedintNumeric
Output
locationCVDA
Output
maxitemlenNumeric
Output
minitemlenNumeric
Output
numitemsNumeric
Output
qnameString16Output
recovstatusCVDA
Output
transidString4Output

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TSQNAME NEXT

Example: 

var cics = new Cics();
var inquireTsqname = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Inquire on the tsqname (16 characters) 
 */
try
{
    cics.exec.inquireTsqnameStart (inquireTsqname ) ; 
	cics.exec.inquireTsqnameNext( inquireTsqname ) ;  // execute the EXEC CICS API request	
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 * For location, AUXILIARY is 247 and MAIN is 248
 * For recovstatus, RECOVERABLE is 29 and NOTRECOVERABLE is 30
 */
for (var prop in inquireTsqname) {
	writeln('\t', prop, ' = ', inquireTsqname[prop]);
}
try
{
   	cics.exec.inquireTsqnameNext( inquireTsqname ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqname) {
	writeln('\t', prop, ' = ', inquireTsqname[prop]);
}
try
{
   	cics.exec.inquireTsqnameEnd( inquireTsqname ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqname) {
	writeln('\t', prop, ' = ', inquireTsqname[prop]);
}

inquireTsqnameEnd()

Description:   End browsing of temporary storage queues.

Use either inquireTsqnameEnd or inquireTsqueueEnd to inquire about names up to 8 characters long; use inquireTsqnameEnd if you have queue names up to 16 characters long.

Properties:  None

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TSQNAME END

Example: 

var cics = new Cics();
var inquireTsqname = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Inquire on the tsqname (16 characters) 
 */
try
{
    cics.exec.inquireTsqnameStart (inquireTsqname ) ; 
	cics.exec.inquireTsqnameNext( inquireTsqname ) ;  // execute the EXEC CICS API request	
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 * For location, AUXILIARY is 247 and MAIN is 248
 * For recovstatus, RECOVERABLE is 29 and NOTRECOVERABLE is 30
 */
for (var prop in inquireTsqname) {
	writeln('\t', prop, ' = ', inquireTsqname[prop]);
}
try
{
   	cics.exec.inquireTsqnameNext( inquireTsqname ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqname) {
	writeln('\t', prop, ' = ', inquireTsqname[prop]);
}
try
{
   	cics.exec.inquireTsqnameEnd( inquireTsqname ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqname) {
	writeln('\t', prop, ' = ', inquireTsqname[prop]);
}

inquireTsqueue()

Description:  Retrieve information about a temporary storage queue.  

Use inquireTsqueue only if your temporary storage queue name is 8 characters in length. Inquiry on a TS queue with a 16 character name using this method will result in an INVREQ return code; use inquireTsqname instead.

Properties:

NameTypeMaximum LengthInput/Output
expiryintNumeric
Output
expiryintminNumeric
Output
flengthNumeric
Output
lastusedintNumeric
Output
locationCVDA
Output
maxitemlenNumeric
Output
minitemlenNumeric
Output
numitemsNumeric
Output
queueString8Input
recovstatusCVDA
Output

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TSQUEUE

Example: 

var cics = new Cics();
var inquireTsqueue = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up inputs  
 */
var inquireTsqueue = 
	{queue : "HBRQLICN"	
	}
/*
 * Inquire on the tsqueue (8 characters) 
 */
try
{
    cics.exec.inquireTsqueue ( inquireTsqueue ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 * For location, AUXILIARY is 247 and MAIN is 248
 * For recovstatus, RECOVERABLE is 29 and NOTRECOVERABLE is 30
 */
for (var prop in inquireTsqueue) {
	writeln('\t', prop, ' = ', inquireTsqueue[prop]);
}

inquireTsqueueStart()

Description: Start a browse of temporary storage queues.

Use inquireTsqueueStart only if your temporary storage queue name is 8 characters in length. Inquiry on a TS queue with a 16 character name using this method will result in an INVREQ return code; use inquireTsqnameStart instead.

Properties:

NameTypeMaximum LengthInput/Output
expiryintNumeric
Output
expiryintminNumeric
Output
flengthNumeric
Output
lastusedintNumeric
Output
locationCVDA
Output
maxitemlenNumeric
Output
minitemlenNumeric
Output
numitemsNumeric
Output
queueString8Output
recovstatusCVDA
Output
transidString4Output

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TSQUEUE START

Example: 

var cics = new Cics();
var inquireTsqueue = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Inquire on the tsqueue (8 characters) 
 */
try
{
    cics.exec.inquireTsqueueStart (inquireTsqueue ) ; 
	cics.exec.inquireTsqueueNext( inquireTsqueue ) ;  // execute the EXEC CICS API request	
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 * For location, AUXILIARY is 247 and MAIN is 248
 * For recovstatus, RECOVERABLE is 29 and NOTRECOVERABLE is 30
 */
for (var prop in inquireTsqueue) {
	writeln('\t', prop, ' = ', inquireTsqueue[prop]);
}
try
{
   	cics.exec.inquireTsqueueNext( inquireTsqueue ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqueue) {
	writeln('\t', prop, ' = ', inquireTsqueue[prop]);
}
try
{
   	cics.exec.inquireTsqueueEnd( inquireTsqueue ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqueue) {
	writeln('\t', prop, ' = ', inquireTsqueue[prop]);
}

inquireTsqueueStartAt()

Description:  Start a browse of temporary storage queues from a specific starting point.

Use inquireTsqueueStartAt only if your temporary storage queue name is 8 characters in length. Inquiry on a TS queue with a 16 character name using this method will result in an INVREQ return code; use inquireTsqnameStartAt instead.

Properties:

NameTypeMaximum LengthInput/Output
atString8Input
expiryintNumeric
Output
expiryintminNumeric
Output
flengthNumeric
Output
lastusedintNumeric
Output
locationCVDA
Output
maxitemlenNumeric
Output
minitemlenNumeric
Output
numitemsNumeric
Output
queueString8Output
recovstatusCVDA
Output
transidString4Output

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TSQUEUE START AT

Example: 

var cics = new Cics();
var inquireTsqueueAt = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var inquireTsqueueAt = 
	{ at : "HBRQLICN"		
	}

/*
 * Inquire on the tsqueue (8 characters) 
 */
try
{
    cics.exec.inquireTsqueueStartAt (	inquireTsqueueAt ) ; 
	cics.exec.inquireTsqueueNext( inquireTsqueueAt ) ;  // execute the EXEC CICS API request	
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 * For location, AUXILIARY is 247 and MAIN is 248
 * For recovstatus, RECOVERABLE is 29 and NOTRECOVERABLE is 30
 */
for (var prop in inquireTsqueueAt) {
	writeln('\t', prop, ' = ', inquireTsqueueAt[prop]);
}
try
{
   	cics.exec.inquireTsqueueNext( inquireTsqueueAt ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqueueAt) {
	writeln('\t', prop, ' = ', inquireTsqueueAt[prop]);
}
try
{
   	cics.exec.inquireTsqueueEnd( inquireTsqueueAt ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqueueAt) {
	writeln('\t', prop, ' = ', inquireTsqueueAt[prop]);
}

inquireTsqueueNext()

Description: Retrieve the next temporary storage queue.

Use inquireTsqueueNext only if your temporary storage queue name is 8 characters in length. Inquiry on a TS queue with a 16 character name using this method will result in an INVREQ return code; use inquireTsqnameNext instead.

Properties:

NameTypeMaximum LengthInput/Output
expiryintNumeric
Output
expiryintminNumeric
Output
flengthNumeric
Output
lastusedintNumeric
Output
locationCVDA
Output
maxitemlenNumeric
Output
minitemlenNumeric
Output
numitemsNumeric
Output
queueString8Output
recovstatusCVDA
Output
transidString4Output

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TSQUEUE NEXT

Example: 

var cics = new Cics();
var inquireTsqueue = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Inquire on the tsqueue (8 characters) 
 */
try
{
    cics.exec.inquireTsqueueStart (inquireTsqueue ) ; 
	cics.exec.inquireTsqueueNext( inquireTsqueue ) ;  // execute the EXEC CICS API request	
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 * For location, AUXILIARY is 247 and MAIN is 248
 * For recovstatus, RECOVERABLE is 29 and NOTRECOVERABLE is 30
 */
for (var prop in inquireTsqueue) {
	writeln('\t', prop, ' = ', inquireTsqueue[prop]);
}
try
{
   	cics.exec.inquireTsqueueNext( inquireTsqueue ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqueue) {
	writeln('\t', prop, ' = ', inquireTsqueue[prop]);
}
try
{
   	cics.exec.inquireTsqueueEnd( inquireTsqueue ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqueue) {
	writeln('\t', prop, ' = ', inquireTsqueue[prop]);
}

inquireTsqueueEnd()

Description:  End browsing of temporary storage queues.

Use inquireTsqueueEnd only if your temporary storage queue name is 8 characters in length. Inquiry on a TS queue with a 16 character name using this method will result in an INVREQ return code; use inquireTsqnameEnd instead.

Properties:  None

Corresponding CICS Command Level API command: EXEC CICS INQUIRE TSQUEUE END

Example: 

var cics = new Cics();
var inquireTsqueue = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Inquire on the tsqueue (8 characters) 
 */
try
{
    cics.exec.inquireTsqueueStart (inquireTsqueue ) ; 
	cics.exec.inquireTsqueueNext( inquireTsqueue ) ;  // execute the EXEC CICS API request	
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 * For location, AUXILIARY is 247 and MAIN is 248
 * For recovstatus, RECOVERABLE is 29 and NOTRECOVERABLE is 30
 */
for (var prop in inquireTsqueue) {
	writeln('\t', prop, ' = ', inquireTsqueue[prop]);
}
try
{
   	cics.exec.inquireTsqueueNext( inquireTsqueue ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqueue) {
	writeln('\t', prop, ' = ', inquireTsqueue[prop]);
}
try
{
   	cics.exec.inquireTsqueueEnd( inquireTsqueue ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in inquireTsqueue) {
	writeln('\t', prop, ' = ', inquireTsqueue[prop]);
}

moveContainerChannel()

Description:  Move a container (and its contents) from one channel to another.

Properties:

NameTypeMaximum LengthInput/Output
asString16Input
channelString16Input
containerString16Input
tochannelString16Input

Corresponding CICS Command Level API command: EXEC CICS MOVE CONTAINER

Example: 

var cics = new Cics();
var moveContainerChannel = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input  
 */
var moveContainerChannel = 
	{container : "FIRSTCON",
	 channel : "FIRSTCHN", 	
	 tochannel: "NEWCHANNEL",
	 as : "NEWCONTAINER"
	}
/*
 * Move the container to a new channel (it will be removed from the old one) 
 */
try
{
    cics.exec.moveContainerChannel ( moveContainerChannel ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * All done 
 */

putContainerChannel()

Description:  Place data in a named channel container.

Properties:

NameTypeMaximum LengthInput/Output
appendBoolean
Input
channelString16Input
containerString16Input
datatypeCVDA
Input
flengthNumeric>32KInput
fromString>32KInput

Corresponding CICS Command Level API command: EXEC CICS PUT CONTAINER CHANNEL

Example: 

var cics = new Cics();
var putContainerChannel = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input  
 * For the datatype parameter, BIT is 1020 and CHAR is 1019
 */
var putContainerChannel = 
	{container : "FIRSTCON",
	 channel : "FIRSTCHN", 	
	 from: "BLAH",
	 flength : 4,
	 append : true,
	 datatype: 1020
	}
/*
 * Put data in a container   
 */
try
{
    cics.exec.putContainerChannel ( putContainerChannel ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tRespPut1 = ', cics.eib.eibresp);
writeln('\tResp2Put1 = ', cics.eib.eibresp2);
/*
 * Put data in a container again to test append  
 */
/*
 * Set up input  
 * For the datatype parameter, BIT is 1020 and CHAR is 1019
 */
var putContainerChannel = 
	{container : "FIRSTCON",
	 channel : "FIRSTCHN", 	
	 from: "BLA2",
	 flength : 4,
	 append : true,
	 datatype: 1020
	}
try
{
    cics.exec.putContainerChannel ( putContainerChannel ) ;  // execute the EXEC CICS API request
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tRespPut2 = ', cics.eib.eibresp);
writeln('\tResp2Put2 = ', cics.eib.eibresp2);
/*
 * Now get the channel container contents
 * Set up input
 */
var getContainerChannel = 
	{channel : "FIRSTCHN",
	 container: "FIRSTCON"
	}
/*
 * Get the container
 */
try
{
	cics.exec.getContainerChannel ( getContainerChannel ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tRespGet = ', cics.eib.eibresp);
writeln('\tResp2Get = ', cics.eib.eibresp2);
writeln('\tInto = ', getContainerChannel.into);
writeln('\tFlength = ', getContainerChannel.flength, '\n');
/*
 * All Done  
 */

querySecurity()

Description:  To query the security authorization of the user.

Properties:

NameTypeMaximum LengthInput/Output
alterCVDA
Output
controlCVDA
Output
logmessageCVDA
Input
readCVDA
Output
resclassString8Input
residString246Input
residlengthNumeric
Input
restypeString12Input
updateCVDA
Output

The following are valid RESTYPE values:

ATOMSERVICE, BUNDLE, DB2ENTRY, DOCTEMPLATE, EPADAPTER, EPADAPTERSET, EVENTBINDING, FILE, JOURNALNAME, JOURNALNUM, JVMSERVER, PROGRAM, PSB, SPCOMMAND, TDQUEUE, TRANSACTION, TRANSATTACH, TSQUEUE, TSQNAME, and XMLTRANSFORM.

Note:  If the value for RESTYPE is equal to SPCOMMAND, then RESID must be one of the following values: 

ASSOCIATION, ATOMSERVICE, AUTINSTMODEL, AUTOINSTALL, BRFACILITY, BUNDLE, BUNDLEPART, CAPDATAPRED, CAPINFOSRCE, CAPOPTPRED, CAPTURESPEC, CFDTPOOL, CONNECTION, CSD, DB2CONN, DB2ENTRY, DB2TRAN, DISPATCHER, DOCTEMPLATE, DSNAME, DUMP, DUMPDS, ENQUEUE, EPADAPTER, EPADAPTERSET, EPADAPTINSET, EVENTBINDING, EVENTPROCESS, EXCI, EXITPROGRAM, FEPIRESOURCE, FILE, HOST, IPCONN, IRC, JOURNALMODEL, JOURNALNAME, JVMSERVER, LIBRARY, MODENAME, MONITOR, MQCONN, MQMON, MVSTCB, OSGIBUNDLE, OSGISERVICE, PARTNER, PIPELINE, PROCESS, PROFILE, PROGRAM, REQID, REQUEST, RESETTIME, RRMS, SECURITY, SHUTDOWN, STATISTICS, STORAGE, SUBPOOL, SYSDUMPCODE, SYSTEM, TASK, TCLASS, TCPIP, TCPIPSERVICE, TDQUEUE, TEMPSTORAGE, TERMINAL, TRACEDEST, TRACEFLAG, TRACETYPE, TRANDUMPCODE, TRANSACTION, TSQUEUE, TSMODEL, TSPOOL, TYPETERM, UOW, UOWDSNFAIL, UOWENQ, UOWLINK, URIMAP, VOLUME, VTAM, WEB, WEBSERVICE, XMLTRANSFORM

Corresponding CICS Command Level API command: EXEC CICS QUERY SECURITY

Example: 

var cics = new Cics();
var querySecurity = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 * For logmessage, LOG is 54 and NOLOG is 55
 */
var querySecurity = 
	{ restype : "FILE",
	  resid : "4",
	  logmessage : 55
	}	
/*
 * Inquire on security of the resource
 */
try
{
    cics.exec.querySecurity (	querySecurity ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 * For alter, ALTERABLE is 52 and NOTALTERABLE is 53 
 * For control, CTRLABLE is 56 and NOTCTRLABLE is 57
 * For read, READABLE is 35 and NOTREADABLE is 36
 * For update, UPDATABLE is 37 and NOTUPDATABLE is 38
 */
for (var prop in querySecurity) {
	writeln('\t', prop, ' = ', querySecurity[prop]);
}
/*
 * Set up input
 */
var querySecurity = 
	{ restype : "SPCOMMAND",
	  resid : "PROGRAM",
	  logmessage : 54
	}	
/*
 * Inquire on security of the resource 
 */
try
{
    cics.exec.querySecurity (	querySecurity ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in querySecurity) {
	writeln('\t', prop, ' = ', querySecurity[prop]);
}

readFile()

Description:  Read a record from a VSAM file.

Properties:

NameTypeMaximum LengthInput/Output
consistentBoolean
Input
debkeyBoolean
Input
debrecBoolean
Input
equalBoolean
Input
fileString8Input
genericBoolean
Input
gteqBoolean
Input
intoString32K-1Output
keylengthNumeric
Input
lengthNumeric
Input/Output
nosuspendBoolean
Input
rbaBoolean
Input
repeatableBoolean
Input
ridfldString255Input
rrnBoolean
Input
sysidString4Input
tokenNumeric
Output
uncommittedBoolean
Input
updateBoolean
Input
xrbaBoolean
Input

Corresponding CICS Command Level API command: EXEC CICS READ FILE

Example: 

var cics = new Cics();
var readFile = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var readFile = 
	{ file : "ZIPTABLE",
	  ridfld : "0607",
	  sysid : "CICF",
	  generic : true,
	  gteq : true
	}	
/*
 * Read the file  
 */
try
{
    cics.exec.readFile ( readFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readFile) {
	writeln('\t', prop, ' = ', readFile[prop]);
}

readNextFile()

Description:  Read the next record from a VSAM file.

Properties:

NameTypeMaximum LengthInput/Output
consistentBoolean
Input
fileString8Input
intoString32K-1Output
keylengthNumeric
Input
lengthNumeric
Input/Output
nosuspendBoolean
Input
rbaBoolean
Input
repeatableBoolean
Input
reqidNumeric
Input
ridfldString255Input
rrnBoolean
Input
sysidString4Input
tokenNumeric
Output
uncommittedBoolean
Input
updateBoolean
Input
xrbaBoolean
Input

Corresponding CICS Command Level API command: EXEC CICS READNEXT FILE

Example:  (Lines 37 through 92)

var cics = new Cics();
var startBrowseFile = new Object();
var readNextFile = new Object();
var readPrevFile = new Object();
var endBrowseFile = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
writeln('Starting startBrowse');
var startBrowseFile = 
	{ file : "ZIPTABLE",
	  ridfld : "005020000",
	  sysid : "CICF",
	  gteq : true,
	  keylength : 9
	}	  
/*
 * Set browser pointer
 */
try
{
    cics.exec.startBrowseFile ( startBrowseFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in startBrowseFile) {
	writeln('\t', prop, ' = ', startBrowseFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readNext');
var readNextFile = 
	{ file : "ZIPTABLE",
	  ridfld : startBrowseFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the next record
 */
try
{
    cics.exec.readNextFile ( readNextFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readNextFile) {
	writeln('\t', prop, ' = ', readNextFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readNext 2');
var readNextFile = 
	{ file : "ZIPTABLE",
	  ridfld : readNextFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the next record
 */
try
{
    cics.exec.readNextFile ( readNextFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readNextFile) {
	writeln('\t', prop, ' = ', readNextFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readPrev'); 
var readPrevFile = 
	{ file : "ZIPTABLE",
	  ridfld : readNextFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the previous record
 */
try
{
    cics.exec.readPrevFile ( readPrevFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readPrevFile) {
	writeln('\t', prop, ' = ', readPrevFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readPrev 2');
var readPrevFile =
	{ file : "ZIPTABLE",
      ridfld : readPrevFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the previous record
 */
try
{
    cics.exec.readPrevFile ( readPrevFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readPrevFile) {
	writeln('\t', prop, ' = ', readPrevFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting endBrowse');
var endBrowseFile = 
	{ file : "ZIPTABLE"		
	}
/*
 * End a browse
 */
try
{
    cics.exec.endBrowseFile ( endBrowseFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in endBrowseFile) {
	writeln('\t', prop, ' = ', endBrowseFile[prop]);
}

readPrevFile()

Description:  Read the previous record from a VSAM file.

Properties:

NameTypeMaximum LengthInput/Output
consistentBoolean
Input
fileString8Input
intoString32K-1Output
keylengthNumeric
Input
lengthNumeric
Input/Output
nosuspendBoolean
Input
rbaBoolean
Input
repeatableBoolean
Input
reqidNumeric
Input
ridfldString255Input
rrnBoolean
Input
sysidString4Input
tokenNumeric
Output
uncommittedBoolean
Input
updateBoolean
Input
xrbaBoolean
Input

Corresponding CICS Command Level API command: EXEC CICS READPREV FILE

Example: (Lines 93-148)

var cics = new Cics();
var startBrowseFile = new Object();
var readNextFile = new Object();
var readPrevFile = new Object();
var endBrowseFile = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
writeln('Starting startBrowse');
var startBrowseFile = 
	{ file : "ZIPTABLE",
	  ridfld : "005020000",
	  sysid : "CICF",
	  gteq : true,
	  keylength : 9
	}	  
/*
 * Set browser pointer
 */
try
{
    cics.exec.startBrowseFile ( startBrowseFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in startBrowseFile) {
	writeln('\t', prop, ' = ', startBrowseFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readNext');
var readNextFile = 
	{ file : "ZIPTABLE",
	  ridfld : startBrowseFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the next record
 */
try
{
    cics.exec.readNextFile ( readNextFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readNextFile) {
	writeln('\t', prop, ' = ', readNextFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readNext 2');
var readNextFile = 
	{ file : "ZIPTABLE",
	  ridfld : readNextFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the next record
 */
try
{
    cics.exec.readNextFile ( readNextFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readNextFile) {
	writeln('\t', prop, ' = ', readNextFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readPrev'); 
var readPrevFile = 
	{ file : "ZIPTABLE",
	  ridfld : readNextFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the previous record
 */
try
{
    cics.exec.readPrevFile ( readPrevFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readPrevFile) {
	writeln('\t', prop, ' = ', readPrevFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readPrev 2');
var readPrevFile =
	{ file : "ZIPTABLE",
      ridfld : readPrevFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the previous record
 */
try
{
    cics.exec.readPrevFile ( readPrevFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readPrevFile) {
	writeln('\t', prop, ' = ', readPrevFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting endBrowse');
var endBrowseFile = 
	{ file : "ZIPTABLE"		
	}
/*
 * End a browse
 */
try
{
    cics.exec.endBrowseFile ( endBrowseFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in endBrowseFile) {
	writeln('\t', prop, ' = ', endBrowseFile[prop]);
}

readTdQ()

Description:  Read a record in a transient data queue.

Link to correct documentation: Cics.readTdQ()  

readTsQ()

Description:  Read an item in a temporary storage queue. 

Link to correct documentation: Cics.readTsQ()  

receive()

Description:  Receive data from standard CICS terminal support.

Properties:

NameTypeMaximum LengthInput/Output
asisBoolean
Input
bufferBoolean
Input
intoString32K-1Output

Corresponding CICS Command Level API command: EXEC CICS RECEIVE

Example:   

var cics = new Cics();
var receiveDataStream = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var receiveDataStream = 
	{ asis : true,
	  buffer : true
	}	  
/*
 * Receive a data stream
 */
try
{
    cics.exec.receive ( receiveDataStream ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in receiveDataStream) {
	writeln('\t', prop, ' = ', receiveDataStream[prop]);
}

The receive object must be specified within the context of a script that either is defined as part of a transaction that utilizes BMS mapping, or is directly invoked by that transaction (by calling HBR$JSE). Otherwise, the receive will fail with an ABM3 abend. To test the above, MAKE the script in the IDE, naming it _tranid_XXXX, where XXXX is the transaction ID you will use on the target CICS. Then, set up a transaction definition for XXXX that points to program HBR$JSE. Finally, execute the transaction XXXX - the script will be executed successfully.

resetBrowseFile()

Description:  Resets the starting browse point of a VSAM file.

Properties:

NameTypeMaximum LengthInput/Output
equalBoolean
Input
fileString8Input
genericBoolean
Input
gteqBoolean
Input
keylengthNumeric
Input
rbaBoolean
Input
reqidNumeric
Input
ridfldString255Input
rrnBoolean
Input
sysidString4Input
xrbaBoolean
Input

Corresponding CICS Command Level API command: EXEC CICS RESETBR FILE

Example:  (lines 94-122)

var cics = new Cics();
var startBrowseFile = new Object();
var resetBrowseFile = new Object();
var readNextFile = new Object();
var readPrevFile = new Object();
var endBrowseFile = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
writeln('Starting startBrowse');
var startBrowseFile = 
	{ file : "ZIPTABLE",
	  ridfld : "005020000",
	  sysid : "CICF",
	  gteq : true,
	  keylength : 9
	}	  
/*
 * Set browser pointer
 */
try
{
    cics.exec.startBrowseFile ( startBrowseFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in startBrowseFile) {
	writeln('\t', prop, ' = ', startBrowseFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readNext');
var readNextFile = 
	{ file : "ZIPTABLE",
	  ridfld : startBrowseFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the next record
 */
try
{
    cics.exec.readNextFile ( readNextFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readNextFile) {
	writeln('\t', prop, ' = ', readNextFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readNext 2');
var readNextFile = 
	{ file : "ZIPTABLE",
	  ridfld : readNextFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the next record
 */
try
{
    cics.exec.readNextFile ( readNextFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readNextFile) {
	writeln('\t', prop, ' = ', readNextFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting resetBrowse');
var resetBrowseFile = 
	{ file : "ZIPTABLE",
	  ridfld : "888880000",
	  sysid : "CICF",
	  gteq : true,
	  keylength : 9
	}	  
/*
 * Set browser pointer
 */
try
{
    cics.exec.resetBrowseFile ( resetBrowseFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in resetBrowseFile) {
	writeln('\t', prop, ' = ', resetBrowseFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readPrev'); 
var readPrevFile = 
	{ file : "ZIPTABLE",
	  ridfld : resetBrowseFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the previous record
 */
try
{
    cics.exec.readPrevFile ( readPrevFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readPrevFile) {
	writeln('\t', prop, ' = ', readPrevFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readPrev 2');
var readPrevFile =
	{ file : "ZIPTABLE",
      ridfld : readPrevFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the previous record
 */
try
{
    cics.exec.readPrevFile ( readPrevFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readPrevFile) {
	writeln('\t', prop, ' = ', readPrevFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting endBrowse');
var endBrowseFile = 
	{ file : "ZIPTABLE"		
	}
/*
 * End a browse
 */
try
{
    cics.exec.endBrowseFile ( endBrowseFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in endBrowseFile) {
	writeln('\t', prop, ' = ', endBrowseFile[prop]);
}

retrieve()

Description:  Retrieve data stored for a task.

Properties:

NameTypeMaximum LengthInput/Output
intoString32K-1Output
lengthNumeric
Input
queueString8Input
rtermidString4Input
rtransidString4Input
waitBoolean
Input

Corresponding CICS Command Level API command: EXEC CICS RETRIEVE

Example:  

var cics = new Cics();
var retrieve = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var retrieve = 
	{ wait : true,
	  length : 1920
	}	  
/*
 * Retrieve data from a previously STARTed task
 */
try
{
    cics.exec.retrieve ( retrieve ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in retrieve) {
	writeln('\t', prop, ' = ', retrieve[prop]);
}

rewriteFile()

Description:  Update a record in a file.

Properties:

NameTypeMaximum LengthInput/Output
fileString8Input
fromString32K-1Output
lengthNumeric
Input
nosuspendBoolean
Input
sysidString4Input
tokenNumeric
Input

Corresponding CICS Command Level API command: EXEC CICS REWRITE FILE

Example:  (lines 68-96)

var cics = new Cics();
var writeFile = new Object();
var readUpdateFile = new Object();
var rewriteFile = new Object();
var unlockFile = new Object();
var deleteFIle = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
writeln('Starting write');
var writeFile = 
	{ file : "ZIPTABLE",
	  ridfld : "777770000",
	  sysid : "CICF",
	  from : "777770000Blik                                                                             ",
	  keylength : 9,
	  length : 90
	}	  
/*
 * Write a new record
 */
try
{
    cics.exec.writeFile ( writeFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in writeFile) {
	writeln('\t', prop, ' = ', writeFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting read file for update');
var readUpdateFile = 
	{ file : "ZIPTABLE",
	  ridfld : '777770000',
	  sysid : "CICF",
	  keylength : 9,
	  update : true
	}
/*
 * Read a record for update
 */
try
{
    cics.exec.readFile ( readUpdateFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readUpdateFile) {
	writeln('\t', prop, ' = ', readUpdateFile[prop]);
}
/*
 * Set up input for rewrite.  Note that by implementation default, a token is created by the read for update.  The rewrite must specify that token or an INVREQ will occur. 
 */
writeln('Starting rewrite');
var rewriteFile = 
	{ file : "ZIPTABLE",
	  from : "777770000John                                                                             ",
	  sysid : "CICF",
	  token : readUpdateFile.token,
	  length : 90
	}
/*
 * Rewrite the record
 */
try
{
    cics.exec.rewriteFile ( rewriteFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in rewriteFile) {
	writeln('\t', prop, ' = ', rewriteFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting read file for update (again)');
var readUpdateFile = 
	{ file : "ZIPTABLE",
	  ridfld : '777770000',
	  sysid : "CICF",
	  keylength : 9,
	  update : true
	}
/*
 * Read a record for update (again)
 */
try
{
    cics.exec.readFile ( readUpdateFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readUpdateFile) {
	writeln('\t', prop, ' = ', readUpdateFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting unlock'); 
var unlockFile = 
	{ file : "ZIPTABLE",
      token : readUpdateFile.token,
	  sysid : "CICF"
	}
/*
 * Unlock record held for update
 */
try
{
    cics.exec.unlockFile ( unlockFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in unlockFile) {
	writeln('\t', prop, ' = ', unlockFile[prop]);
}
/*
 * Delete the previously written record
 */
writeln('Starting delete');
var deleteFile = 
	{ file : "ZIPTABLE",
	  ridfld : "777770000",	
	  sysid : "CICF "
}
/*
 * Delete a record
 */
try
{
    cics.exec.deleteFile ( deleteFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in deleteFile) {
	writeln('\t', prop, ' = ', deleteFile[prop]);
}

runTransid()

Description:  RUN TRANSID initiates a local child transaction that runs asynchronously with
the parent transaction.

Properties:

NameTypeMaximum LengthInput/Output
transidstring4Input
channelstring16Input
childstring16Output

Corresponding CICS Command Level API command: EXEC CICS RUN TRANSID

Example: 

var cics = new Cics();
var runTransid = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var runTransid =
    { channel : 'RUNTRANSIDTEST01',
      transid : 'HBNL'      
    }    
/*
 * Run a transaction
 */
try
{
    cics.exec.runTransid ( runTransid ) ;
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in runTransid) {
    writeln('\t', prop, ' = ', runTransid[prop]);
}


sendText()

Description:  Send text to a 3270 terminal.

Properties:

NameTypeMaximum LengthInput/Output
alternateBoolean
Input
eraseBoolean
Input
fromString32K-1Output

Corresponding CICS Command Level API command: EXEC CICS SEND TEXT

Example:  

var cics = new Cics();
var sendText = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var sendText = 
	{ alternate : false,
      erase : true,
	  from : 'THIS IS A TEST'
	}	  
/*
 * Send the text
 */
try
{
    cics.exec.sendText ( sendText ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in sendText) {
	writeln('\t', prop, ' = ', sendText[prop]);
}

The sendText object must be specified within the context of a script that either is defined as part of a transaction that utilizes BMS mapping, or is directly invoked by that transaction (by calling HBR$JSE). Otherwise, the sendText will fail with an ABM3 abend. To test the above, MAKE the script in the IDE, naming it _tranid_XXXX, where XXXX is the transaction ID you will use on the target CICS. Then, set up a transaction definition for XXXX that points to program HBR$JSE. Finally, execute the transaction XXXX - the script will be executed successfully.

signalEvent()

Description:  

Identify a place in a script where one or more events could be emitted.

Properties:

NameTypeMaximum LengthInput/Output
eventString256Input
fromString64K-1Input
fromchannelString16Input
fromlengthNumeric
Input

Corresponding CICS Command Level API command: EXEC CICS SIGNAL EVENT

Example:  

var cics = new Cics();
var signalEvent = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var signalEvent = 
	{ from : 'This is an event',
      event : 'NAME_OF_THE_EVENT',
	  fromlength : 16
	}	  
/*
 * Send the text
 */
try
{
    cics.exec.signalEvent ( signalEvent ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in signalEvent) {
	writeln('\t', prop, ' = ', signalEvent[prop]);
}

spoolclose()

Description:  

Close a spool report.

Properties:

NameTypeMaximum LengthInput/Output
deleteBoolean
Input
keepBoolean
Input
tokenString8Input

Corresponding CICS Command Level API command: EXEC CICS SPOOLCLOSE

Example:  (lines 83-108)

var cics = new Cics();
var spoolopenInput = new Object();
var spoolread = new Object();
var spoolclose = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
writeln('Doing spoolopenInput');
var spoolopenInput =
    { userid : 'CICSE' }
/*
 * Open for reading of spool file
 */
try
{
    cics.exec.spoolopenInput ( spoolopenInput ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolopenInput) {
    writeln('\t', prop, ' = ', spoolopenInput[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolread 1')
var spoolread =
    { token : spoolopenInput.token,
      maxflength : 132
    }    
/*
 * Read a line from a spool file
 */
try
{
    cics.exec.spoolread ( spoolread ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolread) {
    writeln('\t', prop, ' = ', spoolread[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolread 2')
var spoolread =
    { token : spoolopenInput.token,
      maxflength : 132
    }    
/*
 * Read a line from a spool file
 */
try
{
    cics.exec.spoolread ( spoolread ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolread) {
    writeln('\t', prop, ' = ', spoolread[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolclose');
var spoolclose =
    { token : spoolopenInput.token,
      delete : true
    }    
/*
 * Close the spool
 */
try
{
    cics.exec.spoolclose ( spoolclose ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolclose) {
    writeln('\t', prop, ' = ', spoolclose[prop]);
}

spoolopenInput()

Description:  

Open a spool report.

Properties:

NameTypeMaximum LengthInput/Output
classString1Input
tokenString8Output
useridString8Input

Corresponding CICS Command Level API command: EXEC CICS SPOOLOPEN INPUT

Example:  (lines 7-30)

var cics = new Cics();
var spoolopenInput = new Object();
var spoolread = new Object();
var spoolclose = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
writeln('Doing spoolopenInput');
var spoolopenInput =
    { userid : 'CICSE' }
/*
 * Open for reading of spool file
 */
try
{
    cics.exec.spoolopenInput ( spoolopenInput ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolopenInput) {
    writeln('\t', prop, ' = ', spoolopenInput[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolread 1')
var spoolread =
    { token : spoolopenInput.token,
      maxflength : 132
    }    
/*
 * Read a line from a spool file
 */
try
{
    cics.exec.spoolread ( spoolread ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolread) {
    writeln('\t', prop, ' = ', spoolread[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolread 2')
var spoolread =
    { token : spoolopenInput.token,
      maxflength : 132
    }    
/*
 * Read a line from a spool file
 */
try
{
    cics.exec.spoolread ( spoolread ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolread) {
    writeln('\t', prop, ' = ', spoolread[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolclose');
var spoolclose =
    { token : spoolopenInput.token,
      delete : true
    }    
/*
 * Close the spool
 */
try
{
    cics.exec.spoolclose ( spoolclose ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolclose) {
    writeln('\t', prop, ' = ', spoolclose[prop]);
}
The example in the spoolwrite() object should be executed as a separate script before trying to read spool input; otherwise there will be no spool input to read and the example will fail.


spoolopenOutput()

Description:  

Open a spool report for output. 

Properties:

NameTypeMaximum LengthInput/Output
asaBoolean
Input
classString1Input
mccBoolean
Input
noccBoolean
Input
nodeString8Input
outdescrString256Input
printBoolean
Input
punchBoolean
Input
recordlengthNumeric
Input
tokenString8Output
useridString8Input

Corresponding CICS Command Level API command: EXEC CICS SPOOLOPEN OUTPUT

Example:  (lines 7-36)

var cics = new Cics();
var spoolopenOutput = new Object();
var spoolwrite = new Object();
var spoolclose = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
writeln('Doing spoolopenOutput');
var spoolopenOutput =
    { nocc : true,
      print : true,
      recordlength : 132,
      userid : 'CICSE', 
      node : 'LOCAL',
      msgclass : 'A'
    }    
/*
 * Open for printing
 */
try
{
    cics.exec.spoolopenOutput ( spoolopenOutput ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolopenOutput) {
    writeln('\t', prop, ' = ', spoolopenOutput[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolwrite 1');
var spoolwrite =
    { token : spoolopenOutput.token,
      line : true,
      from : 'This is the first line',
      flength : 132      
    }    
/*
 * Write a line to the spool
 */
try
{
    cics.exec.spoolwrite ( spoolwrite ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolwrite) {
    writeln('\t', prop, ' = ', spoolwrite[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolwrite 2');
var spoolwrite =
    { token : spoolopenOutput.token,
      line : true,
      from : 'This is the second line',
      flength : 132      
    }    
/*
 * Write a line to the spool
 */
try
{
    cics.exec.spoolwrite ( spoolwrite ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolwrite) {
    writeln('\t', prop, ' = ', spoolwrite[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolclose');
var spoolclose =
    { token : spoolopenOutput.token,		
      keep : true
    }    
/*
 * Close the spool
 */
try
{
    cics.exec.spoolclose ( spoolclose ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolclose) {
    writeln('\t', prop, ' = ', spoolclose[prop]);
}

spoolread()

Description:  

Reads data from a spool report.

Properties:

NameTypeMaximum LengthInput/Output
intoString32KOutput
maxflengthNumeric
Input
toflengthNumeric
Output
tokenString8Input

Corresponding CICS Command Level API command: EXEC CICS SPOOLREAD

Example:  (lines 31-56)

var cics = new Cics();
var spoolopenInput = new Object();
var spoolread = new Object();
var spoolclose = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
writeln('Doing spoolopenInput');
var spoolopenInput =
    { userid : 'CICSE' }
/*
 * Open for reading of spool file
 */
try
{
    cics.exec.spoolopenInput ( spoolopenInput ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolopenInput) {
    writeln('\t', prop, ' = ', spoolopenInput[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolread 1')
var spoolread =
    { token : spoolopenInput.token,
      maxflength : 132
    }    
/*
 * Read a line from a spool file
 */
try
{
    cics.exec.spoolread ( spoolread ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolread) {
    writeln('\t', prop, ' = ', spoolread[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolread 2')
var spoolread =
    { token : spoolopenInput.token,
      maxflength : 132
    }    
/*
 * Read a line from a spool file
 */
try
{
    cics.exec.spoolread ( spoolread ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolread) {
    writeln('\t', prop, ' = ', spoolread[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolclose');
var spoolclose =
    { token : spoolopenInput.token,
      delete : true
    }    
/*
 * Close the spool
 */
try
{
    cics.exec.spoolclose ( spoolclose ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolclose) {
    writeln('\t', prop, ' = ', spoolclose[prop]);
}

The example in the spoolwrite() object should be executed as a separate script before trying to read spool input; otherwise there will be no spool input to read and the example will fail.


spoolwrite()

Description:  

Writes data to a spool report.

Properties:

NameTypeMaximum LengthInput/Output
flengthNumeric
Input
fromString32KInput
lineBoolean
Input
pageBoolean
Input
tokenString8Input

Corresponding CICS Command Level API command: EXEC CICS SPOOLWRITE

Example:  (lines 37-64)

var cics = new Cics();
var spoolopenOutput = new Object();
var spoolwrite = new Object();
var spoolclose = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
writeln('Doing spoolopenOutput');
var spoolopenOutput =
    { nocc : true,
      print : true,
      recordlength : 132,
      userid : 'CICSE', 
      node : 'LOCAL',
      msgclass : 'A'
    }    
/*
 * Open for printing
 */
try
{
    cics.exec.spoolopenOutput ( spoolopenOutput ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolopenOutput) {
    writeln('\t', prop, ' = ', spoolopenOutput[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolwrite 1');
var spoolwrite =
    { token : spoolopenOutput.token,
      line : true,
      from : 'This is the first line',
      flength : 132      
    }    
/*
 * Write a line to the spool
 */
try
{
    cics.exec.spoolwrite ( spoolwrite ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolwrite) {
    writeln('\t', prop, ' = ', spoolwrite[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolwrite 2');
var spoolwrite =
    { token : spoolopenOutput.token,
      line : true,
      from : 'This is the second line',
      flength : 132      
    }    
/*
 * Write a line to the spool
 */
try
{
    cics.exec.spoolwrite ( spoolwrite ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolwrite) {
    writeln('\t', prop, ' = ', spoolwrite[prop]);
}
/*
 * Set up input
 */
writeln('Doing spoolclose');
var spoolclose =
    { token : spoolopenOutput.token,		
      keep : true
    }    
/*
 * Close the spool
 */
try
{
    cics.exec.spoolclose ( spoolclose ) ;
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in spoolclose) {
    writeln('\t', prop, ' = ', spoolclose[prop]);
}

start()

Description:  Start a task at a specified time.

Properties:

NameTypeMaximum LengthInput/Output
afterBoolean
Input
atBoolean
Input
fmhBoolean
Input
fromString32K-1Input
hoursNumeric
Input
intervalNumeric
Input
lengthNumeric
Input
minutesNumeric
Input
nocheckBoolean
Input
protectBoolean
Input
queueString8Input
reqidString8Input
rtermidString4Input
rtransidString4Input
secondsNumeric
Input
sysidString4Input
termidString4Input
timeNumeric
Input
transidString4Input
useridString8Input

Corresponding CICS Command Level API command: EXEC CICS START

Example:  

var cics = new Cics();
var startTrans = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var startTrans = 
	{ transid : 'HBNL',
      sysid : 'CICE',
      interval : 0
	}	  
/*
 * Send the text
 */
try
{
    cics.exec.start ( startTrans ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in startTrans) {
	writeln('\t', prop, ' = ', startTrans[prop]);
}

startChannel()

Description:  Start a task, passing it to a channel.

Properties:

NameTypeMaximum LengthInput/Output
channelString16Input
sysidString4Input
termidString4Input
transidString4Input
useridString8Input


Corresponding CICS Command Level API command: EXEC CICS START CHANNEL

Example:  


var cics = new Cics();
var startChannel = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var startChannel = 
	{ transid : 'HBNL',
      sysid : 'CICE',
      channel : 'THISISACHANNEL__'
	}	  
/*
 * Send the text
 */
try
{
    cics.exec.startChannel ( startChannel ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in startChannel) {
	writeln('\t', prop, ' = ', startChannel[prop]);
}

startBrowseContainer()

Description:  Start a browse of the containers associated with a channel.

Properties:

NameTypeMaximum LengthInput/Output
browsetokenNumeric
Output
channelString16Input


Corresponding CICS Command Level API command: EXEC CICS STARTBROWSE CONTAINER

Example:  


var cics = new Cics();
var startBrowseContainer = new Object();
var getNextContainer = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');

/*
 * Set up input
 */
var startBrowseContainer = 
	{channel : "CHANNELNAME00001" 
	}
/*
 * Start the browse of the container
 */
try
{
	cics.exec.startBrowseContainer ( startBrowseContainer ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
writeln('\tBrowsetoken = ', startBrowseContainer.browsetoken, '\n');
/*
 * Now get the next container name
 * Set up input
 */
var getNextContainer = 
	{browsetoken : startBrowseContainer.browsetoken 
	}
/*
 * Get the next container
 */
try
{
	cics.exec.getNextContainer ( getNextContainer ) ;  // execute the EXEC CICS API request 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * To access a single property 
 */
writeln('\tResp = ', cics.eib.eibresp);
writeln('\tResp2 = ', cics.eib.eibresp2);
writeln('\tContainer = ', getNextContainer.container, '\n');



startBrowseFile()

Description:  Begin a sequential browse of a VSAM file.

Properties:

NameTypeMaximum LengthInput/Output
debkeyBoolean
Input
debrecBoolean
Input
equalBoolean
Input
fileString8Input
genericBoolean
Input
gteqBoolean
Input
intoString32K-1Output
keylengthNumeric
Input
rbaBoolean
Input
reqidNumeric
Input
ridfldString255Input
rrnBoolean
Input
sysidString4Input
xrbaBoolean
Input

Corresponding CICS Command Level API command: EXEC CICS STARTBR FILE

Example:  (lines 8-36)

var cics = new Cics();
var startBrowseFile = new Object();
var readNextFile = new Object();
var readPrevFile = new Object();
var endBrowseFile = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
writeln('Starting startBrowse');
var startBrowseFile = 
	{ file : "ZIPTABLE",
	  ridfld : "005020000",
	  sysid : "CICF",
	  gteq : true,
	  keylength : 9
	}	  
/*
 * Set browser pointer
 */
try
{
    cics.exec.startBrowseFile ( startBrowseFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in startBrowseFile) {
	writeln('\t', prop, ' = ', startBrowseFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readNext');
var readNextFile = 
	{ file : "ZIPTABLE",
	  ridfld : startBrowseFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the next record
 */
try
{
    cics.exec.readNextFile ( readNextFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readNextFile) {
	writeln('\t', prop, ' = ', readNextFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readNext 2');
var readNextFile = 
	{ file : "ZIPTABLE",
	  ridfld : readNextFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the next record
 */
try
{
    cics.exec.readNextFile ( readNextFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readNextFile) {
	writeln('\t', prop, ' = ', readNextFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readPrev'); 
var readPrevFile = 
	{ file : "ZIPTABLE",
	  ridfld : readNextFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the previous record
 */
try
{
    cics.exec.readPrevFile ( readPrevFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readPrevFile) {
	writeln('\t', prop, ' = ', readPrevFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting readPrev 2');
var readPrevFile =
	{ file : "ZIPTABLE",
      ridfld : readPrevFile.ridfld,
	  sysid : "CICF",
	  keylength : 9
	}
/*
 * Read the previous record
 */
try
{
    cics.exec.readPrevFile ( readPrevFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readPrevFile) {
	writeln('\t', prop, ' = ', readPrevFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting endBrowse');
var endBrowseFile = 
	{ file : "ZIPTABLE"		
	}
/*
 * End a browse
 */
try
{
    cics.exec.endBrowseFile ( endBrowseFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in endBrowseFile) {
	writeln('\t', prop, ' = ', endBrowseFile[prop]);
}

syncpoint()

Description:  Establish a syncpoint.

Properties:  None

Corresponding CICS Command Level API command: EXEC CICS SYNCPOINT

Example: 

var cics = new Cics();
var syncpoint = new Object();
var syncpointRollback = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Inquire on the tsqueue (8 characters)
 */
try
{
    cics.exec.syncpoint (syncpoint ) ;
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in syncpoint) {
    writeln('\t', prop, ' = ', syncpoint[prop]);
}
try
{
    cics.exec.syncpointRollback( syncpointRollback) ;  // execute the EXEC CICS API request
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in syncpointRollback) {
    writeln('\t', prop, ' = ', syncpointRollback[prop]);
}

syncpointRollback()

Description:  Back out to last syncpoint.

Properties:  None

Corresponding CICS Command Level API command: EXEC CICS SYNCPOINT ROLLBACK

Example: 

var cics = new Cics();
var syncpoint = new Object();
var syncpointRollback = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Inquire on the tsqueue (8 characters)
 */
try
{
    cics.exec.syncpoint (syncpoint ) ;
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in syncpoint) {
    writeln('\t', prop, ' = ', syncpoint[prop]);
}
try
{
    cics.exec.syncpointRollback( syncpointRollback) ;  // execute the EXEC CICS API request
}
 
catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
    writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in syncpointRollback) {
    writeln('\t', prop, ' = ', syncpointRollback[prop]);
}

unlockFile()

Description:  Release exclusive control of a VSAM record previously read for update and then not updated.

Properties:

NameTypeMaximum LengthInput/Output
fileString8Input
sysidString4Input
tokenNumeric
Input

Corresponding CICS Command Level API command: EXEC CICS UNLOCK FILE

Example:  (lines 126-152)

var cics = new Cics();
var writeFile = new Object();
var readUpdateFile = new Object();
var rewriteFile = new Object();
var unlockFile = new Object();
var deleteFIle = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
writeln('Starting write');
var writeFile = 
	{ file : "ZIPTABLE",
	  ridfld : "777770000",
	  sysid : "CICF",
	  from : "777770000Blik                                                                             ",
	  keylength : 9,
	  length : 90
	}	  
/*
 * Write a new record
 */
try
{
    cics.exec.writeFile ( writeFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in writeFile) {
	writeln('\t', prop, ' = ', writeFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting read file for update');
var readUpdateFile = 
	{ file : "ZIPTABLE",
	  ridfld : '777770000',
	  sysid : "CICF",
	  keylength : 9,
	  update : true
	}
/*
 * Read a record for update
 */
try
{
    cics.exec.readFile ( readUpdateFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readUpdateFile) {
	writeln('\t', prop, ' = ', readUpdateFile[prop]);
}
/*
 * Set up input for rewrite.  Note that by implementation default, a token is created by the read for update.  The rewrite must specify that token or an INVREQ will occur. 
 */
writeln('Starting rewrite');
var rewriteFile = 
	{ file : "ZIPTABLE",
	  from : "777770000John                                                                             ",
	  sysid : "CICF",
	  token : readUpdateFile.token,
	  length : 90
	}
/*
 * Rewrite the record
 */
try
{
    cics.exec.rewriteFile ( rewriteFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in rewriteFile) {
	writeln('\t', prop, ' = ', rewriteFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting read file for update (again)');
var readUpdateFile = 
	{ file : "ZIPTABLE",
	  ridfld : '777770000',
	  sysid : "CICF",
	  keylength : 9,
	  update : true
	}
/*
 * Read a record for update (again)
 */
try
{
    cics.exec.readFile ( readUpdateFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readUpdateFile) {
	writeln('\t', prop, ' = ', readUpdateFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting unlock'); 
var unlockFile = 
	{ file : "ZIPTABLE",
      token : readUpdateFile.token,
	  sysid : "CICF"
	}
/*
 * Unlock record held for update
 */
try
{
    cics.exec.unlockFile ( unlockFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in unlockFile) {
	writeln('\t', prop, ' = ', unlockFile[prop]);
}
/*
 * Delete the previously written record
 */
writeln('Starting delete');
var deleteFile = 
	{ file : "ZIPTABLE",
	  ridfld : "777770000",	
	  sysid : "CICF "
}
/*
 * Delete a record
 */
try
{
    cics.exec.deleteFile ( deleteFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in deleteFile) {
	writeln('\t', prop, ' = ', deleteFile[prop]);
}

verifyPassword()

Description:  Verify that a password matches the password recorded by an external security manager.

Properties:

NameTypeMaximum LengthInput/Output
changetimeNumeric
Output
daysleftNumeric
Output
esmreasonNumeric
Output
esmrespNumeric
Output
expirytimeNumeric
Output
invalidcountNumeric
Output
lastusetimeNumeric
Output
passwordString8Input
useridString8Input

Corresponding CICS Command Level API command: EXEC CICS VERIFY PASSWORD

Example:  

var cics = new Cics();
var verifyPassword = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var verifyPassword = 
	{ password : 'XML4CICS',
      userid : 'JOHN'
	}	  
/*
 * Verify the password
 */
try
{
    cics.exec.verifyPassword ( verifyPassword ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in verifyPassword) {
	writeln('\t', prop, ' = ', verifyPassword[prop]);
}

verifyPhrase()

Description:  Verify that a passphrase matches the passphrase recorded by an external security manager.

Properties:

NameTypeMaximum LengthInput/Output
changetimeNumeric
Output
daysleftNumeric
Output
esmreasonNumeric
Output
esmrespNumeric
Output
expirytimeNumeric
Output
invalidcountNumeric
Output
lastusetimeNumeric
Output
phraseString100Input
phraselenNumeric
Input
useridString8Input

Corresponding CICS Command Level API command: EXEC CICS VERIFY PHRASE

Example:  

var cics = new Cics();
var verifyPhrase = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input - note that phraselen is calculated if not specified
 */
var verifyPhrase = 
	{ phrase : 'This is a passphrase',
      userid : 'JOHN'
	}	  
/*
 * Verify the passphrase
 */
try
{
    cics.exec.verifyPhrase ( verifyPhrase ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in verifyPhrase) {
	writeln('\t', prop, ' = ', verifyPhrase[prop]);
}

webClose()

Description:  Completes the application's use of a connection to a server for CICS as an HTTP client.

Properties:

NameTypeMaximum LengthInput/Output
sesstokenString8Input

Corresponding CICS Command Level API command: EXEC CICS WEB CLOSE

Example:

var cics = new Cics();
var webClose = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input - the sesstoken will be provided from a prior webOpenHost request) 
 */
var webCLose = 
	{ sesstoken : 'binary01'
    }	  
/*
 * Do the web close
 */
try
{
    cics.exec.webClose ( webClose ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in webClose) {
	writeln('\t', prop, ' = ', webCLose[prop]);
}

webConverse()

Description:  Verify that a passphrase matches the passphrase recorded by an external security manager.

Properties:

For sending the HTTP client request:

NameTypeMaximum LengthInput/Output
actionCVDA
Input
authenticateCVDA
Input
channelString16Input
charactersetString40Input
closestatusCVDA
Input
containerString16Input
docstatusCVDA
Input
doctokenString16Input
fromStringUnlimitedInput
fromlengthNumeric
Input
mediatypeString56Input
methodCVDA
Input
passwordString100Input
passwordlenNumeric
Input
pathString256Input
pathlenNumeric
Input
querystringString256Input
querystrlenNumeric
Input
sesstokenString8Input
urimapString8Input
usernameString8Input
usernamelenNumeric
Input

The fromlength, passwordlen, pathlen, querystrlen, and usernamelen properties are automatically calculated by the webConverse method. They should only be explicitly specified if the desired length value is to be different then the actual length of the associated data.

For sending the response from the server:

NameTypeMaximum LengthInput/Output
bodycharsetString40Input
intoStringUnlimitedInput
maxlengthNumeric
Input
mediatypeString56Input
notruncateBoolean
Input
statuscodeNumeric
Input
statuslenNumeric
Input
statustextString256Input
tochannelString16Input
tocontainerString16

Input

tolengthNumeric
Input

The statuslen and tolength properties are automatically calculated by the webConverse method. They should only be explicitly specified if the desired length value is to be different then the actual length of the associated data.

For converting items sent and received:

NameTypeMaximum LengthInput/Output
clientconvCVDA
Input

Corresponding CICS Command Level API command: EXEC CICS WEB CONVERSE

Example:  

var cics = new Cics();
var webConverse = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input (note that sesstoken and doctoken properties are provided by prior documentCreate and webOpenHttpHeader method invocations)
 *
 * The following are valid values for the CWDA properties:
 *
 * action - 747 (EXPECT)
 * authenticate - 1092 (BASICAUTH), 496 (NONE)
 * clientconv - 743 (CLICONVERT), 744 (NOCLICONVERT), 745 (NOINCONVERT), 746 (NOOUTCONVERT)
 * docstatus - 295 (DOCDELETE), 296 (NODOCDELETE)
 * method - 292 (DELETE), 748 (GET), 750 (HEAD), 759 (OPTIONS), 636 (POST), 749 (PUT), 760 (TRACE) 
 */
var webConverse = 
	{ authenticate : 1092,
      from : 'This is the message',
      mediatype : 'text/xml',
      method : 636,
      password : 'mypw',
      sesstoken : 'binary01',
      username : 'myuser'  
	}	  
/*
 * Do the web conversation
 */
try
{
    cics.exec.webConverse ( webConverse ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in webConverse) {
	writeln('\t', prop, ' = ', webConverse[prop]);
}

webEndBrowseHttpHeader()

Description:  Signal the end of an HTTP header browse.

Properties:

NameTypeMaximum LengthInput/Output
sesstokenString
Input

Corresponding CICS Command Level API command: EXEC CICS WEB ENDBROWSE HTTPHEADER

Example:  

var cics = new Cics();
var webEndBrowseHttpHeader = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input - note that the sesstoken property value is provided by a prior webStartBrowseHttpHeader method invocation
 */
var webEndBrowseHttpHeader = 
	{ sesstoken : 'BINARY01'
	}	  
/*
 * End the browse
 */
try
{
    cics.exec.webEndBrowseHttpHeader ( webEndBrowseHttpHeader ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in webEndBrowseHttpHeader) {
	writeln('\t', prop, ' = ', webEndBrowseHttpHeader[prop]);
}

webOpenHost()

Description:  Open a connection to a server for CICS as an HTTP client.

Properties:

NameTypeMaximum LengthInput/Output
certificateString32Input
ciphersString56Input
codepageString8Input
hostString256Input
hostlengthNumeric
Input
httprnumNumeric
Output
httpvnumNumeric
Output
numciphersNumeric
Input
portnumberNumeric
Input
schemeCVDA
Input
sesstokenString16Output

Corresponding CICS Command Level API command: EXEC CICS WEB OPEN HOST

Example:  

var cics = new Cics();
var webOpenHost = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input - note that hostlen is calculated if not specified
 * Valid values for the scheme property are 1096 (HTTP) and 1029 (HTTPS)
 */
var webOpenHost = 
	{ host : 'myhostdomain',
      portnumber : '4001',
      scheme : 1096
	}	  
/*
 * Perform the web open
 */
try
{
    cics.exec.webOpenHost ( webOpenHost ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in webOpenHost) {
	writeln('\t', prop, ' = ', webOpenHost[prop]);
}

webOpenUrimap()

Description:  Open a connection to a server for CICS as an HTTP client with a URIMAP.

Properties:

NameTypeMaximum LengthInput/Output
ciphersString56Input
codepageString8Input
httprnumNumeric
Output
httpvnumNumeric
Output
numciphersNumeric
Input
sesstokenString16Output
urimapString8Input

Corresponding CICS Command Level API command: EXEC CICS WEB OPEN URIMAP

Example:  

var cics = new Cics();
var webOpenUrimap = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input 
 */
var webOpenUrimap = 
	{  urimap : 'MYURIMAP'
	}	  
/*
 * Perform the web open
 */
try
{
    cics.exec.webOpenUrimap ( webOpenUrimap ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in webOpenUrimap) {
	writeln('\t', prop, ' = ', webOpenUrimap[prop]);
}


webParseUrl()

Description:  Break down a URL string into its component parts.

Properties:

NameTypeMaximum LengthInput/Output
hostString256Output
hostlengthNumeric
Output
hosttypeCVDA
Output
pathString256Output
pathlengthNumeric
Output
portnumberNumeric
Output
querystringString256Output
querystrlenNumeric
Output
schemenameNumeric256Output
urlString256Input
urllengthNumeric
Input

Corresponding CICS Command Level API command: EXEC CICS WEB PARSE URL

Example:  

var cics = new Cics();
var webParseUrl = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input - note that urllength is calculated if not specified
 */
var webParseUrl = 
	{ url : 'http://This_is_a_URL'       
	}	  
/*
 * Retrieve the URL information
 */
try
{
    cics.exec.webParseUrl ( webParseUrl ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 * For the hosttype property, the possible returned values are 302 (HOSTNAME), 300 (IPv4), and 301 (IPv6) 
 */
for (var prop in webParseUrl) {
	writeln('\t', prop, ' = ', webParseUrl[prop]);
}

webReadHttpHeader()

Description:  Extract HTTP header information.

Properties:

NameTypeMaximum LengthInput/Output
nameString256Input
namelengthNumeric
Input
sesstokenString8Input
valueString256Input
valuelengthNumeric
Input

Corresponding CICS Command Level API command: EXEC CICS WEB READ HTTPHEADER

Example:  

var cics = new Cics();
var webReadHttpHeader = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input - note that namelength and valuelength are calculated if not specified
 * The sesstoken value comes from a prior webOpenHost() or webOpenUrimap() method invocation
 */
var webReadHttpHeader = 
	{ sesstoken : 'BINARY01',
      name : 'HTTPHEADER01',
      value : 'This is a value'
	}	  
/*
 * Read the HTTP header
 */
try
{
    cics.exec.webReadHttpHeader ( webReadHttpHeader ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in webReadHttpHeader) {
	writeln('\t', prop, ' = ', webReadHttpHeader[prop]);
}

webReadNextHttpHeader()

Description:  Extract information from the next HTTP header.

Properties:

NameTypeMaximum LengthInput/Output
nameString256Input
namelengthNumeric
Input
sesstokenString8Input
valueString256Input
valuelengthNumeric
Input

Corresponding CICS Command Level API command: EXEC CICS WEB READNEXT HTTPHEADER

Example:  

var cics = new Cics();
var webReadNextHttpHeader = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input - note that namelength and valuelength are calculated if not specified
 * The sesstoken value comes from a prior startBrowseHttpHeader() method invocation
 */
var webReadNextHttpHeader = 
	{ sesstoken : 'BINARY01',
      name : 'HTTPHEADER01',
      value : 'This is a value'
	}	  
/*
 * Read the next HTTP header
 */
try
{
    cics.exec.webReadNextHttpHeader ( webReadNextHttpHeader ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in webReadNextHttpHeader) {
	writeln('\t', prop, ' = ', webReadNextHttpHeader[prop]);
}


webReceiveBinary()

Description:  Receive an HTTP response for CICS as an HTTP client.

Properties:

NameTypeMaximum LengthInput/Output
bodycharsetString40Output
clientconvCVDA
Input
intoStringUnlimitedOutput
lengthNumeric
Output
maxlengthNumeric
Input
mediatypeString56Output
notruncateBoolean
Input
sesstokenString16Input
statuscodeNumeric
Output
statuslenNumeric
Output
statustextString256Output

Corresponding CICS Command Level API command: EXEC CICS WEB RECEIVE

Example:  

var cics = new Cics();
var webReceiveBinary = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input - note that length and statuslen are calculated if not specified
 * Valid values for the clientconv property are 743 (CLICONVERT) and 744 (NOCLICONVERT)
 * The sesstoken property is taken from a prior webOpenHost() or webOpenUrimap() method invocation
 */
var webReceiveBinary = 
	{ into : aNewFieldWhereTheReceivedDataGoes, 
      sesstoken : 'BINARY01'
	}	  
/*
 * Do the receive
 */
try
{
    cics.exec.webReceiveBinary ( webReceiveBinary ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in webReceiveBinary) {
	writeln('\t', prop, ' = ', webReceiveBinary[prop]);
}

webStartBrowseHttpHeader()

Description:  Signal start of HTTP header browse.

Properties:

NameTypeMaximum LengthInput/Output
sesstokenString16Input

Corresponding CICS Command Level API command: EXEC CICS WEB STARTBROWSE HTTPHEADER

Example:  

var cics = new Cics();
var webStartBrowseHttpHeader = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input 
 * The sesstoken property is taken from a prior WebOpenHost() or webOpenUrimap() method invocation
 */
var webStartBrowseHttpHeader = 
	{ sesstoken : 'BINARY01'
	}	  
/*
 * Start to browse HTTP headers
 */
try
{
    cics.exec.webStartBrowseHttpHeader ( webStartBrowseHttpHeader ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in webStartBrowseHttpHeader) {
	writeln('\t', prop, ' = ', webStartBrowseHttpHeader[prop]);
}

webWriteHttpHeader()

Description:  Build HTTP header information.

Properties:

NameTypeMaximum LengthInput/Output
nameString256Input
namelengthNumeric
Input
sesstokenString8Input
valueString256Input
valuelengthNumeric
Input

Corresponding CICS Command Level API command: EXEC CICS WEB WRITE HTTPHEADER

Example:  

var cics = new Cics();
var webWriteHttpHeader = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input - note that namelength and valuelength are calculated if not specified
 * The sesstoken value comes from a prior webOpenHost() or webOpenUrimap() method invocation
 */
var webWriteHttpHeader = 
	{ sesstoken : 'BINARY01',
      name : 'HTTPHEADER01',
      value : 'This is a value'
	}	  
/*
 * Read the HTTP header
 */
try
{
    cics.exec.webWriteHttpHeader ( webWriteHttpHeader ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in webWriteHttpHeader) {
	writeln('\t', prop, ' = ', webWriteHttpHeader[prop]);
}

writeFile()

Description:  Write a new record to a file.

Properties:

NameTypeMaximum LengthInput/Output
fileString8Input
fromString32K-1Input
keylengthNumeric
Input
lengthNumeric
Input
massinsertBoolean
Input
nosuspendBoolean
Input
rbaBoolean
Input
ridfldString255Input
rrnBoolean
Input
sysidString4Input
xrbaBoolean
Input

Corresponding CICS Command Level API command: EXEC CICS WRITE FILE

Example:  (lines 9-38)

var cics = new Cics();
var writeFile = new Object();
var readUpdateFile = new Object();
var rewriteFile = new Object();
var unlockFile = new Object();
var deleteFIle = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
writeln('Starting write');
var writeFile = 
	{ file : "ZIPTABLE",
	  ridfld : "777770000",
	  sysid : "CICF",
	  from : "777770000Blik                                                                             ",
	  keylength : 9,
	  length : 90
	}	  
/*
 * Write a new record
 */
try
{
    cics.exec.writeFile ( writeFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in writeFile) {
	writeln('\t', prop, ' = ', writeFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting read file for update');
var readUpdateFile = 
	{ file : "ZIPTABLE",
	  ridfld : '777770000',
	  sysid : "CICF",
	  keylength : 9,
	  update : true
	}
/*
 * Read a record for update
 */
try
{
    cics.exec.readFile ( readUpdateFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readUpdateFile) {
	writeln('\t', prop, ' = ', readUpdateFile[prop]);
}
/*
 * Set up input for rewrite.  Note that by implementation default, a token is created by the read for update.  The rewrite must specify that token or an INVREQ will occur. 
 */
writeln('Starting rewrite');
var rewriteFile = 
	{ file : "ZIPTABLE",
	  from : "777770000John                                                                             ",
	  sysid : "CICF",
	  token : readUpdateFile.token,
	  length : 90
	}
/*
 * Rewrite the record
 */
try
{
    cics.exec.rewriteFile ( rewriteFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in rewriteFile) {
	writeln('\t', prop, ' = ', rewriteFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting read file for update (again)');
var readUpdateFile = 
	{ file : "ZIPTABLE",
	  ridfld : '777770000',
	  sysid : "CICF",
	  keylength : 9,
	  update : true
	}
/*
 * Read a record for update (again)
 */
try
{
    cics.exec.readFile ( readUpdateFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in readUpdateFile) {
	writeln('\t', prop, ' = ', readUpdateFile[prop]);
}
/*
 * Set up input
 */
writeln('Starting unlock'); 
var unlockFile = 
	{ file : "ZIPTABLE",
      token : readUpdateFile.token,
	  sysid : "CICF"
	}
/*
 * Unlock record held for update
 */
try
{
    cics.exec.unlockFile ( unlockFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in unlockFile) {
	writeln('\t', prop, ' = ', unlockFile[prop]);
}
/*
 * Delete the previously written record
 */
writeln('Starting delete');
var deleteFile = 
	{ file : "ZIPTABLE",
	  ridfld : "777770000",	
	  sysid : "CICF "
}
/*
 * Delete a record
 */
try
{
    cics.exec.deleteFile ( deleteFile ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in deleteFile) {
	writeln('\t', prop, ' = ', deleteFile[prop]);
}

writeJournalname()

Description:  Create a journal record.

Properties:

NameTypeMaximum LengthInput/Output
flengthNumeric
Output
fromString32K-400Output
journalnameString8Output
jtypeidString2Output
nosuspendBoolean
Output
pfxlengNumeric
Output
prefixString32K-400Output
reqidNumeric
Output
waitBoolean
Output

Corresponding CICS Command Level API command: EXEC CICS WRITE JOURNALNAME

Example:  

var cics = new Cics();
var writeJournal = new Object();
var common = require('common', 'hbutils');
var debugging = require('debugging', 'hbutils');
/*
 * Set up input
 */
var writeJournal = 
	{ journalname : 'DFHLOG',
      jtypeid : 'JB',
      from : 'This is a test of the exec.cics writejournal broadcast system - this is only a test',
      flength : 83	  
	}	  
/*
 * Write the journal record
 */
try
{
    cics.exec.writeJournalname ( writeJournal ) ; 
}

catch ( e )  // the following will display any return codes that are returned from the call, which equate to the RESP and RESP2 values returned from the request
{
	writeln(debugging.object(e, 'Error Object'));
}
/*
 * Iterate over all of the properties
 */
for (var prop in writeJournal) {
	writeln('\t', prop, ' = ', writeJournal[prop]);
}

writeTdQ()

Description:  Write a record to a transient data queue.

Link to correct documentation: Cics.writeTdQ()  

writeTsQ()

Description: Write an item to a temporary storage queue.

Link to correct documentation: Cics.writeTsQ()  

  • No labels
Write a comment…