rabbitmq-c  0.5.0
C AMQP Client library for RabbitMQ
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Functions
amqp_tcp_socket.h File Reference

Go to the source code of this file.

Functions

amqp_socket_t * amqp_tcp_socket_new (amqp_connection_state_t state)
 A TCP socket connection. More...
 
void amqp_tcp_socket_set_sockfd (amqp_socket_t *self, int sockfd)
 Assign an open file descriptor to a socket object. More...
 

Function Documentation

amqp_socket_t* amqp_tcp_socket_new ( amqp_connection_state_t  state)

A TCP socket connection.

Create a new TCP socket.

Call amqp_connection_close() to release socket resources.

Returns
A new socket object or NULL if an error occurred.
Since
v0.4.0
void amqp_tcp_socket_set_sockfd ( amqp_socket_t *  self,
int  sockfd 
)

Assign an open file descriptor to a socket object.

This function must not be used in conjunction with amqp_socket_open(), i.e. the socket connection should already be open(2) when this function is called.

Parameters
[in,out]selfA TCP socket object.
[in]sockfdAn open socket descriptor.
Since
v0.4.0