M[UMPS] Commands

O[PEN]

Introduced in the 1977 ANSI M[UMPS] language standard.

Clarifications (no change intended) in a future ANSI M[UMPS] language standard:

When a device is currently "OPEN", and another OPEN command is issued by the process that "owns" the device, and in the later OPEN command the device parameters are different than in the original one, the system will behave as if the device is virtually CLOSEd and then re-OPENed with the new parameters. If the new parameters are incompatible with the device, error processing will occur "as usual".

Any keywords in the argument of the command are processed in strict left-to-right order. When multiple equivalent parameters are encountered, the last occurrence processed will define the action(s) to be taken.

For examples, see the examples with the USE command.

Additions in a future ANSI M[UMPS] language standard.

The ability to specify "user-defined" mnemonicspaces is added. It will be possible to specify to an implementation to use entries in a specific routine (let's call it USER for the purpose of this discussion) for the processing of the commands OPEN, USE and CLOSE and the various controlmnemonics for specific combinations of device and mnemonicspace.

When this feature is active, the controlmnemonic /ABC(P1,P2) will be executed as DO ABC^USER(P1,P2), and the command OPEN device:(PARAM1:KEY2=VALUE2) will be executed as:

DO
. NEW X,Y
. SET (X,Y)=2 ; Number of deviceparameters
. SET X(1)="PARAM1" ; First deviceparameter
. SET X(2)="KEY2",Y(2)=VALUE2
. DO %OPEN^USER(device,.X,.Y,"")
. QUIT
The name of a device may contain an environment specification
OPEN |"LONDON"|MTA47

The addition of a binding to TCP/IP socket devices includes a number of new deviceparameters.

The deviceparameters are: ATTACH, CONNECT, DELIMITER, IOERROR, LISTEN, DETACH and SOCKET. For examples, see the USE command.

For a program that parses a programming language, it is hard to see the difference between:
...:(abc=xyz):...
and
...:(FILENAME="C:\temp\ABC.TMP"):...
In the former example, the text between the parentheses should be an expression that happens to return a boolean value, whereas in the latter example, the text between the parentheses could be a "keyword equals value" combination that has a meaning in certain mnemonicspaces.

In order to make it easier to indicate this difference, the option to precede a devicekeyword with a slash has been introduced. This would make the latter example look like:
...:(/FILENAME="C:\temp\ABC.TMP"):...

Examples with naked references:

OPEN DEVICE
SET ^ABC(1,2)="reset naked indicator"
; Naked indicator is now ^ABC(1,
OPEN ^(3,4)

; Naked indicator is now: ^ABC(1,3,
; Actual reference is: ^ABC(1,3,4)

OPEN DEVICE:PARAMETERS
SET ^ABC(1,2)="reset naked indicator"
; Naked indicator is now ^ABC(1,
OPEN ^(3,4):^(5,6)

; 1. fetch ^(3,4) = ^ABC(1,3,4)
; 2. fetch ^(5,6) = ^ABC(1,3,5,6)
; Naked indicator is now: ^ABC(1,3,5,


This document is © Ed de Moel, 1995-2005.
It is part of a book by Ed de Moel that is published under the title "M[UMPS] by Example" (ISBN 0-918118-42-5).
Printed copies of the book are no longer available.

This document describes the various commands that are defined in the M[UMPS] language standard (ANSI X11.1, ISO 11756).

The information in this document is NOT authoritative and subject to be modified at any moment.
Please consult the appropriate (draft) language standard for an authoritative definition.

In this document, information is included that will appear in future standards.
The MDC cannot guarantee that these 'next' standards will indeed appear.