PreviousUpNext

14.4.32  Internet_Socket

The standard library Internet_Socket api defines access to TCP and UDP Internet Protocol sockets for multithreaded Mythryl programs.

The Internet_Socket api is implemented by the internet_socket package.

The Internet_Socket api source code is in src/lib/std/src/socket/internet-socket.api.

See also: Internet_Socket__Premicrothread package.

The above information is manually maintained and may contain errors.

api {
    Inet;
    Threadkit_Socket X = ?.proto_socket::Threadkit_Socket((Inet, X));
    Stream_Socket X = Threadkit_Socket(?.proto_socket__premicrothread::Stream(X ) );
    Datagram_Socket  = Threadkit_Socket(?.proto_socket__premicrothread::Datagram );
    Socket_Address  = ?.proto_socket__premicrothread::Socket_Address(Inet );
    inet_af : ?.proto_socket__premicrothread::af::Address_Family;
    to_address : (?.dns_host_lookupinternal::Internet_Address , Int) -> Socket_Address;
    from_address : Socket_Address -> (?.dns_host_lookupinternal::Internet_Address , Int);
    any : Int -> Socket_Address;
        package udp
          : api {
                make_socket : Void -> Datagram_Socket;
                make_socket' : Int -> Datagram_Socket;};;
        package tcp
          : api {
                make_socket : Void -> Stream_Socket(X );
                make_socket' : Int -> Stream_Socket(X );
                get_nodelay : Stream_Socket(X ) -> Bool;
                set_nodelay : (Stream_Socket(X ) , Bool) -> Void;};;};


Comments and suggestions to: bugs@mythryl.org

PreviousUpNext