HP 3000 Manuals

##RJIN Procedural Interface [ RJE User/Programmer Reference Manual ] MPE/iX 5.0 Documentation


RJE User/Programmer Reference Manual

#RJIN Procedural Interface 

The input file reference may be to a user-written procedure, which must
conform to the following format:

     INTEGER PROCEDURE procedurename ({target});
     ARRAY {target};

When the user procedure is called by RJE, it should move an input record
into target and then return control to RJE; the value of the procedure
should be assigned the length of the record.  The maximum allowable size
of target is 128 words or -256 bytes.  In addition, you should also
return the equivalent of condition code equal (CCE) at Q-1.

The variable should be declared in an SPL procedure like this:

     INTEGER MYCC=Q-1;

where MYCC =     0 for condition code greater (CCG)

                 1 for condition code less (CCL)

                 2 for condition code equal (CCE)

All other values are undefined.  Return the equivalent of a CCE in a
normal situation, a CCG for an end of file and a CCL for any other error.
The maximum allowable size of target is 128 words or -256 bytes.

RJE transmits the record from target to the remote processor and calls
procedurename again.  This continues until all input records have been
transmitted.  At this time, the procedure should return a value
equivalent to condition code greater (CCG) in Q-1 to RJE.

#RJOUT, #RJLIST, and #RJPUNCH Procedural Interface 

The output file reference for these commands may be a user-written
procedure which must conform to the following format:

     PROCEDURE procedurename({target},{count});
     VALUE {count};
     INTEGER {count};
     ARRAY {target};

RJE moves an output record into the array target and call the
user-written output procedure procedurename.  The size of the array
target, a negative byte count, is passed by value as count in the
procedure call.  The user-written procedure then processes the output
record and returns control to RJE. Carriage control is converted to HP
format but this information is not passed with the data received; it is
placed in location Q-6.

When the #RJOUT, #RJLIST, #RJPUNCH command receives an end of data, it
passes an EOT indicator through location Q-7.  This allows the output
procedure to detect the end of transmission.

     Example Declarations 

LOGICAL CCTL = Q-6  << Carriage Control Information >>

LOGICAL EOT = Q-7   << End Of Transmission>>

RJE ceases to call the output procedure after all output records have
been received and the #RJOUT, #RJLIST, or #RJPUNCH command completes.



MPE/iX 5.0 Documentation