LIB-ITEM ::= ... | DOWNLOAD-ITEMS DOWNLOAD-ITEMS ::= download-items LIB-NAME ITEM-NAME-OR-MAP+ ITEM-NAME-OR-MAP ::= ITEM-NAME | ITEM-NAME-MAP ITEM-NAME-MAP ::= item-name-map ITEM-NAME ITEM-NAME ITEM-NAME ::= SIMPLE-ID
The syntax of local libraries is here extended with a further sort of library item, for use with distributed libraries. The DOWNLOAD-ITEMS construct is written:
from LN get IN1 |-> IN'1,..., INn |-> IN'n endwhere the terminating `end' keyword is optional. A map `INn |-> INn' may be simply written `INn'.
It specifies which definitions to copy from the remote library named LN, changing the remote names INi to the local names IN'i.
The semantics corresponds to having already replaced all references in the downloaded definitions by the corresponding (closed) specifications; cyclic chains of references via remote libraries are not allowed. The download items show exactly which specification names are added to the current global environment of the library in which they occur, allowing references to named specifications to be checked locally (although not whether the kind of specification to be downloaded from the remote library is consistent with its local use).
When the library name LN does not include a version number, the version with the largest version number is taken. (This need not be the latest installed version, due to the lexicographic ordering on version identifiers.)
[CHANGED:] A direct link to another library is simply written as its URL.
The location of a library is always a directory, giving access not
only to the individual specifications defined by the current
version of the library but also to archived versions, various
indexes, and other documentation. An indirect link is written:
An indirect link is interpreted as a URL by the current global library
directory.
[]
LIB-ID ::= DIRECT-LINK | INDIRECT-LINK
DIRECT-LINK ::= direct-link URL
INDIRECT-LINK ::= indirect-link PATH
FI1/.../FIn
where each file identifier FIi is a valid file name as if for
use in a URL.