• Aucun résultat trouvé

E SOURCE OBJECT

Dans le document Reference Manual (Page 66-74)

OBJECT L $

~1<file title>-- TO [ I <new file name> I

<directory title>-- TO$

~

I <new directory

name>~

$-1

< new directory name>

--<di rectory . name>'---~---l

<change from group>

< change from files>

E

SOURCE OBJECT

~1<fil e name>--

TaL

$ ] <new fil e name>

<di rectory name>- TO [ $ ] <new di rectory name>J

Explanation

The TITLE and CHANGE commands are synonyms~ They change the name (the value of the FILENAME attribute) of the work file or of files or directories. The only difference between the TITLE and CHANGE commands is that the keyword TO in the < change files> and < change from files> constructs is optional for the TITLE command, but required for the CHANGE command.

8600 1500-000

CHANGE

Command (cant.)

If the <new file name> or the associated object file already exists, then the file name or file title specified is not changed. Also, any file names in the directory name or directory title specified that already exist in the < new directory name>, or any object files associated with file names that already exist in the object directory associated with the new directory name are not changed.

If < family name> is specified, the command applies only to the file name or directory name on the volume associated with family name. For example, CHANGE FILEX ON DISK TO FILEZ affects only files found on DISK even though the family specification for the session is FAMILY DISK = USERP ACK OTHERWISE OTHERP ACK. Refer to

"Family Substitution" in Section 1, "General Information" for more information.

If < family name> is not specified, the command applies to the file name or directory name found on DISK. If DISK is also the < target family> in the family specification for the session, then the only files affected by the command are those on the < substitute family>. Files on the < alternate family> are not affected. (Refer to "Family Substitution" in Section 1, "General Information" for more information.)

In a < change from group> construct, a FROM < family name> clause applies to all the file names or directory names in that < change from group>. An ON < family name> clause In the < file title> or < directory title> constructs applies only to the immediately preceding file name. An ON clause cannot precede a FROM clause in the same command.

When specifying a file name, file title, or directory name, a user logged on under a nonprivileged usercode cannot enter a usercode specification other than the usercode for the current session.

If SOURCE or OBJECT is used as a file name, then it must be enclosed in quotation marks to prevent ambiguity with the keywords SOURCE and OBJECT.

If the CHANGE command is used to change the name of a file whose LOCKEDFILE file attribute is set to TRUE, the file name is not changed. CANDE displays the following message to indicate that the file name was not changed:

<file name> NOT CHANGED (LOCKEDFILE).

For more information about the LOCKEDFILE file attribute, refer to the File Attributes Reference Manual. See the ALTER command earlier in this section for information about changing the LOCKEDFILE attribute.

The folloWing paragraphs contain an explanation for each syntactic variation of the CHANGE command.

CHANGE <new file name>

CHANGE TO <new file name>

CHANGE <new file name> and CHANGE TO <new file name> change the name of the current work file to a new file name. Additionally, if a workobject file exists, its name is changed to become the object file associated with the new file name. If no work file exists, the command is rejected with an error message. Neither a usercode nor an asterisk (*) is allowed in the new file name.

CHANGE Command (cont.)

3-14

CHANGE <file title> TO <new file name>

CHANGE SOURCE <file title> TO <new file name>

CHANGE < file title> TO < new file name> changes the name of the file specified by the file title to a new file name. Additionally, if the associated object file exists, its name is changed to the object file name associated with the new file name. If SOURCE is specified, the name of the file specified by the file title is changed to a new file name; any object file associated with the file title is not affected. The dollar sign ($) in front of a new file name is not allowed.

CHANGE <directory title> TO <new directory name>

CHANGE SOURCE <directory title> TO <new directory name>

CHANGE < directory title> TO < new directory name> changes the names of the files in the directory specified by the directory title to the appropriate file names in the new directory name. The command also changes the names of the files in the associated object directory to the object file names associated with new directory name.

If SOURCE is specified, the names of the files in the directory specified by the directory title are changed but the associated object directory is not affected. The dollar sign ($) in front of a new directory name is not allowed.

