Copies into the currently-active workspace named items from a saved workspace. For example, to copy functions FRED and JOE from a workspace called MYWS in library 3, you would enter:
)COPY 3 MYWS FRED JOE SAVED 1991-06-13 23.24.06
If just the workspace name is used, the entire contents are copied:
)COPY MYWS SAVED 1991-06-13 23.28.17
If the name of an object to be copied matches the name of an object already in the active workspace, the copy will overwrite the object already in the workspace. See also )PCOPY Protected copy, )SCOPY Silent copy, )SPCOPY Silent protected copy). If a WORKSPACE FULL or SYMBOL TABLE FULL error is encountered, the active workspace is left unchanged. You should note that the )COPY operation works by temporarily )SAVEing the active workspace in the logical unit from which objects are being copied (or in a disc defined for temporary objects), extracting the required objects from the workspace identified in the )COPY command and then merging the active workspace and the objects to be copied. It is thus possible to see a DISC FULL message during a copy operation.
)COPY can be used to copy classes and objects from a saved workspace. However, some special considerations arise:
If you )COPY a list of classes and/or objects, or an entire workspace, APLX will first copy any top-level classes (classes with no parent), then classes of the first generation (children of top-level classes), and so on. It will then )COPY object instances and other items. This guarantees that no object properties or class hierarchy information is unnecessarily lost.
There are two different ways in which you can specify where APLX should look for the saved workspace:
See the description of the )LOAD system command for more detail on libraries and path names.
If one or more of the names following the )COPY command is enclosed in parentheses and is the name of a variable in the workspace to be copied from which is a simple character scalar, vector or matrix, then the contents of the variable are interpreted as the name or names of objects to be copied. The alternative forms of )COPY (i.e. )PCOPY, )SCOPY, and )SPCOPY) will also accept name arrays as part of the name list of the command.
(THIS THAT THE_OTHER)„›'DATA' NAMES„ŚBOX 'THIS THAT THE_OTHER' )WSID TEST WAS TEST )VARS NAMES THAT THE_OTHER THIS )SAVE 1991-06-13 19.14.26 TEST )CLEAR CLEAR WS )COPY TEST (NAMES) SAVED 1991-06-13 19.14.26 )VARS THAT THE_OTHER THIS