Accessing Files Programmer's Guide (32650-90885)

Chapter 2 39
Creating A File
The HPFOPEN Intrinsic
itemnum
52 or system-defined file references specified through
itemnum
5.
42/CA Device class:
Passes a device class where the file resides. The file system uses the device
class name to select a nonshareable device from a configured list of
available devices. The name can have a length of up to eight alphanumeric
characters, beginning with a letter (for example, TAPE). If a device class is
specified, the file is allocated to any available device in that class.
Only one of the following options can be in effect when a file is opened:
itemnum
=20
itemnum
=22
itemnum
=23
itemnum
=42
Default: A disk file located on the volume class DISC associated with the
group in which file resides.
A character placed in the first element designates the delimiter used by
HPFOPEN to search for the end of the character array. The delimiter can
appear again only following the last valid character of the character array,
for example:
%devclass%
(% is the delimiter,
devclass
is the designator)
fabcxyzf
(
f
is the delimiter,
abcxyz
is the designator)
This
itemnum
may not be specified when creating hierarchical directories.
Hierarchical directories created on the system volume set is allocated on
any volume within the set. Hierarchical directories created on non-system
volume sets is allocated on the master volume.
43/record UFID:
Passes a unique file identifier (UFID) to provide a fast opening of an old
disk file. A UFID is a record structure, 20 bytes in length, that uniquely
identifies a disk file. Using this option avoids a directory search. Obtain
the UFID of an opened file by calling FFILEINFO. The UFID can then be
passed to HPFOPEN. The file represented by the UFID must be accessible to
the process calling HPFOPEN. (All file system security checks are made.)
New files cannot be opened with this option. If the file to be opened by the
UFID contains a lockword, use
itemnum
=2 to specify the file name with the
lockword.
Only files in the MPE name space may be opened by UFID. An attempt to
open a file outside the MPE name space by UFID results in a
status.info
of -321 being returned. Only system code may open a file by UFID in the
POSIX name space.
Default: No UFID passed (a directory search is performed)
(ASC) Not used for asynchronous devices.