CHANGE ,OBJECT <file title> TO <new file name>

CHANGE OBJECT <file title> TO $ <new file name>

CHANGE OBJECT $ <file title> TO <new file name>

CHANGE OBJECT $ <file title> TO $ <new file name>

CHANGE OBJECT < file title> TO < new file name> changes the name of the object file associated with a file title to the name of the object file associated with the new file name. The dollar sign ($) can precede either the file title, or the new file name, or both.

For the file title, the dollar sign indicates that the file is not stored with the associated object file name but is stored as a file title. For the new file name, the dollar sign indicates that the changed file receives a new file name as its name instead of the object file name associated with the new file name.

CHANGE OBJECT <directory title> TO <new directory name>

CHANGE OBJECT <directory title> TO $ <new directory name>

CHANGE OBJECT $ <directory title> TO <new directory name>

CHANGE OBJECT $ <directory title> TO $ <new directory name>

CHANGE OBJECT < directory title> TO < new directory name> changes the names of the rues in the object directory associated with the directory title to the appropriate file names in the object directory associated with the new directory name. The dollar sign ($) can precede either the directory title, or the new directory name, or both.

For the directory title, the dollar sign indicates that the directory is not stored as the associated object directory name but is stored as a directory title. For the new directory name, the dollar sign indicates that the files in the changed directory receive a new directory name as their directory name instead of the object directory name associated with the new directory name.

8600 1500-010

CHANGE Command (cont.)

Examples

The following example renames the work file from A to B:

WHAT

HWORKFILE A: ALGOL TITLE B

H

WHAT

HWORKFI LE B: ALGOL

The following example renames the source file A to B and the object file OBJECT/A to OBJECT/B:

TITLE A B

H(UZER)A ON USERPACK

(&

OBJECT) CHANGED TO (UZER)B

The following example renames the source file A, the source file B, and the object file OBJECT/B to AI, BI, and OBJECT/BI, respectively. All files reside on the family OTHERPACK.

CHANGE SOURCE A TO AI, B TO B1 FROM OTHERPACK H(UZER)A ON OTHERPACK CHANGED TO (UZER)A1

H(UZER)B ON OTHERPACK

(&

OBJECT) CHANGED TO (UZER)BI

The following example renames the file A to B on the family USERP ACK:

CHANGE A ON USERPACK TO B

H(UZER)A ON USERPACK CHANGED TO (UZER)B

The following example renames the object file associated with the file TEST (named OBJECTtrEST) to TEST:

CHAN OBJECT TEST TO $TEST

H(UZER)OBJECT/TEST ON USERPACK CHANGED TO (UZER)TEST

The following example renames the object file TESTONLY (which is not stored under the object directory) to OBJECTtrESTONLY:

CHAN OBJECT $TESTONLY TO TESTONLY

#(UZER)TESTONLY ON USERPACK CHANGED TO (UZER)OBJECT/TESTONLY

CHANGE Command (cont.)

3-16

The following example renames the files of the directory PROGRAMLIB and its associated object directory:

TITLE PROGRAMLIB/= LIB/=

#2 FILES IN (UlER)PROGRAMLIB/= CHANGED TO (UlER)LIB/= ON USERPACK

#1 FILE IN (UlER)OBJECT/PROGRAMLIB/= CHANGED TO (UlER)OBJECT/LIB/=

ON USERPACK

CHARGE Command

CHARGE

Syntax

- CHARGE -.---.---~

~<chargecode>~

< chargecode >

- < n a m e > - - - /

Explanation

"The CHARGE command specifies a new chargecode at some point in a session.

When CHARGE is entered, the chargecode reverts to a null chargecode specification unless USEDEFAULTCHARGE and CHARGEREQ, or just CHARGEREQ, are SET in the USERDATAFILE entry for that usercode. If both USEDEFAULTCHARGE and CHARGEREQ are SET, transmitting CHARGE causes the chargecode to revert to the default chargecode. If CHARGEREQ (but not USEDEFAULTCHARGE) is SET in the USERDATAFILE for the current usercode, and CHARGE is entered, an error message is given.

