08.11.2014 Views

Software Reference Manual - NetEx

Software Reference Manual - NetEx

Software Reference Manual - NetEx

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Receiving Block Module (RBM)<br />

This module is called once to open the file and establish communications. Afterwards, it is called each time a<br />

block of file data arrives from NETEX. It is the responsibility of the receiving block module to decode all file<br />

transfer protocol information contained within the NETEX data block. The block module will then call the<br />

receiving record module once for each logical record contained within the file. Overall logic flow for this<br />

module is as follows:<br />

1. When entered, it checks the entry the first time. It examines the file MODE specified by the user and subtracts<br />

the appropriate header length from the BLOCK = value passed by the control module. It then calls<br />

the receiving record module for the first time providing the passed file parameters and the adjusted<br />

BLOCK= size.<br />

2. On successful return from the receiving record module, the file will have been opened. Also returned by<br />

the record module is the maximum logical record length that will be encountered in the file. The block<br />

module will add the record header length to the maximum record length and return the value to the RCV<br />

module. At this point, the block module returns to the control module.<br />

3. On the next entry to the block module, the first buffer of information from the sending block module will<br />

be provided. Based on the file MODE, the block module will decode the logical record information and<br />

call the record module once for each logical record. When the block is exhausted, the block module will<br />

return to receive another buffer.<br />

4. If an end of information or terminal error indication is encountered in the incoming data stream, the block<br />

module will call the record module for the last time with an error or EOI indication. On return from the<br />

block module, the file should be closed and a termination message will normally be produced by the record<br />

module.<br />

5. If the record module returns a message or abnormal end error, the block module will forward the message<br />

to the control module. If abnormal end was indicated it will free any allocated data areas since the module<br />

was called for the last time.<br />

Sending Block Module (SBM)<br />

The sending block module is responsible for providing blocks of file information to be sent to a receiving remote<br />

BFX application. When called the first time, it will call the sending record module to open the file and<br />

determine record and record size requirements. Its logic proceeds as follows:<br />

1. When entered, it checks the entry the first time. It examines the file MODE specified by the user and subtracts<br />

the appropriate header length from the BLOCK = value passed by the control module. It then calls<br />

the sending record module for the first time providing the passed file parameters and the adjusted<br />

BLOCK= size.<br />

2. On successful return from the sending record module, the file will have been opened. Also returned by<br />

the record module is the maximum logical record length that will be encountered in the file. The block<br />

module will add the record header length to the maximum and return the value to the SND module. At<br />

this point, the block module returns to the control module.<br />

3. On the next entry to the block module, a buffer will be passed that is to be filled by the block module.<br />

The block module will insert block protocol information based on the file MODE and repeatedly call the<br />

record module until the remaining space in the block is too small to accommodate the maximum record<br />

size first declared by the record module. Record protocol information is added based on the negotiated<br />

LCM and the file MODE.<br />

MAN-REF-H211-05 Appendix B: BFX Internal Summary Page 87

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!