gtpc2m1h | C/C++ Language Support User's Guide |
This function informs the control program that the entry control block
(ECB) has ended with a shared resource. It is used with the
enqc function.
Format
include <tpfapi.h>
int deqc(char *deq_name,
enum e_qual ssu_qual);
- deq_name
- The address of an 8-byte area that contains the deqc resource
name.
- ssu_qual
- Subsystem user (SSU) qualification for the resource. The argument
must belong to the enumerated type e_qual, which is defined in the
tpfapi.h header file. Use one of the following
predefined terms:
- QUAL_U
- Subsystem qualification applies. The resource name is subsystem
unique and is qualified by the database index (DBI) value for the
subsystem.
- QUAL_S
- System wide qualification applies. The resource name is not
subsystem unique. Any ECB issuing an enqc function with
QUAL_S will be enqueued on the same named resource. If two
enqc functions are issued with the same resource name but different
ssu_qual values, two different resource names are assumed to
exist. The deqc function must have the same
ssu_qual value as the enqc function.
Normal Return
Integer value of zero.
Error Return
A system error is issued if you are attempting to call deqc from
a resource that will never be held by this ECB through the enqc
function. The ECB will exit.
Programming Considerations
- The resource must have been defined using the enqc
function.
Examples
The following example dequeues a shared resource with ssu_qual
defined as QUAL_S.
#include <tpfapi.h>
char resource_name[8];
deqc(resource_name, QUAL_S);
Related Information
enqc-Define and Enqueue a Resource.