When CHARGE < chargecode > is entered, the chargecode changes to the specified

<chargecode>. IfCHARGEREQ is SET in the USERDATAFILE, <chargecode>

must be validated in the USERDATAFILE. If CHARGEREQ is not SET, any chargecode can be entered; validation in the USERDATAFILE is not necessary. Specifying a new chargecode provides a breakdown of system usage statistics incurred under the previous chargecode. When a new chargecode is entered, the system usage statistics for the session are set to zero as if the previous session had terminated and a new one had begun.

For more information on chargecodes, refer to "User Identification and Logging On"

in Section 1, "General Information." Refer to the Security Administration Guide for further information on the USERDATAFILE.

Examples charge

#SESSION 3601 ET=9.0 PT=0.0 10=0.0

#CONTINUE SESSION 3601 14:08:03 4/20/78 CHAR ME

#SESSION 3601 ET=7:47.2 PT=55.8 10=57.1

#CONTINUE SESSION 3601 14:15:50 04/20/78 CHAR 12345678901234567

#SESSION 3601 ET=5:08.9 pt=0.5 10=0.2

#CONTINUE SESSION 3601 14:20:59 04/20/78

COMPILE Command

/1\-<source file title>---r-...L-..J /1 \- AS [ $ ] <object fil e name>

-/1\1<standard compiler> ~

WITH -<compiler name>

L-

ON -<family name>.J

< code file task attribute>

FILE -<internal f

The COMPILE command invokes a compiler to compile a program, and if there are no syntax errors in the program, the result is an object program.

8600 1500-010

COMPILE Command (cont.)

Specifying a file to be compiled

You can specify the title of the source file that is to ,be compiled; however, if a source-file title is not specified, the work file is assumed. If the file to be compiled is the work file, an UPDATE operation is performed before the compiler is invoked. The following examples show a COMPILE command that specifies a source-file title, and a COMPILE command that assumes the work file, respectively:

COMPILE MY/ALGOL/PROGRAM COMPILE

If a source-file title is specified, the reSUlting object program is titled OBJECT/ < source file title>. If the work file is specified or assumed and the work file is saved before it is compiled, then the object program is titled OBJECT/ < work file title>. If an object file name other than the source-file title is desired, then the following COMPILE syntax should be used:

COMPILE <source file title> AS OUR/ALGOL/PROGRAM

If an object file name other than the work file title is desired, then either of the following COMPILE statements can be used, resulting in an object program titled OBJECT/OUR/ ALGOL/PROGRAM:

COMPILE <work file title> AS OUR/ALGOL/PROGRAM COMPILE AS OUR/ALGOL/PROGRAM

If a dollar sign ($) precedes the object file name, the OBJECT directory is omitted. An asterisk (*) or usercode is not permitted with an object file name.

Specifying a compiler

A particular compiler can be specified to compile a source file or work file; however, if a compiler is not specified, the compiler appropriate for the source-file type is invoked.

For example, the ALGOL compiler is invoked for type ALGOL files. The following are examples of the COMPILE command with a compiler name specified:

COMPILE MY/ALGOL/PROGRAM ALGOL

COMPILE HIS/COBOL74/PROGRAM C74 ON PACK

If a compiler is not specified and the type of the source file or work file is not a compiler type (such as SEQ or DATA), CANDE displays one of the following messages:

#SOURCE NOT COMPILER TYPE

#WORKFILE NOT COMPILER TYPE

Nonstandard compilers (such as BDMSCOBOL and BDMSALGOL) can be invoked by using the WITH construct.

COMPILE Command (cont.)

3-20

Because the prefix SYSTEM/ is assumed to precede the first node of the compiler title after any usercode or asterisk (*), the prefix SYSTEM/ should not be explicitly specified.

The compiler title has the same form as a file title, except that the maximum number of nodes is 11. For example, the following command uses SYSTEM/ALGOL compiler:

Dans le document Reference Manual (Page 66-74)