This is adasockets.info, produced by makeinfo version 4.6 from ./adasockets.texi. START-INFO-DIR-ENTRY * adasockets: (adasockets). AdaSockets reference manual END-INFO-DIR-ENTRY Copyright (C) 2002-2004 Samuel Tardieu Permission is granted to make and distribute verbatim copies of this manual provided the copyright notice and this permission notice are preserved on all copies. Permission is granted to copy and distribute modified versions of this manual under the conditions for verbatim copying, provided also that the entire resulting derived work is distributed under the terms of a permission notice identical to this one. Permission is granted to copy and distribute translations of this manual into another language, under the above conditions for modified versions.  File: adasockets.info, Node: Top, Next: What is AdaSockets?, Prev: (dir), Up: (dir) * Menu: * What is AdaSockets?:: * Installing AdaSockets:: * Using AdaSockets:: * Sockets package:: * Sockets.Multicast package:: * Sockets.Naming package:: * Contributors:: * Resources on the Internet:: * Index:: --- The Detailed Node Listing --- Using AdaSockets * Compiling an Ada application:: * Setting up unicast sockets:: * Setting up multicast sockets:: * Sending and receiving data:: Sending and receiving data * Raw data manipulation:: * String-oriented exchanges::  File: adasockets.info, Node: What is AdaSockets?, Next: Installing AdaSockets, Prev: Top, Up: Top What is AdaSockets? ******************* AdaSockets is a set of free software Ada packages allowing Ada programmers to use the so-called BSD sockets from their favourite programming language. AdaSockets has been designed and tested with the GNAT free software Ada compiler, but should be portable to other compilers quite easily. Starting from release 3.14, the GNAT compiler started to integrate a `GNAT.Sockets' package. However, this package is GNAT specific and contains at this time less features than AdaSockets. At some point, AdaSockets may use `GNAT.Sockets' as its underlying sockets structure. AdaSockets philosophy is to help the Ada programmer by providing easy-to-use objects. Special care has been taken to ensure that performances do however remain good.  File: adasockets.info, Node: Installing AdaSockets, Next: Using AdaSockets, Prev: What is AdaSockets?, Up: Top Installing AdaSockets ********************* Installing AdaSockets on a Unix or OpenVMS machine is as simple as typing a few commands. Once you got the latest version of AdaSockets (*note Resources on the Internet::), uncompress and untar it and go to the top-level directory of the distribution. You must configure the AdaSockets distribution by using the `configure' command, such as in: ./configure --prefix=/users/sam/adasockets If you want to install AdaSockets under the `/usr/local' hierarchy, you do not need to specify the `--prefix' option. Make sure you have write permission on the target directories. Once AdaSockets is configured, you can compile and install it by using the `make' command: make install The GNU make program is recommended but not mandatory. On your system, it may be installed under the `gmake' name.  File: adasockets.info, Node: Using AdaSockets, Next: Sockets package, Prev: Installing AdaSockets, Up: Top Using AdaSockets **************** * Menu: * Compiling an Ada application:: * Setting up unicast sockets:: * Setting up multicast sockets:: * Sending and receiving data::  File: adasockets.info, Node: Compiling an Ada application, Next: Setting up unicast sockets, Prev: Using AdaSockets, Up: Using AdaSockets Compiling an Ada application ============================ AdaSockets comes with an `adasockets-config' application that can be used to retrieve installation parameters while using `gnatmake' to compile your Ada application. The `--cflags' parameters tells `adasockets-config' to output the path to the Ada packages sources, while `--libs' asks for the path to the Ada library. gnatmake `adasockets-config --cflags` mainprog -largs `adasockets-config --libs`  File: adasockets.info, Node: Setting up unicast sockets, Next: Setting up multicast sockets, Prev: Compiling an Ada application, Up: Using AdaSockets Setting up unicast sockets ========================== Unicast sockets are used everywhere on the Internet, for surfing the web, sending electronic mails or accessing remote files. They come in two flavours: TCP TCP is a connected mode, in which packets are sent in a reliable and ordered way. Everything sent at one end will eventually arrive in the same order at the other end, the underlying operating system takes care of retransmitting missing packets and reordering out-of-order ones. UDP UDP is a non-connected mode. A packet sent on a UDP socket may or may not arrive at the other end. This is a much lighter protocol when reliability is not needed as the operating system does not have to use large buffers to reorder packets. Also, this generates less traffic as no acknowledgments need to be sent by the kernels. The package `Sockets' defines a `Socket_FD' tagged type. An instance of this type (or of any of its descendants) represents an incoming or outgoing socket. Two different kinds of sockets can be created: unicast (one-to-one) and multicast (many-to-many).  File: adasockets.info, Node: Setting up multicast sockets, Next: Sending and receiving data, Prev: Setting up unicast sockets, Up: Using AdaSockets Setting up multicast sockets ============================ Multicast sockets are used for group communication over the Internet. To use multicast sockets, you must be connected to a multicast network and use a multicast-enabled operating system (such as most Unices, Linux or even recent Windows versions). Unless you are connected to the mbone (multicast backbone) or have setup a private multicast network, you will only be able to use multicast on your local network. A multicast socket is somewhat similar to a UDP socket; in particular, packets may be lost or misordered. You can create a multicast socket using the function `Create_Multicast_Socket' in the package `Sockets.Multicast'. This function returns a `Multicast_Socket_FD' object, which derives from `Socket_FD'. `Create_Multicast_Socket' takes care of the whole setup of your multicast socket. You do not need to call any additionnal subprogram before using it. In particular, `Create_Multicast_Socket' will take care of registering the multicast socket to the operating system, so that the latter can tell the connected routers to propagate the subscription to the mbone as needed.  File: adasockets.info, Node: Sending and receiving data, Prev: Setting up multicast sockets, Up: Using AdaSockets Sending and receiving data ========================== In AdaSockets, data can be sent and received in three different ways: raw, string-oriented and stream-oriented. * Menu: * Raw data manipulation:: * String-oriented exchanges::  File: adasockets.info, Node: Raw data manipulation, Next: String-oriented exchanges, Prev: Sending and receiving data, Up: Sending and receiving data Raw data manipulation --------------------- Raw data is manipulated using the predefined `Ada.Streams.Stream_Element_Array' Ada type. This corresponds to an array of bytes, or an `unsigned char *' in the C programming language.  File: adasockets.info, Node: String-oriented exchanges, Prev: Raw data manipulation, Up: Sending and receiving data String-oriented exchanges ------------------------- String-oriented exchanges provides the programmer with `Ada.Text_IO' like subprograms. Most Internet protocols are line-oriented and those subprograms are perfectly suited to implement those. When sending data, the classical `CR + LF' sequence will be sent at the end of each line. When receiving data, `CR' characters are discarded and `LF' is used as the end-of-line marker. The `Get' function is tied to the size of the operating system buffer. It is better to use `Get_Line' to get a full line. The line can be as long as the length of the Ada buffer. The Ada buffer can be adjusted by using the `Set_Buffer' and `Unset_Buffer' procedures. When using string-oriented exchanges with datagram protocols such as UDP, setting a buffer using `Set_Buffer' for the receiving socket is mandatory. If you don't, the receiving socket will loose data and will be unable to reconstitute the string.  File: adasockets.info, Node: Sockets package, Next: Sockets.Multicast package, Prev: Using AdaSockets, Up: Top Sockets package *************** The `Sockets' package contains all the definitions and subprograms needed to build a simple unicast client or server. - Sockets.Socket_FD: type Socket_FD is tagged private; The `Socket_FD' tagged type is the root type of all sockets. It gets initialized by calling *Note Socket (procedure)::. * Menu: * Accept_Socket (procedure):: Accept an incoming connection * Bind (procedure):: Associate a local port to a socket * Connect (procedure):: Connect a socket on a given host/port * Get (function):: Get a string from a remote host * Get_Char (function):: Get a character from a remote host * Get_Line (procedure):: Get a whole line from a remote host * Get_Line (function):: Get a whole line from a remote host * Getsockopt (procedure):: Retrieve a socket option * Listen (procedure):: Establish a listen queue * New_Line (procedure):: Send a CR/LF to a remote host * Put (procedure):: Send a string to a remote host * Put_Line (procedure):: Send a CR/LF terminated string to a remote host * Receive (procedure):: Receive raw data over a socket * Receive (function):: Receive raw data over a socket * Receive_Some (procedure):: Receive raw data over a socket * Send (procedure):: Send raw data over a socket * Set_Buffer (procedure):: Install a line-oriented buffer of the socket object * Setsockopt (procedure):: Set a socket option * Shutdown (procedure):: Shutdown a socket * Socket (procedure):: Create a socket of the given mode * Unset_Buffer (procedure):: Deinstall the line-oriented buffer of the socket object  File: adasockets.info, Node: Accept_Socket (procedure) Accept_Socket (procedure) ------------------------- PURPOSE Accept an incoming connection PROTOTYPE - Sockets.Accept_Socket: procedure Accept_Socket (SOCKET : Socket_FD; NEW_SOCKET : out Socket_FD); PARAMETERS SOCKET in Initialized NEW_SOCKET out Incoming socket object DESCRIPTION This procedure creates a new socket corresponding to an incoming connection on TCP socket SOCKET. All the communications with the peer will take place on NEW_SOCKET, while the program can accept another connection on SOCKET. NEW_SOCKET must not be initialized before calling this procedure, or must have been cleaned up by calling `Shutdown', in order to avoid a file descriptors leak. `Accept_Socket' will block until an incoming connection is ready to be accepted. EXAMPLE declare Sock : Socket_FD; Incoming : Socket_FD; begin -- Create a TCP socket listening on local port 4161 Socket (Sock, PF_INET, SOCK_STREAM); Bind (Sock, 4161); Listen (Sock, 3); -- One-connection-at-a-time server (3 may be pending) loop -- Wait for a new connection and accept it Accept_Socket (Sock, Incoming); -- Do some dialog with the remote host Do_Some_Dialog (Incoming); -- Close incoming socket and wait for next connection Shutdown (Incoming); end loop; end; SEE ALSO *Note Bind (procedure)::, *Note Listen (procedure)::, *Note Shutdown (procedure)::, *Note Socket (procedure)::.  File: adasockets.info, Node: Bind (procedure) Bind (procedure) ---------------- PURPOSE Associate a local port to a socket PROTOTYPE - Sockets.Bind: procedure Bind (SOCKET : Socket_FD; PORT : Natural; HOST : String := ""); PARAMETERS SOCKET in Initialized socket object PORT in Local port to bind to HOST in Local interface to bind to DESCRIPTION This procedure requests a local port from the operating system. If 0 is given in PORT, the system will assign a free port whose number can later be retrieved using *Note Get_Sock_Port (function)::. Also, most operating systems require special privileges if you want to bind to ports below 1024. If HOST is not the empty string, it must contain the IP address of a local interface to bind to, or a name which resolves into such an address. If an empty string is given (the default), the socket will be bound to all the available interfaces. EXCEPTIONS `Socket_Error' Requested port or interface not available SEE ALSO *Note Listen (procedure)::, *Note Socket (procedure)::.  File: adasockets.info, Node: Connect (procedure) Connect (procedure) ------------------- PURPOSE Connect a socket on a given host/port PROTOTYPE - Sockets.Connect: procedure Connect (SOCKET : Socket_FD; HOST : String; PORT : Positive); PARAMETERS SOCKET in Initialized socket object HOST in Host to connect to PORT in Port to connect to DESCRIPTION This procedure connects an initialized socket to a given host on a given port. In the case of a TCP socket, a real connection is attempted. In the case of a UDP socket, no connection takes place but the endpoint coordinates are recorded. EXCEPTIONS `Connection_Refused'The connection has been refused by the server `Socket_Error' Another error occurred during the connection EXAMPLE declare Sock : Socket_FD; begin -- Create a TCP socket Socket (Sock, PF_INET, SOCK_STREAM); -- Connect it to rfc1149.net's mail server Connect (Sock, "mail.rfc1149.net", 25); -- Do a mail transaction then close the socket [...] end; SEE ALSO *Note Socket (procedure)::.  File: adasockets.info, Node: Get (function) Get (function) -------------- PURPOSE Get a string from a remote host PROTOTYPE - Sockets.Get: function Get (SOCKET : Socket_FD'Class) return String; PARAMETERS SOCKET in Initialized and connected socket object RETURN VALUE Some characters that have been received DESCRIPTION This function receives some characters from a remote host. As soon that at least one character is available, the current reception buffer is returned. There is usually little gain in using this function whose behaviour is comparable to the one of *Note Receive (function)::. Other functions such as *Note Get_Char (function)::, or *Note Get_Line (function)::, allow more structured programming. However, this function may be used to avoid loosing characters when calling *Note Unset_Buffer (procedure)::, if, for some reason, the remote host may have sent some. EXCEPTIONS `Connection_Closed'Peer has closed the connection before sending any data  File: adasockets.info, Node: Get_Char (function) Get_Char (function) ------------------- PURPOSE Get a character from a remote host PROTOTYPE - Sockets.Get_Char: function Get_Char (SOCKET : Socket_FD'Class) return Character; PARAMETERS SOCKET in Initialized and connected socket object RETURN VALUE One character sent by the remote host DESCRIPTION This function receives exactly one character from the remote host. EXCEPTIONS `Connection_Closed'Peer has closed the connection before sending the character SEE ALSO *Note Get (function)::, *Note Get_Line (function)::, *Note Get_Line (procedure)::, *Note Receive (procedure)::, *Note Set_Buffer (procedure)::.  File: adasockets.info, Node: Get_Line (procedure) Get_Line (procedure) -------------------- PURPOSE Get a whole line from a remote host PROTOTYPE - Sockets.Get_Line: procedure Get_Line (SOCKET : Socket_FD'Class; STR : in out String; LAST : out Natural); PARAMETERS SOCKET in Initialized and connected socket object STR in out String to fill LAST out Last index used in the string DESCRIPTION This procedure receives one line from the remote host. A line consists into zero or more characters followed by an optional CR and by a LF. Those terminators are stripped before the line is returned. This procedure blocks until one full line has been received. EXCEPTIONS `Connection_Closed'Peer has closed the connection before sending a whole line SEE ALSO *Note Get (function)::, *Note Get_Char (function)::, *Note Get_Line (function)::, *Note Receive (procedure)::, *Note Set_Buffer (procedure)::.  File: adasockets.info, Node: Get_Line (function) Get_Line (function) ------------------- PURPOSE Get a whole line from a remote host PROTOTYPE - Sockets.Get_Line: function Get_Line (SOCKET : Socket_FD'Class; MAX_LENGTH : Positive := 2048) return String; PARAMETERS SOCKET in Initialized and connected socket object MAX_LENGTH in Maximum returned line length RETURN VALUE A line without the CR and LF separators DESCRIPTION This function receives one line from the remote host. A line consists into zero or more characters followed by an optional CR and by a LF. Those terminators are stripped before the line is returned. This function blocks until one full line has been received. The line length is limited with the value of the Max_Length argument, to avoid exhaustion of the secondary stack. EXCEPTIONS `Connection_Closed'Peer has closed the connection before sending a whole line SEE ALSO *Note Get (function)::, *Note Get_Char (function)::, *Note Get_Line (procedure)::, *Note Receive (procedure)::, *Note Set_Buffer (procedure)::.  File: adasockets.info, Node: Getsockopt (procedure) Getsockopt (procedure) ---------------------- PURPOSE Retrieve a socket option PROTOTYPE - Sockets.Getsockopt: procedure Getsockopt (SOCKET : Socket_FD; LEVEL : Socket_Level := SOL_SOCKET; OPTNAME : Socket_Option; OPTVAL : out Integer); PARAMETERS SOCKET in Initialized and bound socket object LEVEL in Protocol level OPTNAME in Option name OPTVAL out Option value DESCRIPTION This procedure retrieves options applicable to a socket. Please see your operating system manual for usable levels and options. Two levels are defined: `SOL_SOCKET' (the default) and `IPPROTO_IP'. The options are `SO_REUSEADDR', `SO_REUSEPORT', `IP_MULTICAST_TTL', `IP_ADD_MEMBERSHIP', `IP_DROP_MEMBERSHIP', `IP_MULTICAST_LOOP', `SO_SNDBUF' and `IP_RCVBUF'. Note that unlike their C language counterpart, `Getsockopt' and `Setsockopt' do not require an extra parameter representing the length in bytes of the option value. AdaSockets nows the right size for every option. SEE ALSO *Note Setsockopt (procedure)::.  File: adasockets.info, Node: Listen (procedure) Listen (procedure) ------------------ PURPOSE Establish a listen queue PROTOTYPE - Sockets.Listen: procedure Listen (SOCKET : Socket_FD; QUEUE_SIZE : Positive := 5); PARAMETERS SOCKET in Initialized and bound socket object QUEUE_SIZE in Requested slots in the listen queue DESCRIPTION This procedure establishes a listen queue after a TCP socket as been initialized and bound. Each slot in the queue can hold one incoming connection that has not been accepted yet. Note that most operating systems ignore queue sizes larger than five. SEE ALSO *Note Accept_Socket (procedure)::, *Note Bind (procedure)::, *Note Socket (procedure)::.  File: adasockets.info, Node: New_Line (procedure) New_Line (procedure) -------------------- PURPOSE Send a CR/LF to a remote host PROTOTYPE - Sockets.New_Line: procedure New_Line (SOCKET : Socket_FD'Class; COUNT : Natural := 1); PARAMETERS SOCKET in Initialized and connected socket object COUNT in Number of CR/LF sequences to send DESCRIPTION This procedure sends one or more CR/LF combinations to the peer. EXCEPTIONS `Connection_Closed'Peer has prematurely closed the connection SEE ALSO *Note Put (procedure)::, *Note Put_Line (procedure)::.  File: adasockets.info, Node: Put (procedure) Put (procedure) --------------- PURPOSE Send a string to a remote host PROTOTYPE - Sockets.Put: procedure Put (SOCKET : Socket_FD'Class; STR : String); PARAMETERS SOCKET in Initialized and connected socket object STR in String to send DESCRIPTION This procedure sends the content of STR over an outgoing or incoming socket. EXCEPTIONS `Connection_Closed'Peer has prematurely closed the connection SEE ALSO *Note New_Line (procedure)::, *Note Put_Line (procedure)::, *Note Send (procedure)::.  File: adasockets.info, Node: Put_Line (procedure) Put_Line (procedure) -------------------- PURPOSE Send a CR/LF terminated string to a remote host PROTOTYPE - Sockets.Put_Line: procedure Put_Line (SOCKET : Socket_FD'Class; STR : String); PARAMETERS SOCKET in Initialized and connected socket object STR in String to send DESCRIPTION This procedure sends the content of STR plus a CR/LF combination over an outgoing or incoming socket. EXCEPTIONS `Connection_Closed'Peer has prematurely closed the connection SEE ALSO *Note New_Line (procedure)::, *Note Put (procedure)::, *Note Send (procedure)::.  File: adasockets.info, Node: Receive (procedure) Receive (procedure) ------------------- PURPOSE Receive raw data over a socket PROTOTYPE - Sockets.Receive: procedure Receive (SOCKET : Socket_FD'Class; DATA : out Ada.Streams.Stream_Element_Array); PARAMETERS SOCKET in Initialized and bound or connected socket object DATA out Incoming data buffer DESCRIPTION This procedure receives data from a bound UDP socket or a connected TCP socket. It will block until the DATA reception buffer has been totally filled. EXCEPTIONS `Connection_Closed'Peer has closed the connection before `Data'Length' bytes were received SEE ALSO *Note Get_Line (function)::, *Note Get_Line (procedure)::, *Note Receive (function)::, *Note Receive_Some (procedure)::.  File: adasockets.info, Node: Receive (function) Receive (function) ------------------ PURPOSE Receive raw data over a socket PROTOTYPE - Sockets.Receive: function Receive (SOCKET : Socket_FD; MAX : Ada.Streams.Stream_Element_Count := 4096) return Ada.Streams.Stream_Element_Array; PARAMETERS SOCKET in Initialized and bound or connected socket object MAX in Maximum data length RETURN VALUE Received raw data DESCRIPTION This procedure receives data from a bound UDP socket or a connected TCP socket. Only one system call will be performed; this function will return whatever data has arrived. Note that in GNAT the secondary stack may be used to store the data and may result in stack storage exhaustion. EXCEPTIONS `Connection_Closed'Peer has closed the connection before sending any data SEE ALSO *Note Receive (procedure)::, *Note Receive_Some (procedure)::, *Note Get_Line (function)::, *Note Get_Line (procedure)::.  File: adasockets.info, Node: Receive_Some (procedure) Receive_Some (procedure) ------------------------ PURPOSE Receive raw data over a socket PROTOTYPE - Sockets.Receive_Some: procedure Receive_Some (SOCKET : Socket_FD'Class; DATA : out Ada.Streams.Stream_Element_Array; LAST : out Ada.Streams.Stream_Element_Offset); PARAMETERS SOCKET in Initialized and bound or connected socket object DATA out Incoming data buffer LAST out Index of last element placed into DATA DESCRIPTION This procedure receives data from a bound UDP socket or a connected TCP socket. As soon as at least one byte has been read, it returns with LAST set to the index of the latest written element of DATA. EXCEPTIONS `Connection_Closed'Peer has closed the connection before sending any data SEE ALSO *Note Get_Line (function)::, *Note Get_Line (procedure)::, *Note Receive (function)::, *Note Receive (procedure)::.  File: adasockets.info, Node: Send (procedure) Send (procedure) ---------------- PURPOSE Send raw data over a socket PROTOTYPE - Sockets.Send: procedure Send (SOCKET : Socket_FD; DATA : out Ada.Streams.Stream_Element_Array); PARAMETERS SOCKET in Initialized and connected socket object DATA out Data to be sent DESCRIPTION This procedure sends data over a connected outgoing socket or over an incoming socket. EXCEPTIONS `Connection_Closed'Peer has prematurely closed the connection SEE ALSO *Note Put (procedure)::, *Note Put_Line (procedure)::.  File: adasockets.info, Node: Set_Buffer (procedure) Set_Buffer (procedure) ---------------------- PURPOSE Install a line-oriented buffer of the socket object PROTOTYPE - Sockets.Set_Buffer: procedure Set_Buffer (SOCKET : Socket_FD'Class; LENGTH : Positive := 1500); PARAMETERS SOCKET in Initialized and connected socket object LENGTH in Size in bytes of the newly installed buffer DESCRIPTION This procedure puts the socket object in buffered mode. If the socket was already buffered, the content of the previous buffer will be lost. The buffered mode only affects character- and line-oriented read operation such as *Note Get (function)::, *Note Get_Char (function)::, and *Note Get_Line (function)::. Other reception subprograms will not function properly if buffered mode is used at the same time. The size of the buffer has to be greater than the biggest possible packet sent by the remote host, otherwise data loss may occur. SEE ALSO *Note Unset_Buffer (procedure)::.  File: adasockets.info, Node: Setsockopt (procedure) Setsockopt (procedure) ---------------------- PURPOSE Set a socket option PROTOTYPE - Sockets.Setsockopt: procedure Setsockopt (SOCKET : Socket_FD; LEVEL : Socket_Level := SOL_SOCKET; OPTNAME : Socket_Option; OPTVAL : Integer); PARAMETERS SOCKET in Initialized and bound socket object LEVEL in Protocol level OPTNAME in Option name OPTVAL in Option value DESCRIPTION This procedure sets options applicable to a socket. Please see your operating system manual for usable levels and options. Two levels are defined: `SOL_SOCKET' (the default) and `IPPROTO_IP'. The options are `SO_REUSEADDR', `SO_REUSEPORT', `IP_MULTICAST_TTL', `IP_ADD_MEMBERSHIP', `IP_DROP_MEMBERSHIP', `IP_MULTICAST_LOOP', `SO_SNDBUF' and `IP_RCVBUF'. Note that unlike their C language counterpart, `Getsockopt' and `Setsockopt' do not require an extra parameter representing the length in bytes of the option value. AdaSockets nows the right size for every option. SEE ALSO *Note Getsockopt (procedure)::.  File: adasockets.info, Node: Shutdown (procedure) Shutdown (procedure) -------------------- PURPOSE Shutdown a socket PROTOTYPE - Sockets.Shutdown: procedure Shutdown (SOCKET : in out Socket_FD; HOW : Shutdown_Type := Both); PARAMETERS SOCKET in out Socket object to shutdown HOW in Direction to shutdown DESCRIPTION This procedure shutdowns either direction of the socket. HOW can take the value `Send', `Receive' or `Both'. SEE ALSO *Note Socket (procedure)::.  File: adasockets.info, Node: Socket (procedure) Socket (procedure) ------------------ PURPOSE Create a socket of the given mode PROTOTYPE - Sockets.Socket: procedure Socket (SOCKET : out Socket_FD; DOMAIN : Socket_Domain := PF_INET; TYP : Socket_Type := SOCK_STREAM); PARAMETERS SOCKET out Socket object to initialize DOMAIN in Protocol family TYP in Kind of sockets DESCRIPTION This procedure initializes a new socket object by reserving a file descriptor to the operating system. For backward compatibility with older versions of this library, `AF_INET' is still accepted as a value but should be replaced as soon as possible with the proper `PF_INET'. Using `SOCK_STREAM' for the TYP argument will create a TCP socket while a `SOCK_DGRAM' will create a UDP one. EXAMPLE declare Sock : Socket_FD; begin -- Create a TCP socket Socket (Sock, PF_INET, SOCK_STREAM); -- Perform some operations on socket [...] -- Shutdown the socket in both directions Shutdown (Sock, Both); end; SEE ALSO *Note Shutdown (procedure)::.  File: adasockets.info, Node: Unset_Buffer (procedure) Unset_Buffer (procedure) ------------------------ PURPOSE Deinstall the line-oriented buffer of the socket object PROTOTYPE - Sockets.Unset_Buffer: procedure Unset_Buffer (SOCKET : Socket_FD'Class); PARAMETERS SOCKET in Initialized and connected socket object DESCRIPTION This procedure deinstalls the buffer previously installed by *Note Set_Buffer (procedure)::. If any data is still present in the buffer, it will be lost. To avoid this situation, the buffer can be flushed by calling *Note Get (function)::.  File: adasockets.info, Node: Sockets.Multicast package, Next: Sockets.Naming package, Prev: Sockets package, Up: Top Sockets.Multicast package ************************* The `Sockets.Multicast' allows the creation of IP multicast sockets. - Sockets.Multicast.Multicast_Socket_FD: type Multicast_Socket_FD is new Socket_FD with private; The `Multicast_Socket_FD' tagged type derives from the `Socket_FD' type. It gets initialized by calling *Note Create_Multicast_Socket (function)::. * Menu: * Create_Multicast_Socket (function):: Create an IP multicast socket * Create_Multicast_Socket (function):: Create an IP multicast socket  File: adasockets.info, Node: Create_Multicast_Socket (function) Create_Multicast_Socket (function) ---------------------------------- PURPOSE Create an IP multicast socket PROTOTYPE - Sockets.Multicast.Create_Multicast_Socket: function Create_Multicast_Socket (GROUP : String; PORT : Positive; TTL : Positive := 16; SELF_LOOP : Boolean := True) return Multicast_Socket_FD; PARAMETERS GROUP in IP address of the multicast group to join PORT in Port of the multicast group to join TTL in Time-to-live of sent packets SELF_LOOP in Should the socket receive the packets sent from the local host? RETURN VALUE The new initialized multicast socket DESCRIPTION This function creates an IP multicast socket attached to a given group, identified by its class E IP address and port. Be careful when choosing the TTL parameter of your IP multicast socket. Most IP multicast routers do implement threshold-based filtering and will not let IP multicast packets leave your organization if the TTL on the last router is smaller than 16. EXAMPLE declare Sock : Multicast_Socket_FD; begin -- Create a multicast socket on group 224.1.2.3 port 8763 Sock := Create_Multicast_Socket ("224.1.2.3", 8763); -- Perform some operations on socket [...] -- Shutdown the socket in both directions Shutdown (Sock, Both); end; SEE ALSO *Note Send (procedure)::, *Note Shutdown (procedure)::.  File: adasockets.info, Node: Create_Multicast_Socket (function) Create_Multicast_Socket (function) ---------------------------------- PURPOSE Create an IP multicast socket PROTOTYPE - Sockets.Multicast.Create_Multicast_Socket: function Create_Multicast_Socket (GROUP : String; PORT : Positive; LOCAL_PORT : Natural; TTL : Positive := 16) return Multicast_Socket_FD; PARAMETERS GROUP in IP address of the multicast group to join PORT in Port of the multicast group to join LOCAL_PORT in Local port number to use TTL in Time-to-live of sent packets RETURN VALUE The new initialized multicast socket DESCRIPTION This function creates an IP multicast socket attached to a given group, identified by its class E IP address and port. If Local_Port is 0, a free port will automatically be chosen by your operating system. This function should be used when you want to send packets to a multicast group without receiving any packet yourself. EXAMPLE declare Sock : Multicast_Socket_FD; begin -- Create a multicast socket on group 224.1.2.3 port 8763 Sock := Create_Multicast_Socket ("224.1.2.3", 8763); -- Perform some operations on socket [...] -- Shutdown the socket in both directions Shutdown (Sock, Both); end; SEE ALSO *Note Send (procedure)::, *Note Shutdown (procedure)::.  File: adasockets.info, Node: Sockets.Naming package, Next: Contributors, Prev: Sockets.Multicast package, Up: Top Sockets.Naming package ********************** The `Sockets.Naming' package contains types and helper functions needed to manipulate Internet host names and addresses. - Sockets.Naming.Address: type Address is record H1, H2, H3, H4 : Address_Component; end record; This type represents an IPv4 address with `H1' being the first octet and `H4' the last one. For example, 137.194.161.2 is represented by `H1=137, H2=194, H3=161, H4=2'. - Sockets.Naming.Address_Array: type Address_Array is array (Positive range <>) of Address; Helper type - Sockets.Naming.Address_Component: type Address_Component is Natural range 0 .. 255; Helper type - Sockets.Naming.Host_Entry: type Host_Entry (N_Aliases, N_Addresses : Natural) is new Ada.Finalization.Controlled with record Name : String_Access; Aliases : String_Array (1 .. N_Aliases); Addresses : Address_Array (1 .. N_Addresses); end record; The `Host_Entry' type holds a set of names and IP addresses associated with a host. Each host can have several IP address as well as several aliases. - Sockets.Naming.String_Access: type String_Access is access String; Helper type - Sockets.Naming.String_Array: type String_Array is array (Positive range <>) of String_Access; Helper type * Menu: * Address_Of (function):: Get the IP address of a host * Any_Address (function):: Special address representing any address on the local host * Get_Peer_Addr (function):: Retrieve IP address of remote host * Get_Peer_Port (function):: Retrieve port used by remote host * Get_Sock_Addr (function):: Retrieve IP address of local host * Get_Sock_Port (function):: Retrieve port used by local host * Host_Name (function):: Get the name of the current host * Image (function):: Make a string from an address * Info_Of_Name_Or_IP (function):: Get addresses and names of a host * Is_IP_Address (function):: Check if given string is a valid IP address * Name_Of (function):: Official name of the host * Value (function):: Transform a string into an address  File: adasockets.info, Node: Address_Of (function) Address_Of (function) --------------------- PURPOSE Get the IP address of a host PROTOTYPE - Sockets.Naming.Address_Of: function Address_Of (SOMETHING : String) return Address; PARAMETERS SOMETHING in Host name or IP address RETURN VALUE IPv4 address EXCEPTIONS `Naming_Error' No information available for this name or address SEE ALSO *Note Name_Of (function)::.  File: adasockets.info, Node: Any_Address (function) Any_Address (function) ---------------------- PURPOSE Special address representing any address on the local host PROTOTYPE - Sockets.Naming.Any_Address: function Any_Address RETURN VALUE Equivalent to `INADDR_ANY' in the C programming language  File: adasockets.info, Node: Get_Peer_Addr (function) Get_Peer_Addr (function) ------------------------ PURPOSE Retrieve IP address of remote host PROTOTYPE - Sockets.Naming.Get_Peer_Addr: function Get_Peer_Addr (SOCKET : Socket_FD) return Address; PARAMETERS SOCKET in Connected socket object RETURN VALUE Peer address SEE ALSO *Note Get_Peer_Port (function)::, *Note Get_Sock_Addr (function)::.  File: adasockets.info, Node: Get_Peer_Port (function) Get_Peer_Port (function) ------------------------ PURPOSE Retrieve port used by remote host PROTOTYPE - Sockets.Naming.Get_Peer_Port: function Get_Peer_Port (SOCKET : Socket_FD) return Positive; PARAMETERS SOCKET in Connected socket object RETURN VALUE Port used on the remote host SEE ALSO *Note Get_Sock_Port (function)::, *Note Get_Peer_Addr (function)::.  File: adasockets.info, Node: Get_Sock_Addr (function) Get_Sock_Addr (function) ------------------------ PURPOSE Retrieve IP address of local host PROTOTYPE - Sockets.Naming.Get_Sock_Addr: function Get_Sock_Addr (SOCKET : Socket_FD) return Address; PARAMETERS SOCKET in Connected socket object RETURN VALUE Address of local interface used SEE ALSO *Note Get_Sock_Port (function)::, *Note Get_Peer_Addr (function)::.  File: adasockets.info, Node: Get_Sock_Port (function) Get_Sock_Port (function) ------------------------ PURPOSE Retrieve port used by local host PROTOTYPE - Sockets.Naming.Get_Sock_Port: function Get_Sock_Port (SOCKET : Socket_FD) return Positive; PARAMETERS SOCKET in Connected socket object RETURN VALUE Port used on the local host SEE ALSO *Note Get_Peer_Port (function)::, *Note Get_Sock_Addr (function)::.  File: adasockets.info, Node: Host_Name (function) Host_Name (function) -------------------- PURPOSE Get the name of the current host PROTOTYPE - Sockets.Naming.Host_Name: function Host_Name RETURN VALUE Name of the current host DESCRIPTION This function returns the name of the current host. Depending on the local configuration, it may or may not be a fully qualified domain name (FQDN).  File: adasockets.info, Node: Image (function) Image (function) ---------------- PURPOSE Make a string from an address PROTOTYPE - Sockets.Naming.Image: function Image (ADD : Address) return String; PARAMETERS ADD in IP address RETURN VALUE String representation of the IP address SEE ALSO *Note Value (function)::.  File: adasockets.info, Node: Info_Of_Name_Or_IP (function) Info_Of_Name_Or_IP (function) ----------------------------- PURPOSE Get addresses and names of a host PROTOTYPE - Sockets.Naming.Info_Of_Name_Or_IP: function Info_Of_Name_Or_IP (SOMETHING : String) return Host_Entry; PARAMETERS SOMETHING in Host name or IP address RETURN VALUE Corresponding host entry DESCRIPTION This function extracts all the names and addresses from the naming service. EXCEPTIONS `Naming_Error' No information available for this name or address  File: adasockets.info, Node: Is_IP_Address (function) Is_IP_Address (function) ------------------------ PURPOSE Check if given string is a valid IP address PROTOTYPE - Sockets.Naming.Is_IP_Address: function Is_IP_Address (SOMETHING : String) return Boolean; PARAMETERS SOMETHING in String to check RETURN VALUE `True' if SOMETHING is an IP address  File: adasockets.info, Node: Name_Of (function) Name_Of (function) ------------------ PURPOSE Official name of the host PROTOTYPE - Sockets.Naming.Name_Of: function Name_Of (SOMETHING : String) return String; PARAMETERS SOMETHING in Host name or IP address RETURN VALUE Name of the host EXCEPTIONS `Naming_Error' No information available for this name or address SEE ALSO *Note Address_Of (function)::.  File: adasockets.info, Node: Value (function) Value (function) ---------------- PURPOSE Transform a string into an address PROTOTYPE - Sockets.Naming.Value: function Value (ADD : String) return Address; PARAMETERS ADD in Textual representation of an IP address RETURN VALUE Corresponding Address SEE ALSO *Note Image (function)::.  File: adasockets.info, Node: Contributors, Next: Resources on the Internet, Prev: Sockets.Naming package, Up: Top Contributors ************ AdaSockets has been originally developped by Samuel Tardieu who still maintains it. However, the following people have made crucial contributions to AdaSockets, be they new code, bug fixes or porting to new operating systems: * Dmitriy Anisimkov () * Alan Barnes () * Juanma Barranquero () * Bobby D. Bryant () * Sander Cox () * Sune Falk () * Guillaume Foliard () * Laurent Guerby () * David J. Kristola () * Dominik Madon () * Pascal Obry () * Nicolas Ollinger () * Stéphane Patureau () * Thomas Quinot () * Preben Randhol () * Maxim Reznik () * Samuel Tardieu () If you feel that you have been forgotten, please send me a mail so that I can fix it in the next version. *Note Resources on the Internet::, for how to contribute.  File: adasockets.info, Node: Resources on the Internet, Next: Index, Prev: Contributors, Up: Top Resources on the Internet ************************* The latest version of AdaSockets can always be found at: There is a mailing-list that you can use to discuss problem or suggestions at: Please use the mailing-list for questions and discussions. However, you can send me patches by private mail ().  File: adasockets.info, Node: Index, Prev: Resources on the Internet, Up: Top Index ***** * Menu: * Accept_Socket: Accept_Socket (procedure). * Accepting a new connection: Accept_Socket (procedure). * Ada.Streams.Stream_Element_Array <1>: Raw data manipulation. * Ada.Streams.Stream_Element_Array <2>: Receive_Some (procedure). * Ada.Streams.Stream_Element_Array <3>: Send (procedure). * Ada.Streams.Stream_Element_Array <4>: Receive (function). * Ada.Streams.Stream_Element_Array: Receive (procedure). * Ada.Streams.Stream_Element_Count <1>: Receive (function). * Ada.Streams.Stream_Element_Count: Receive_Some (procedure). * AdaSockets presentation: What is AdaSockets?. * Address: Sockets.Naming package. * Address_Array: Sockets.Naming package. * Address_Component: Sockets.Naming package. * Address_Of: Address_Of (function). * AF_INET: Socket (procedure). * Any_Address: Any_Address (function). * Assigning a local port: Bind (procedure). * Bind: Bind (procedure). * Binding a socket: Bind (procedure). * Both: Shutdown (procedure). * Closing a socket: Shutdown (procedure). * Comparaison with GNAT.Sockets: What is AdaSockets?. * Connect: Connect (procedure). * Connecting a socket: Connect (procedure). * Connection_Closed <1>: New_Line (procedure). * Connection_Closed <2>: Get (function). * Connection_Closed <3>: Get_Char (function). * Connection_Closed <4>: Get_Line (procedure). * Connection_Closed <5>: Get_Line (function). * Connection_Closed <6>: Receive_Some (procedure). * Connection_Closed <7>: Put (procedure). * Connection_Closed <8>: Put_Line (procedure). * Connection_Closed <9>: Receive (procedure). * Connection_Closed <10>: Send (procedure). * Connection_Closed: Receive (function). * Connection_Refused: Connect (procedure). * Contributing <1>: Resources on the Internet. * Contributing: Contributors. * CR <1>: New_Line (procedure). * CR <2>: Get_Line (function). * CR: Get_Line (procedure). * Create_Multicast_Socket <1>: Create_Multicast_Socket (function). * Create_Multicast_Socket <2>: Setting up multicast sockets. * Create_Multicast_Socket: Create_Multicast_Socket (function). * Creating a multicast socket <1>: Create_Multicast_Socket (function). * Creating a multicast socket <2>: Create_Multicast_Socket (function). * Creating a multicast socket: Setting up multicast sockets. * Creating a server: Bind (procedure). * Creating a socket <1>: Create_Multicast_Socket (function). * Creating a socket <2>: Socket (procedure). * Creating a socket <3>: Create_Multicast_Socket (function). * Creating a socket: Setting up unicast sockets. * Creating a TCP socket: Setting up unicast sockets. * Creating a UDP socket: Setting up unicast sockets. * Creating a unicast socket: Setting up unicast sockets. * Establishing a listen queue: Listen (procedure). * Finding AdaSockets on the Internet: Resources on the Internet. * Get: Get (function). * Get_Char: Get_Char (function). * Get_Line <1>: Get_Line (procedure). * Get_Line: Get_Line (function). * Get_Peer_Addr: Get_Peer_Addr (function). * Get_Peer_Port: Get_Peer_Port (function). * Get_Sock_Addr: Get_Sock_Addr (function). * Get_Sock_Port: Get_Sock_Port (function). * Getsockopt: Getsockopt (procedure). * Group communication: Setting up multicast sockets. * Handling a new connection: Accept_Socket (procedure). * Host_Entry: Sockets.Naming package. * Host_Name: Host_Name (function). * Image: Image (function). * Info_Of_Name_Or_IP: Info_Of_Name_Or_IP (function). * Installing AdaSockets: Installing AdaSockets. * IP_ADD_MEMBERSHIP <1>: Setsockopt (procedure). * IP_ADD_MEMBERSHIP: Getsockopt (procedure). * IP_DROP_MEMBERSHIP <1>: Setsockopt (procedure). * IP_DROP_MEMBERSHIP: Getsockopt (procedure). * IP_MULTICAST_LOOP <1>: Getsockopt (procedure). * IP_MULTICAST_LOOP: Setsockopt (procedure). * IP_MULTICAST_TTL <1>: Setsockopt (procedure). * IP_MULTICAST_TTL: Getsockopt (procedure). * IPPROTO_IP <1>: Setsockopt (procedure). * IPPROTO_IP: Getsockopt (procedure). * Is_IP_Address: Is_IP_Address (function). * LF <1>: Get_Line (function). * LF <2>: Get_Line (procedure). * LF: New_Line (procedure). * Listen: Listen (procedure). * Listen queue: Listen (procedure). * Manipulating socket options <1>: Setsockopt (procedure). * Manipulating socket options: Getsockopt (procedure). * Mbone: Setting up multicast sockets. * Multicast sockets: Setting up multicast sockets. * Multicast_Socket_FD <1>: Sockets.Multicast package. * Multicast_Socket_FD: Setting up multicast sockets. * Name_Of: Name_Of (function). * Naming_Error <1>: Info_Of_Name_Or_IP (function). * Naming_Error <2>: Address_Of (function). * Naming_Error: Name_Of (function). * New_Line: New_Line (procedure). * PF_INET: Socket (procedure). * Put: Put (procedure). * Put_Line: Put_Line (procedure). * Raw data manipulation: Raw data manipulation. * Receive <1>: Shutdown (procedure). * Receive <2>: Receive (function). * Receive: Receive (procedure). * Receive_Some: Receive_Some (procedure). * Receiving data <1>: Get_Line (function). * Receiving data <2>: Receive_Some (procedure). * Receiving data <3>: Get_Char (function). * Receiving data <4>: Get_Line (procedure). * Receiving data <5>: Set_Buffer (procedure). * Receiving data <6>: Receive (function). * Receiving data <7>: Get (function). * Receiving data <8>: Unset_Buffer (procedure). * Receiving data <9>: Receive (procedure). * Receiving data: Sending and receiving data. * Reporting a bug: Resources on the Internet. * Representing IP addresses <1>: Value (function). * Representing IP addresses: Image (function). * Retrieving socket options: Getsockopt (procedure). * Send <1>: Shutdown (procedure). * Send: Send (procedure). * Sending data <1>: Sending and receiving data. * Sending data <2>: Send (procedure). * Sending data <3>: Put_Line (procedure). * Sending data <4>: New_Line (procedure). * Sending data: Put (procedure). * Sending patches: Resources on the Internet. * Set_Buffer: Set_Buffer (procedure). * Setsockopt: Setsockopt (procedure). * Setting socket options: Setsockopt (procedure). * Shutdown: Shutdown (procedure). * SO_RCVBUF <1>: Getsockopt (procedure). * SO_RCVBUF: Setsockopt (procedure). * SO_REUSEADDR <1>: Getsockopt (procedure). * SO_REUSEADDR: Setsockopt (procedure). * SO_REUSEPORT <1>: Setsockopt (procedure). * SO_REUSEPORT: Getsockopt (procedure). * SO_SNDBUF <1>: Setsockopt (procedure). * SO_SNDBUF: Getsockopt (procedure). * SOCK_DGRAM: Socket (procedure). * SOCK_STREAM: Socket (procedure). * Socket <1>: Setting up unicast sockets. * Socket: Socket (procedure). * Socket shutdown: Shutdown (procedure). * Socket_Error <1>: Bind (procedure). * Socket_Error: Connect (procedure). * Socket_FD <1>: Sockets package. * Socket_FD: Setting up unicast sockets. * Sockets.Accept_Socket: Accept_Socket (procedure). * Sockets.Bind: Bind (procedure). * Sockets.Connect: Connect (procedure). * Sockets.Get: Get (function). * Sockets.Get_Char: Get_Char (function). * Sockets.Get_Line <1>: Get_Line (function). * Sockets.Get_Line: Get_Line (procedure). * Sockets.Getsockopt: Getsockopt (procedure). * Sockets.IP_ADD_MEMBERSHIP <1>: Setsockopt (procedure). * Sockets.IP_ADD_MEMBERSHIP: Getsockopt (procedure). * Sockets.IP_DROP_MEMBERSHIP <1>: Getsockopt (procedure). * Sockets.IP_DROP_MEMBERSHIP: Setsockopt (procedure). * Sockets.IP_MULTICAST_LOOP <1>: Setsockopt (procedure). * Sockets.IP_MULTICAST_LOOP: Getsockopt (procedure). * Sockets.IP_MULTICAST_TTL <1>: Setsockopt (procedure). * Sockets.IP_MULTICAST_TTL: Getsockopt (procedure). * Sockets.IPPROTO_IP <1>: Getsockopt (procedure). * Sockets.IPPROTO_IP: Setsockopt (procedure). * Sockets.Listen: Listen (procedure). * Sockets.Multicast.Create_Multicast_Socket <1>: Create_Multicast_Socket (function). * Sockets.Multicast.Create_Multicast_Socket <2>: Setting up multicast sockets. * Sockets.Multicast.Create_Multicast_Socket: Create_Multicast_Socket (function). * Sockets.Naming.Address_Of: Address_Of (function). * Sockets.Naming.Any_Address: Any_Address (function). * Sockets.Naming.Get_Peer_Addr: Get_Peer_Addr (function). * Sockets.Naming.Get_Peer_Port: Get_Peer_Port (function). * Sockets.Naming.Get_Sock_Addr: Get_Sock_Addr (function). * Sockets.Naming.Get_Sock_Port: Get_Sock_Port (function). * Sockets.Naming.Host_Name: Host_Name (function). * Sockets.Naming.Image: Image (function). * Sockets.Naming.Info_Of_Name_Or_IP: Info_Of_Name_Or_IP (function). * Sockets.Naming.Is_IP_Address: Is_IP_Address (function). * Sockets.Naming.Name_Of: Name_Of (function). * Sockets.Naming.Value: Value (function). * Sockets.New_Line: New_Line (procedure). * Sockets.Put: Put (procedure). * Sockets.Put_Line: Put_Line (procedure). * Sockets.Receive <1>: Receive (procedure). * Sockets.Receive: Receive (function). * Sockets.Receive_Some: Receive_Some (procedure). * Sockets.Send: Send (procedure). * Sockets.Set_Buffer: Set_Buffer (procedure). * Sockets.Setsockopt: Setsockopt (procedure). * Sockets.Shutdown: Shutdown (procedure). * Sockets.SO_RCVBUF <1>: Setsockopt (procedure). * Sockets.SO_RCVBUF: Getsockopt (procedure). * Sockets.SO_REUSEADDR <1>: Getsockopt (procedure). * Sockets.SO_REUSEADDR: Setsockopt (procedure). * Sockets.SO_REUSEPORT <1>: Setsockopt (procedure). * Sockets.SO_REUSEPORT: Getsockopt (procedure). * Sockets.SO_SNDBUF <1>: Setsockopt (procedure). * Sockets.SO_SNDBUF: Getsockopt (procedure). * Sockets.Socket <1>: Socket (procedure). * Sockets.Socket: Setting up unicast sockets. * Sockets.SOL_SOCKET <1>: Setsockopt (procedure). * Sockets.SOL_SOCKET: Getsockopt (procedure). * Sockets.Unset_Buffer: Unset_Buffer (procedure). * SOL_SOCKET <1>: Getsockopt (procedure). * SOL_SOCKET: Setsockopt (procedure). * Stream_Element_Array <1>: Send (procedure). * Stream_Element_Array <2>: Receive_Some (procedure). * Stream_Element_Array <3>: Raw data manipulation. * Stream_Element_Array <4>: Receive (procedure). * Stream_Element_Array: Receive (function). * Stream_Element_Count <1>: Receive_Some (procedure). * Stream_Element_Count: Receive (function). * String_Access: Sockets.Naming package. * String_Array: Sockets.Naming package. * Suggesting a feature: Resources on the Internet. * TCP socket: Setting up unicast sockets. * UDP socket: Setting up unicast sockets. * Unicast sockets: Setting up unicast sockets. * Unset_Buffer: Unset_Buffer (procedure). * Value: Value (function).  Tag Table: Node: Top795 Node: What is AdaSockets?1369 Node: Installing AdaSockets2254 Node: Using AdaSockets3234 Node: Compiling an Ada application3521 Node: Setting up unicast sockets4139 Node: Setting up multicast sockets5430 Node: Sending and receiving data6747 Node: Raw data manipulation7101 Node: String-oriented exchanges7488 Node: Sockets package8567 Node: Accept_Socket (procedure)10510 Node: Bind (procedure)12294 Node: Connect (procedure)13472 Node: Get (function)14728 Node: Get_Char (function)15837 Node: Get_Line (procedure)16616 Node: Get_Line (function)17679 Node: Getsockopt (procedure)18896 Node: Listen (procedure)20114 Node: New_Line (procedure)20897 Node: Put (procedure)21537 Node: Put_Line (procedure)22179 Node: Receive (procedure)22883 Node: Receive (function)23814 Node: Receive_Some (procedure)24934 Node: Send (procedure)26036 Node: Set_Buffer (procedure)26680 Node: Setsockopt (procedure)27803 Node: Shutdown (procedure)29007 Node: Socket (procedure)29555 Node: Unset_Buffer (procedure)30834 Node: Sockets.Multicast package31473 Node: Create_Multicast_Socket (function)32189 Node: Create_Multicast_Socket (function)33874 Node: Sockets.Naming package35443 Node: Address_Of (function)37948 Node: Any_Address (function)38473 Node: Get_Peer_Addr (function)38794 Node: Get_Peer_Port (function)39275 Node: Get_Sock_Addr (function)39772 Node: Get_Sock_Port (function)40271 Node: Host_Name (function)40766 Node: Image (function)41196 Node: Info_Of_Name_Or_IP (function)41578 Node: Is_IP_Address (function)42219 Node: Name_Of (function)42637 Node: Value (function)43135 Node: Contributors43533 Node: Resources on the Internet44863 Node: Index45406  End Tag Table