18.08.2013 Views

(SYSLIB) Programming Reference Manual - Public Support Login ...

(SYSLIB) Programming Reference Manual - Public Support Login ...

(SYSLIB) Programming Reference Manual - Public Support Login ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Section 13<br />

MFDSP$–Master File Directory Service<br />

Package<br />

MFDSP$ retrieves information about files from the master file directory (MFD). A copy<br />

of the MFD is needed before the MFDSP$ routine can be used. The MFD copy is<br />

produced by a call to ER MSCON$ (using the DGET$ or DGETP$ function). Once this<br />

copy of the MFD is in a mass storage file that is assigned to the calling program, the<br />

MFDSP$ routine can be used to retrieve the lead items, main items, and device area<br />

descriptor (DAD) tables of all the files in the MFD. A complete description of how the<br />

ER MSCON$ is used and what information is contained in lead items, main items, and<br />

DAD tables can be found in the Exec Installation and Configuration Guide.<br />

The copy of the MFD can also be obtained by initially calling MFDSP$ with function code<br />

10. MFDSP$ then does an ER MSCON$ DGET$ function to copy the MFD to a scratch<br />

file that MFDSP$ has assigned.<br />

The following subsections describe the packet needed by the MFDSP$ routine, as well<br />

as the MASM calling sequence.<br />

13.1. Packet<br />

The MFDSP$ routine requires that the calling program provide it with a packet. The first<br />

two words of the MFDSP$ packet must contain (in Fieldata LJSF) the internal file name<br />

of the file that holds the output from the ER MSCON$. This file must be assigned<br />

before the call to MFDSP$ can be made. Failure to have the file assigned results in an<br />

I/O error type 01, code 21, contingency 12.<br />

The MFDSP$ routine uses the remainder of the packet as scratch space. Since the<br />

routine does track-size double-buffered I/O, the packet must be large enough to hold two<br />

I/O packets, two track-size buffers, and additional space required by the MFDSP$ routine<br />

for its internal tables. In general, a packet of 4,400 words is an adequate starting size.<br />

Once the ER MSCON$ file is successfully initialized, the exact packet size required is<br />

returned in register A5. The packet length may have to be increased if a 02 error is<br />

returned.<br />

7833 1733–004 13–1

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

Saved successfully!

Ooh no, something went wrong!