-- AddressTranslation.mesa (last edited by: AOF on: September 10, 1980 9:32 AM)(2048)\i3bI18Bi

DIRECTORY
NSAddress USING [NetworkAddress, NetworkNumber];

AddressTranslation: DEFINITIONS =
BEGIN

-- interface

-- All numbers are in octal.
-- <network address> ::= <net>#<host>#<socket>
-- <system element> ::= <net>#<host>#
-- <network number> ::= <net>.
-- <net> ::= {a 32 bit number, soon to be 48 bits} | <empty>
-- <host> ::= <broadcast> | <Dmachine> | <alto> | <ether1>
-- <broadcast> ::= *
-- <Dmachine> ::= {48 bit processor ID}
-- <alto> ::= a{8 bit number representing the ether address}
-- <ether1> ::= e{8 bit number requiring 48 bit translation service}
-- <socket> ::= {16 bit number}

NSAddressElement: TYPE = NSAddress.NetworkAddress;
NetworkAddress: TYPE = NSAddress.NetworkAddress;

StringToNetworkAddress: PROCEDURE [STRING]
RETURNS [NetworkAddress];
StringToNSAddressElement: PROCEDURE [STRING]
RETURNS [NSAddressElement];
StringToNetworkNumber: PROCEDURE [STRING]
RETURNS [NSAddress.NetworkNumber];

BadSyntax: ERROR [field: Field];
Field: TYPE = {net, host, socket};

AppendNetworkAddress: PROCEDURE
[s: STRING, nA: NetworkAddress];
AppendNSAddressElement: PROCEDURE
[s: STRING, sE: NSAddressElement];
AppendNetworkNumber: PROCEDURE
[s: STRING, net: NSAddress.NetworkNumber];
AppendMyNetworkNumber: PROCEDURE [STRING]; -- primary network
AppendMyHostNumber: PROCEDURE [STRING];

StringOverflow: ERROR; -- error generated by the above procedures.

END. -- AddressTranslation\84b18B22i14I1bi29B459I93b22B53b21B52b21B66b10B59b21B51b20B49b19B65b21B21i19I1b18B23b14B8i44I6i4b18BI
LOGl4269d2999e12(635)\i
Time: May 9, 1980 11:56 AM By: Dalal Action: created file.l4269d2999e12\i
Time: June 9, 1980 1:22 PM By: AOF Action: Commented on definition of various fields of <network address>.l4269d2999\i
Time: July 29, 1980 12:10 PM By: AOF Action: SIGNALs => ERRORsl4269d2999\i
Time: August 21, 1980 2:37 PM By: AOF Action: Fix NSAddressElement and NetworkAddress so they are opaque.l4269d2999\i