HPFOPEN
NM callable only.
Creates file objects and supports FIFO files.
Syntax
____________________________________________________
| |
| I32 I32 I32V * |
| HPFOPEN(filenum,status[,itemnum,item] [...]);|
____________________________________________________
NOTE Up to 41 itemnum/item pairs can be specified.
Parameters
filenum 32-bit signed integer by reference (required)
Returns a file descriptor for a FIFO file.
Can be used safely with all file system intrinsics
that require a 16-bit file number to be passed in
the intrinsic call (for example, FREAD, FWRITE,
FCLOSE).
status 32-bit signed integer by reference (optional)
Returns the status of the HPFOPEN call. If no
errors or warnings are encountered, status returns
32-bits of zero. If errors or warnings are
encountered, status is interpreted as two 16-bit
fields:
Bits (0:16) comprise status.info. A negative value
indicates an error condition, and a positive value
indicates a warning condition. Refer to the MPE/iX
Error Message Manual Volumes 1, 2 and 3
(32650-90066, 32650-90152, and 32650-90368) for a
description of its value.
Bits (16:16) comprise.status.subsys. The value
represents the subsystem that set the status
information. The subsystem identifier for HPFOPEN
is 143.
CAUTION If an error or warning is encountered and the status parameter
was not specified, HPFOPEN causes the calling process to abort.
itemnum 32-bit signed integer by value (optional)
Passes the item number. Refer to Table 4-20 .
item type varies by reference (optional)
Passes and/or returns the option indicated by the
corresponding itemnum parameter. Refer to Table
4-20 .
NOTE An itemnum takes precedence over any previously specified duplicate
itemnum. Any duplicated itemnum is flagged as a warning.
Table 4-20. HPFOPEN Itemnum/Item Values
-----------------------------------------------------------------------------------------------
| | | |
| Itemnum | Mnemonic | Item Description |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 0 | | End of option list: |
| | | |
| | | There is no corresponding item. The absence of an itemnum after the |
| | | last itemnum,item pair is equivalent to specifying this option. |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 2 | CA | Formal designator: |
| | | |
| | | Passes a formal file designator that is interpreted according to |
| | | MPE-escaped semantics (unless another syntax has been chosen via item |
| | | 41). The file name must be terminated by a nonalphanumeric character |
| | | other than a period (.), a slash (/), a hyphen (-), and an underscore |
| | | (_). Use of matched starting and ending name delimiters (a quoted |
| | | name) alleviates the need for a terminating character other than the |
| | | quote characters. |
| | | |
| | | The file referred to by formaldesig can be either an MPE file (i.e., |
| | | one that uses MPE syntax) or it can follow HFS syntax. If |
| | | formaldesig follows MPE syntax, the file name can include password, |
| | | group, and account specifications. The file name can backreference a |
| | | file equation and optionally be preceded by an asterisk. If |
| | | formaldesig follows HFS syntax, the file name must start with either |
| | | a dot (.) or a slash (/). |
| | | |
| | | The file referred to by formaldesig may reside either in an MPE group |
| | | or in an HFS directory. For files located in HFS directories, |
| | | traverse directory entries (TD) access is required to all directories |
| | | specified in formaldesig. If there is no TD access, HPFOPEN fails |
| | | and a value of -180 is returned in the status.info parameter. If you |
| | | are using HPFOPEN to create a file or hierarchical directory and you |
| | | lack of create directory entry (CD) access, status.info will return a |
| | | value of -179. |
| | | |
| | | If formaldesig is an escaped pathname: |
| | | |
| | | |
| | | * you cannot reference remote files |
| | | |
| | | * it cannot express a name equivalent to filename:envid |
| | | |
| | | * you cannot use the device parameter (device=node#) to specify |
| | | the remote location of a device |
| | | |
| | | If formaldesig is the name of a user-defined file, it can begin with |
| | | an asterisk (*). If formaldesig is the name of a system-defined |
| | | file, it can begin with a dollar sign ($). When creating a KSAM |
| | | file, formaldesig must be a unique file name, that is, one not |
| | | currently existing in the permanent file directory. |
| | | |
| | | The formal file designator can contain command interpreter variables |
| | | and expressions that are evaluated before formaldesig is parsed and |
| | | validated. |
| | | |
| | | As the default, HPFOPEN creates a nameless file that can be read or |
| | | written to, but not saved. (The domain option of a nameless file |
| | | must specify a new file unless it is a device file.) |
| | | |
-----------------------------------------------------------------------------------------------
Table 4-20. HPFOPEN Itemnum/Item Values (cont.)
-----------------------------------------------------------------------------------------------
| | | |
| Itemnum | Mnemonic | Item Description |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 2 cont'd | | The following are examples of valid formal file designators: |
| | | |
| | | &file/lock.group.account:node.dest.level& |
| | | &filename& |
| | | &!myfile& |
| | | &!afile/![FINFO("!afile",33)]& |
| | | |
| | | The following are examples of invalid formal file designators: |
| | | |
| | | "filename.group (missing delimiter (")) |
| | | file.group" ( 'f' is used as delimiter, missing at end) |
| | | |
| | | (ASC) It is recommended that this itemnum, item pair be used for |
| | | asynchronous devices. |
| | | |
| | | When you use HPFOPEN to open a file, you may use either itemnum=2 or |
| | | itemnum=51; you cannot use both. |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 3 | I32 | Domain: |
| | | |
| | | Passes a value indicating which file domain the system searches to |
| | | locate the file. A nameless disk file must always be a new file. |
| | | |
| | | A device file (such as a tape drive, terminal, spooled printer or hot |
| | | printer) always resides in the system file domain (permanent file |
| | | directory). Always specify a device file as old or permanent. |
| | | |
| | | The following values are valid: |
| | | |
| | | |
| | | 0 The file is a new temporary file. It is not placed in a |
| | | directory. |
| | | |
| | | 1 The file is a permanent file, found in the system file domain. |
| | | |
| | | 2 The file is a temporary file, found in the job file domain. |
| | | |
| | | 3 The file is an old (permanent or temporary) file. The job file |
| | | domain is searched first. If the file is not found, the system |
| | | file domain is searched. |
| | | |
| | | 4 The file is created, placed in the permanent file directory, and |
| | | becomes a permanent file. |
| | | |
| | | Hierarchical directories must be created in the permanent file domain |
| | | by specifying the create file domain (4). |
| | | |
| | | Default: 0 |
| | | |
-----------------------------------------------------------------------------------------------
Table 4-20. HPFOPEN Itemnum/Item Values (cont.)
-----------------------------------------------------------------------------------------------
| | | |
| Itemnum | Mnemonic | Item Description |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 5 | I32 | Designator: |
| | | |
| | | Passes a value indicating a special file opening. Any of the |
| | | following special files can be specified with the itemnum=2. For |
| | | example, a file name of $STDLIST opens the standard list device. The |
| | | following values are valid: |
| | | |
| | | |
| | | 0 Allows all other options to specify the file. |
| | | |
| | | 1 The actual file designator is $STDLIST. |
| | | |
| | | 2 The actual file designator is $NEWPASS. |
| | | |
| | | 3 The actual file designator is $OLDPASS. |
| | | |
| | | 4 The actual file designator is $STDIN. |
| | | |
| | | 5 The actual file designator is $STDINX. |
| | | |
| | | 6 The actual file designator is $NULL. |
| | | |
| | | Default: 0 |
| | | |
| | | For example, if MYFILE is passed in itemnum=2, then using itemnum=5 |
| | | and item=4 to equate it with $STDIN is equivalent to the file |
| | | equation FILE MYFILE=$STDIN. |
| | | |
| | | This option is not equated with itemnum=2 if both of the following |
| | | conditions are true: |
| | | |
| | | * The itemnum=9 option allows file equations for the file |
| | | opening. |
| | | |
| | | * An explicit or implicit FILE command equating the formal file |
| | | designator to a different actual file designator occurs in the |
| | | job/session. |
| | | |
| | | A leading * in a formal file designator passed by itemnum=2 overrides |
| | | an itemnum=9 option. |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 6 | I32 | Record format: |
| | | |
| | | Passes a value indicating the internal record structure desired for |
| | | the file. This option is applicable only at file creation. |
| | | |
| | | The following values are valid for records: |
| | | |
| | | |
| | | 0 Fixed-length |
| | | |
| | | 1 Variable-length |
| | | |
| | | 2 Undefined-length (no implied structure) |
| | | |
| | | 9 Byte stream |
| | | |
| | | 10 Hierarchical directory |
| | | |
| | | Default: 0 |
| | | |
-----------------------------------------------------------------------------------------------
Table 4-20. HPFOPEN Itemnum/Item Values (cont.)
-----------------------------------------------------------------------------------------------
| | | |
| Itemnum | Mnemonic | Item Description |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 6 cont'd | | Byte stream record format may be specified only for standard disk |
| | | files (itemnum 10 equal to 0). Hierarchical directory record format |
| | | is the the default record format when creatinng a directory (itemnum |
| | | 10 equal to 9). Itemnum 10 equal to 9 is the only record format |
| | | which may be specified when creating a directory. Hierarchical |
| | | record format is only specified for the directory file type. Record |
| | | formats not implemented for the specified file type are ignored. |
| | | Byte stream and hierarchical directory record formats are supported |
| | | only on disk devices. |
| | | |
| | | (ASC) This itemnum,item pair is ignored for files opened on a |
| | | terminal; records of files on terminals are of undefined length. If |
| | | the file is to be redirected to tape or disk, set the value to 0 |
| | | (fixed-length). |
| | | |
| | | FIFO file must be created with the byte streams (9) record format. |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 7 | I32 | Carriage-control: |
| | | |
| | | Passes a value indicating whether or not a carriage-control directive |
| | | is supplied in the calling sequence of each FWRITE call that writes |
| | | records onto the file. This option is applicable only at file |
| | | creation. |
| | | |
| | | The following values are valid: |
| | | |
| | | |
| | | 0 No carriage-control directive expected |
| | | |
| | | 1 Carriage-control directive expected |
| | | |
| | | Default: 0 |
| | | |
| | | Carriage-control is defined only for ASCII files. This option and |
| | | itemnum=53 are exclusive, and attempts to open new files with both |
| | | binary and carriage-control directives result in an access violation. |
| | | |
| | | |
| | | A carriage-control character passed through the control parameter of |
| | | FWRITE is recognized for files with carriage-control specified in |
| | | HPFOPEN/FOPEN. Embedded control characters are treated as data on |
| | | files where no carriage-control is specified, and spacing is not |
| | | invoked for the file. Specify spacing action on files where |
| | | carriage-control has been specified by either embedding the control |
| | | in the record, indicated with a control parameter in the call to |
| | | FWRITE, or by sending the control code directly through the control |
| | | parameter of FWRITE. |
| | | |
| | | If a carriage-control character is sent to a file where the control |
| | | cannot be executed directly (for example, line spacing characters |
| | | sent to a disk or tape file), the control character is embedded as |
| | | the first byte of the record. Therefore, the first byte of each |
| | | record in a disk file having carriage-control characters enabled |
| | | contains control information. If carriage-control characters are |
| | | sent to other types of files, the control is transmitted to the |
| | | driver. |
| | | |
| | | Control codes %400 through %403 are remapped to %100 through %103, so |
| | | that they fit into one byte and can be embedded. Records written to |
| | | the line printer with control codes %400 through %403 should contain |
| | | only control information. |
| | | |
| | | Records written with control codes %400 through %403 and no data |
| | | (count=0, or embedded control and count=1) does not cause physical |
| | | I/O. |
| | | |
-----------------------------------------------------------------------------------------------
Table 4-20. HPFOPEN Itemnum/Item Values (cont.)
-----------------------------------------------------------------------------------------------
| | | |
| Itemnum | Mnemonic | Item Description |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 7 cont'd | | For computing record size, the file system considers carriage-control |
| | | information as part of the data record. Therefore, specifying the |
| | | carriage-control option adds one byte to the record size when the |
| | | file is originally created. For example, a specification of |
| | | REC=-132,1,F,ASCII;CCTL results in a recsize of 133 bytes. |
| | | |
| | | Generally, the entire record can be read. Refer to the table listing |
| | | the item values returned by the FFILEINFO intrinsic. However, on |
| | | writes to files where carriage-control characters are specified, the |
| | | data transferred is limited to recsize-1 unless a control of one is |
| | | passed, indicating the data record is prefixed with embedded |
| | | carriage-control characters. |
| | | |
| | | The value of this itemnum is ignored when a byte stream or |
| | | hierarchical directory is created. Byte stream files and |
| | | hierarchical directories are created without carriage control |
| | | (NOCCTL). |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 8 | CA | Enable tape label: |
| | | |
| | | Passes the tape label name of a labeled tape. The name must follow |
| | | the ANSI standards for tape label names. The name consists of <=6 |
| | | printable characters that identify the volume. In a multivolume set, |
| | | only the first tape label can be specified. |
| | | |
| | | Default: a null tape label |
| | | |
| | | 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: |
| | | %volid% (% is the delimiter, volid is the designator) |
| | | fabcxyzf (f is the delimiter, abcxyz is the designator) |
| | | |
| | | (ASC) Not used for asynchronous devices. |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 9 | I32 | Disallow file equation: |
| | | |
| | | Passes a value indicating whether or not file equations are allowed. |
| | | A leading * in a formal file designator overrides the setting to |
| | | disallow file equations. |
| | | |
| | | The following values are valid: |
| | | |
| | | |
| | | 0 Allow file equations to override programmatic or system-defined |
| | | file specifications. |
| | | |
| | | 1 Disallow file equations from overriding programmatic or |
| | | system-defined file specifications. |
| | | |
| | | File equations can be enabled for escaped pathnames expressed using |
| | | MPE-escaped name semantics or names expressed using POSIX name |
| | | semantics, but a matching file equation is not found since the file |
| | | designator on the left side of a file equation can only be expressed |
| | | using MPE-only syntax. |
| | | |
| | | Default: 0 |
| | | |
-----------------------------------------------------------------------------------------------
Table 4-20. HPFOPEN Itemnum/Item Values (cont.)
-----------------------------------------------------------------------------------------------
| | | |
| Itemnum | Mnemonic | Item Description |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 10 | I32 | File type: |
| | | |
| | | Passes a value indicating the internal record structure used to |
| | | access records in the file. If the file is old, this option is |
| | | ignored. Specifying an itemnum=5 value other than zero overrides |
| | | this option. This option is applicable only at file creation. |
| | | |
| | | The following values are valid: |
| | | |
| | | |
| | | 0 Standard (STD) file |
| | | |
| | | 1 KSAM/3000 file |
| | | |
| | | 2 Relative I/O (RIO) file |
| | | |
| | | 3 KSAM XL file |
| | | |
| | | 5 NM spoolfile |
| | | |
| | | 4 Circular (CIR) file |
| | | |
| | | 6 Message (MSG) file |
| | | |
| | | 9 Directory |
| | | |
| | | Default: 0 |
| | | |
| | | Hierarchical directories must be created in the permanent file |
| | | domain. |
| | | |
| | | KSAM/3000 (1), RIO (2) and CIR (4) file types may only be created |
| | | using names belonging to the MPE name space. |
| | | |
| | | (ASC) Set the value to 0 for asynchronous devices. |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 11 | I32 | Access type: |
| | | |
| | | Passes a value indicating the type of access intended for the file. |
| | | This option restricts/allows usage of the file system intrinsics. |
| | | |
| | | The following values are valid: |
| | | |
| | | |
| | | 0 Read access only, if the file's security provisions allow read |
| | | access. FWRITE, FUPDATE, and FWRITEDIR intrinsic calls cannot |
| | | reference this file. The end-of-file (EOF) is not changed; the |
| | | record pointer starts at zero. (Default) |
| | | |
| | | 1 Write access only, if the file's security provisions allow write |
| | | access. Any data written in the file prior to the current |
| | | HPFOPEN request is deleted. FREAD, FREADSEEK, FUPDATE, and |
| | | FREADDIR intrinsic calls cannot reference this file. The EOF is |
| | | set to zero; the record pointer starts at zero. On magnetic |
| | | tape an EOF is written to the tape when the file is closed even |
| | | if no data is written. |
| | | |
| | | 2 Write-Save access only, if the file's security provisions allow |
| | | write access. Previous data in the file is not deleted. FREAD, |
| | | FREADSEEK, FUPDATE, and FREADDIR intrinsic calls cannot |
| | | reference this file. The EOF is not changed; the record pointer |
| | | starts at zero. Therefore, data is overwritten if FWRITE is |
| | | called. The system changes this value to append for message |
| | | files. |
| | | |
-----------------------------------------------------------------------------------------------
Table 4-20. HPFOPEN Itemnum/Item Values (cont.)
-----------------------------------------------------------------------------------------------
| | | |
| Itemnum | Mnemonic | Item Description |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 11 | | 3 Append access only, if the file's security |
| cont'd | | provisions allow either append or write access. |
| | | FREAD, FREADDIR, FREADSEEK, FUPDATE, FSPACE, |
| | | FPOINT, and FWRITEDIR intrinsic calls cannot |
| | | reference this file. The record pointer is set |
| | | to EOF prior to each FWRITE. For disk files, |
| | | the EOF is updated after each FWRITE call. |
| | | Therefore, data cannot be overwritten. |
| | | |
| | | 4 Read/Write (I/O) access only, if the file's |
| | | security provisions allow both read and write |
| | | access. If both read and write access are not |
| | | allowed, the access type is limited to that |
| | | specified in the security provisions (either |
| | | read or write). Any file intrinsic can be |
| | | issued except FUPDATE for this file. The EOF |
| | | is not changed; the record pointer starts at |
| | | zero. This option is not valid for message |
| | | files. |
| | | |
| | | 5 Update access only, if the file's security |
| | | provisions allow both read and write access. |
| | | If both read and write access are not allowed, |
| | | the access type is limited to that specified in |
| | | the security provisions (either read or write). |
| | | All file intrinsics can be issued, including |
| | | FUPDATE, for this file. The EOF is not |
| | | changed; the record pointer starts at zero. |
| | | This option is not valid for message files. |
| | | |
| | | 6 Execute access only, if the file's security |
| | | provisions allow execute access. This allows |
| | | read/write access to any loaded file. The |
| | | program must be running in privileged mode to |
| | | specify execute access. This option is not |
| | | valid for message files. |
| | | |
| | | 7 Execute-Read access only, if the file's |
| | | security provisions allow execute access. This |
| | | allows only read access to a loaded file. The |
| | | program must be running in PM to specify |
| | | execute-read access. This is changed to |
| | | execute access for KSAM, CIR, and RIO files. |
| | | Not valid for message files. |
| | | |
| | | 8 Reserved for MPE/iX. No access, opens the file |
| | | or directory without any access checking. A |
| | | process must be executing in system code to use |
| | | this access type. |
| | | |
| | | 9 Directory read access, opens a directory for |
| | | directory read access. Directories can only be |
| | | opened for no access or directory read access. |
| | | Files cannot be opened for directory read |
| | | access. |
| | | FIFO files should be opened for Read Access Only (0) or Write Access |
| | | Only (1). Other access types can cause unexpected results to occur. |
| | | |
-----------------------------------------------------------------------------------------------
Table 4-20. HPFOPEN Itemnum/Item Values (cont.)
-----------------------------------------------------------------------------------------------
| | | |
| Itemnum | Mnemonic | Item Description |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 12 | I32 | Dynamic locking: |
| | | |
| | | Passes a value enabling/disabling file locking for the file. When |
| | | specified, the FLOCK and FUNLOCK intrinsics can be used to |
| | | dynamically permit/restrict concurrent access to a disk file by other |
| | | processes at specified times. |
| | | |
| | | The following values are valid: |
| | | |
| | | |
| | | 0 Disallow dynamic locking/unlocking |
| | | |
| | | 1 Allow dynamic locking/unlocking |
| | | |
| | | Default: 0 |
| | | |
| | | The process can continue this temporary locking/unlocking until it |
| | | closes the file. If several accessors are sharing the file, they |
| | | must all specify, or not specify, this option. For example, if a |
| | | file is opened with the dynamic locking option enabled, and a |
| | | subsequent accessor tries to open the file with dynamic locking |
| | | disabled, that subsequent attempt to open fails. |
| | | |
| | | Dynamic locking/unlocking is possible through the equivalent of a |
| | | global resource identification number (RIN) assigned to the file and |
| | | temporarily acquired by HPFOPEN. |
| | | |
| | | Accessors that have opened a file with the dynamic locking option |
| | | enabled must access the file through the FLOCK and FUNLOCK intrinsics |
| | | to gain exclusive access to the file. Since the use of these |
| | | intrinsics is discretionary, however, all accessors must agree to use |
| | | FLOCK and FUNLOCK when writing to a file to guarantee exclusive |
| | | access. File locking is advised, but is not mandated by MPE/iX. |
| | | |
| | | Lock access must be at the account, group, and file levels for |
| | | HPFOPEN to grant this option. (Lock access is available if lock, |
| | | execute, append, or write access is set at these levels.) This |
| | | option is ignored for files not residing on disk. |
| | | |
| | | This itemnum may only be specified with the disallow dynamic locking |
| | | value (0) when used with directories. |
| | | |
| | | (ASC) Not used for asynchronous devices. |
| | | |
-----------------------------------------------------------------------------------------------
Table 4-20. HPFOPEN Itemnum/Item Values (cont.)
-----------------------------------------------------------------------------------------------
| | | |
| Itemnum | Mnemonic | Item Description |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 13 | I32 | Exclusive: |
| | | |
| | | Passes a value indicating continuous exclusive access to the file, |
| | | from open to close. Use this option when performing a critical |
| | | operation (for example, updating the file). |
| | | |
| | | The following values are valid: |
| | | |
| | | |
| | | 0 If itemnum=11 specifies read only access, read-share access |
| | | takes effect. Otherwise, exclusive access takes effect. |
| | | Regardless of which access option was selected, FFILEINFO |
| | | reports zero. A zero (default) value for the itemnum specifies |
| | | that if the access type is read, directory read, or no access |
| | | (itemnum 11 equal to 0, 8, or 9) then shared access takes |
| | | effect; otherwise exclusive access takes effect. |
| | | |
| | | 1 Exclusive access. After the file is opened, any additional |
| | | HPFOPEN/FOPEN requests for this file, whether issued by this |
| | | process or another process, are prohibited until this process |
| | | issues the FCLOSE request or terminates. If any process is |
| | | already accessing this file when an HPFOPEN/FOPEN call is issued |
| | | with exclusive access specified, an error status is returned to |
| | | the process. If another HPFOPEN/FOPEN call is issued for this |
| | | file while exclusive access is in effect, an error code is |
| | | returned to the process that issued that HPFOPEN/FOPEN call. |
| | | Request exclusive access only if the lock access mode is allowed |
| | | by the security provisions for the file. For message files, |
| | | specifying this value means that there can be only one reader |
| | | and one writer. |
| | | |
| | | Exclusive access cannot be used with directories. |
| | | |
| | | 2 Read-Share access (semi-exclusive access). After the file is |
| | | opened, concurrent write access to this file through another |
| | | HPFOPEN/FOPEN request is prohibited, whether issued by this |
| | | process or another process, until this process issues the FCLOSE |
| | | request or terminates. A subsequent request for the read/write |
| | | or update itemnum=11 obtains read access. However, other types |
| | | of read access are allowed. If a process already has write |
| | | access to the file when this HPFOPEN call is issued, an error |
| | | code is returned to the calling process. If another |
| | | HPFOPEN/FOPEN call that violates the read-only restriction is |
| | | issued while read-share access is in effect, that call fails and |
| | | an error code is returned to the calling process. You can |
| | | request read-share access only if you are allowed the lock |
| | | access mode by the security provisions for the file. For |
| | | message files, specifying this value means that there can be |
| | | multiple readers, but only one writer. |
| | | |
| | | 3 Share access. After the file is opened, this permits concurrent |
| | | access to this file by any process, in any access mode, subject |
| | | to other basic security provisions in effect. For message |
| | | files, specifying this value means that there can be multiple |
| | | writers and one reader. |
| | | |
| | | Default: 0 |
| | | |
| | | (ASC) This option is ignored for devices. |
| | | |
| | | FIFO files should be opened for Share Access (3). Other exclusive |
| | | accesses to file will cause unexpected results to occur. |
| | | |
-----------------------------------------------------------------------------------------------
Table 4-20. HPFOPEN Itemnum/Item Values (cont.)
-----------------------------------------------------------------------------------------------
| | | |
| Itemnum | Mnemonic | Item Description |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 14 | I32 | Multiaccess: |
| | | |
| | | Passes a value indicating how the file's record pointer is to be |
| | | shared. This option is useful for sharing standard input devices |
| | | where there is some natural sequence of access to the file. This |
| | | option permits processes located in different jobs or sessions to |
| | | open the same file and share that file's record pointer. |
| | | |
| | | The following values are valid: |
| | | |
| | | |
| | | 0 No multiple process access allowed. A unique record pointer is |
| | | created for this access to the file. For message files, the |
| | | file system sets the multiaccess option to 2 when a zero is |
| | | specified for this option. |
| | | |
| | | 1 Intrajob multiprocess access allowed. A record pointer is |
| | | shared with all other opened files of the same name in the same |
| | | job/session who opened the file with itemnum=14 is set to either |
| | | 1 or 2. |
| | | |
| | | 2 Interjob multiprocess access allowed. A record pointer is |
| | | shared with all other opened files of the same name on the |
| | | system. This is the same as specifying the GMULTI option in a |
| | | FILE command. |
| | | |
| | | Default: 0 |
| | | |
| | | Native byte stream access (see item 77) is opened regardless of the |
| | | value of this itemnum. This itemnum is also ignored for directories |
| | | since it is not applicable. |
| | | |
| | | (ASC) Not used for asynchronous devices. |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 15 | I32 | Multirecord: |
| | | |
| | | Passes a value indicating that individual read or write requests are |
| | | not confined to record boundaries. |
| | | |
| | | The following values are valid: |
| | | |
| | | |
| | | 0 Nonmultirecord mode (NOMULTI) |
| | | |
| | | 1 Multirecord mode (MULTI) |
| | | |
| | | Default: 0 |
| | | |
| | | If the number of half words or bytes to be transferred (specified in |
| | | the length parameter of the read or write request) exceeds the size |
| | | of the physical record (that is, a block) that is referenced, the |
| | | remaining half words or bytes are taken from subsequent successive |
| | | records until the number specified by length has been transferred. |
| | | For message (MSG) files not accessed with itemnum=17 enabled, the |
| | | file system sets this option to zero. This option is available only |
| | | if itemnum=46 is set to 1. |
| | | |
| | | (ASC) This option is not used for printers. |
| | | |
-----------------------------------------------------------------------------------------------
Table 4-20. HPFOPEN Itemnum/Item Values (cont.)
-----------------------------------------------------------------------------------------------
| | | |
| Itemnum | Mnemonic | Item Description |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 16 | I32 | Nowait I/O: |
| | | |
| | | Allows the accessor to initiate an I/O request and to have control |
| | | returned before the completion of the I/O. This option implies the |
| | | inhibit buffering option; if NOBUF is not specified, the file system |
| | | does it. Multirecord access is not available. This option is not |
| | | available if the file is located on a remote computer. When opening |
| | | nonmessage files, the process must be running in PM (execution level |
| | | 2) to specify this option. Set itemnum=29 to 3 if the file is to be |
| | | accessed while in user mode (execution level 3). |
| | | |
| | | The following values are valid: |
| | | |
| | | |
| | | 0 Nowait I/O not in effect |
| | | |
| | | 1 Nowait I/O in effect |
| | | |
| | | Default: 0 |
| | | |
| | | Directories may not be opened using Nowait I/O (1). |
| | | |
-----------------------------------------------------------------------------------------------
| | | |
| 17 | I32 | Copy mode: |
| | | |
| | | Passes a value that determines if any file should be treated as a |
| | | standard sequential file so it can be copied by logical record or |
| | | physical block to another file. |
| | | |
| | | Byte stream files and directories are accessed using normal access |
| | | (0) regardless of the value specified for this itemnum. |
| | | |
| | | The following values are valid: |
| | | |
| | | |
| | | 0 The file is accessed as its own file type (for example, a |
| | | message file is treated as a message file). |
| | | |
| | | 1 The file is to be treated as a standard (STD) file with |
| | | variable-length records. For message files, this allows |
| | | nondestructive reading of an old message file at either the |
| | | logical record or physical block record level. Only block-level |
| | | access is permitted if the file is opened with write access. |
| | | This prevents incorrectly formatted data from being written to |
| | | the message file while it is unprotected. To access a message |
| | | file in copy mode, a process must have exclusive access to the |
| | | file. |
| | | |
| | | (KSAM) Not allowed for KSAM XL files. |
| | | |
| | | Default: 0 |
| | | |
-----------------------------------------------------------------------------------------------