src/lib/xmmsipc/msg.c File Reference

#include <stdarg.h>
#include <string.h>
#include <stdlib.h>
#include <errno.h>
#include <time.h>
#include <assert.h>
#include "xmmspriv/xmms_list.h"
#include "xmmsc/xmmsc_ipc_transport.h"
#include "xmmsc/xmmsc_ipc_msg.h"
#include "xmmsc/xmmsc_util.h"
#include "xmmsc/xmmsc_sockets.h"
#include "xmmsc/xmmsc_stdint.h"
#include "xmmsc/xmmsv_coll.h"

Go to the source code of this file.

Functions

xmms_ipc_msg_txmms_ipc_msg_alloc (void)
xmms_ipc_msg_txmms_ipc_msg_new (uint32_t object, uint32_t cmd)
void xmms_ipc_msg_destroy (xmms_ipc_msg_t *msg)
void xmms_ipc_msg_set_length (xmms_ipc_msg_t *msg, uint32_t len)
uint32_t xmms_ipc_msg_get_length (const xmms_ipc_msg_t *msg)
uint32_t xmms_ipc_msg_get_object (const xmms_ipc_msg_t *msg)
void xmms_ipc_msg_set_object (xmms_ipc_msg_t *msg, uint32_t object)
uint32_t xmms_ipc_msg_get_cmd (const xmms_ipc_msg_t *msg)
void xmms_ipc_msg_set_cmd (xmms_ipc_msg_t *msg, uint32_t cmd)
void xmms_ipc_msg_set_cookie (xmms_ipc_msg_t *msg, uint32_t cookie)
uint32_t xmms_ipc_msg_get_cookie (const xmms_ipc_msg_t *msg)
bool xmms_ipc_msg_write_transport (xmms_ipc_msg_t *msg, xmms_ipc_transport_t *transport, bool *disconnected)
 Try to write message to transport.
bool xmms_ipc_msg_read_transport (xmms_ipc_msg_t *msg, xmms_ipc_transport_t *transport, bool *disconnected)
 Try to read message from transport into msg.
uint32_t xmms_ipc_msg_put_value (xmms_ipc_msg_t *msg, xmmsv_t *v)
bool xmms_ipc_msg_get_value (xmms_ipc_msg_t *msg, xmmsv_t **val)

Function Documentation

xmms_ipc_msg_t* xmms_ipc_msg_alloc ( void   ) 

Definition at line 96 of file msg.c.

Referenced by xmms_ipc_msg_new().

void xmms_ipc_msg_destroy ( xmms_ipc_msg_t msg  ) 

Definition at line 122 of file msg.c.

uint32_t xmms_ipc_msg_get_cmd ( const xmms_ipc_msg_t msg  ) 

Definition at line 163 of file msg.c.

uint32_t xmms_ipc_msg_get_cookie ( const xmms_ipc_msg_t msg  ) 

Definition at line 185 of file msg.c.

uint32_t xmms_ipc_msg_get_length ( const xmms_ipc_msg_t msg  ) 
uint32_t xmms_ipc_msg_get_object ( const xmms_ipc_msg_t msg  ) 

Definition at line 147 of file msg.c.

bool xmms_ipc_msg_get_value ( xmms_ipc_msg_t msg,
xmmsv_t **  val 
)

Definition at line 961 of file msg.c.

xmms_ipc_msg_t* xmms_ipc_msg_new ( uint32_t  object,
uint32_t  cmd 
)

Definition at line 109 of file msg.c.

uint32_t xmms_ipc_msg_put_value ( xmms_ipc_msg_t msg,
xmmsv_t *  v 
)

Definition at line 470 of file msg.c.

bool xmms_ipc_msg_read_transport ( xmms_ipc_msg_t msg,
xmms_ipc_transport_t transport,
bool *  disconnected 
)

Try to read message from transport into msg.

Returns:
TRUE if message is fully read.

Definition at line 246 of file msg.c.

void xmms_ipc_msg_set_cmd ( xmms_ipc_msg_t msg,
uint32_t  cmd 
)

Definition at line 171 of file msg.c.

Referenced by xmms_ipc_msg_new().

void xmms_ipc_msg_set_cookie ( xmms_ipc_msg_t msg,
uint32_t  cookie 
)

Definition at line 179 of file msg.c.

void xmms_ipc_msg_set_length ( xmms_ipc_msg_t msg,
uint32_t  len 
)

Definition at line 131 of file msg.c.

void xmms_ipc_msg_set_object ( xmms_ipc_msg_t msg,
uint32_t  object 
)

Definition at line 155 of file msg.c.

Referenced by xmms_ipc_msg_new().

bool xmms_ipc_msg_write_transport ( xmms_ipc_msg_t msg,
xmms_ipc_transport_t transport,
bool *  disconnected 
)

Try to write message to transport.

If full message isn't written the message will keep track of the amount of data written and not write already written data next time.

Returns:
TRUE if full message was written, FALSE otherwise. disconnected is set if transport was disconnected

Definition at line 201 of file msg.c.


Generated on Tue Feb 23 18:14:36 2010 for XMMS2 by  doxygen 1.6.1