PreviousUpNext

15.4.1214  src/lib/std/src/socket/unix-domain-socket.pkg

## unix-domain-socket.pkg

# Compiled by:
#     src/lib/std/standard.lib



###                  "Things hard to come by are much esteemed."
###
###                                       -- Latin Proverb 


stipulate
    package tps =  plain_socket;                                        # plain_socket                          is from   src/lib/std/src/socket/plain-socket.pkg
    package ts  =  socket;                                              # socket                                is from   src/lib/std/src/socket/socket.pkg
    package tss =  socket::typ;
    package uds =  unix_domain_socket__premicrothread;                  # unix_domain_socket__premicrothread    is from   src/lib/std/src/socket/unix-domain-socket--premicrothread.pkg
herein

    package   unix_domain_socket
    : (weak)  Unix_Domain_Socket                                        # Unix_Domain_Socket                    is from   src/lib/std/src/socket/unix-domain-socket.api
    {
        Unix = uds::Unix;

        Unix_Domain_Socket_Address =  ts::Socket_Address( Unix );
        Threadkit_Socket(X)        =  ts::Threadkit_Socket( Unix, X );

        Stream_Socket(X) = Threadkit_Socket( ts::Stream(X) );
        Datagram_Socket  = Threadkit_Socket( ts::Datagram );


        unix_address_family = uds::unix_address_family;
        #
        string_to_unix_domain_socket_address =   uds::string_to_unix_domain_socket_address;
        unix_domain_socket_address_to_string =   uds::unix_domain_socket_address_to_string;

        package stream {
            #
            fun make_socket ()          = tps::make_socket       (unix_address_family, tss::stream);
            fun make_socket' proto      = tps::make_socket'      (unix_address_family, tss::stream, proto);             # NOT EXPORTED BY API -- is this a bug?  XXX QUERO FIXME
            fun make_socket_pair ()     = tps::make_socket_pair  (unix_address_family, tss::stream);
            fun make_socket_pair' proto = tps::make_socket_pair' (unix_address_family, tss::stream, proto);             # NOT EXPORTED BY API -- is this a bug?  XXX QUERO FIXME
        };

        package datagram {
            #
            fun make_socket ()          = tps::make_socket       (unix_address_family, tss::datagram);
            fun make_socket' proto      = tps::make_socket'      (unix_address_family, tss::datagram, proto);           # NOT EXPORTED BY API -- is this a bug?  XXX QUERO FIXME
            fun make_socket_pair ()     = tps::make_socket_pair  (unix_address_family, tss::datagram);
            fun make_socket_pair' proto = tps::make_socket_pair' (unix_address_family, tss::datagram, proto);           # NOT EXPORTED BY API -- is this a bug?  XXX QUERO FIXME
        };
    };
end;

## COPYRIGHT (c) 1996 AT&T Research.
## Subsequent changes by Jeff Prothero Copyright (c) 2010-2015,
## released per terms of SMLNJ-COPYRIGHT.


Comments and suggestions to: bugs@mythryl.org

PreviousUpNext