mw_st_list.h(3)

NAME
mw_st_list.h -

Detailed Description

Parse and compose buddy lists in the format commonly used by Sametime Connect clients.

SYNOPSIS

#include <glib.h>
#include <glib/glist.h>
#include 'mw_common.h'

  Defines
#define ST_LIST_MAJOR 3
#define ST_LIST_MICRO 3
#define ST_LIST_MINOR 1

  Enumerations
enum mwSametimeGroupType { mwSametimeGroup_NORMAL = 1, mwSametimeGroup_DYNAMIC = 2, mwSametimeGroup_UNKNOWN = 0 }
enum mwSametimeUserType { mwSametimeUser_NORMAL = 1, mwSametimeUser_EXTERNAL = 2, mwSametimeUser_UNKNOWN = 0 }

  Functions
struct mwSametimeUser * mwSametimeGroup_findUser (struct mwSametimeGroup *g, struct mwIdBlock *user)
void mwSametimeGroup_free (struct mwSametimeGroup *g)
Remove a group from its list, and free it.
const char * mwSametimeGroup_getAlias (struct mwSametimeGroup *g)
struct mwSametimeList * mwSametimeGroup_getList (struct mwSametimeGroup *g)
const char * mwSametimeGroup_getName (struct mwSametimeGroup *g)
enum mwSametimeGroupType mwSametimeGroup_getType (struct mwSametimeGroup *g)
GList * mwSametimeGroup_getUsers (struct mwSametimeGroup *g)
Get a GList snapshot of the users in a list.
gboolean mwSametimeGroup_isOpen (struct mwSametimeGroup *g)
struct mwSametimeGroup * mwSametimeGroup_new (struct mwSametimeList *l, enum mwSametimeGroupType type, const char *name)
Create a new group in a list.
void mwSametimeGroup_setAlias (struct mwSametimeGroup *g, const char *alias)
void mwSametimeGroup_setOpen (struct mwSametimeGroup *g, gboolean open)
struct mwSametimeGroup * mwSametimeList_findGroup (struct mwSametimeList *l, const char *name)
void mwSametimeList_free (struct mwSametimeList *l)
Free the list, all of its groups, and all of the groups' members.
void mwSametimeList_get (struct mwGetBuffer *b, struct mwSametimeList *l)
Load a sametime list from a buffer.
GList * mwSametimeList_getGroups (struct mwSametimeList *l)
Get a GList snapshot of the groups in a list.
guint mwSametimeList_getMajor (struct mwSametimeList *l)
guint mwSametimeList_getMicro (struct mwSametimeList *l)
guint mwSametimeList_getMinor (struct mwSametimeList *l)
struct mwSametimeList * mwSametimeList_load (const char *str)
convert a plain string into a sametime list
struct mwSametimeList * mwSametimeList_new ()
Create a new list.
void mwSametimeList_put (struct mwPutBuffer *b, struct mwSametimeList *l)
Write a sametime list onto a buffer.
void mwSametimeList_setMajor (struct mwSametimeList *l, guint v)
void mwSametimeList_setMicro (struct mwSametimeList *l, guint v)
void mwSametimeList_setMinor (struct mwSametimeList *l, guint v)
char * mwSametimeList_store (struct mwSametimeList *l)
convert a sametime list into a string
void mwSametimeUser_free (struct mwSametimeUser *u)
Remove user from its group, and free it.
const char * mwSametimeUser_getAlias (struct mwSametimeUser *u)
const char * mwSametimeUser_getCommunity (struct mwSametimeUser *u)
struct mwSametimeGroup * mwSametimeUser_getGroup (struct mwSametimeUser *u)
const char * mwSametimeUser_getShortName (struct mwSametimeUser *u)
enum mwSametimeUserType mwSametimeUser_getType (struct mwSametimeUser *u)
const char * mwSametimeUser_getUser (struct mwSametimeUser *u)
struct mwSametimeUser * mwSametimeUser_new (struct mwSametimeGroup *g, enum mwSametimeUserType type, struct mwIdBlock *user)
Create a user in a group.
void mwSametimeUser_setAlias (struct mwSametimeUser *u, const char *alias)
void mwSametimeUser_setShortName (struct mwSametimeUser *u, const char *name)

Define Documentation

  #define ST_LIST_MAJOR 3

  #define ST_LIST_MICRO 3

  #define ST_LIST_MINOR 1

Enumeration Type Documentation

  enum mwSametimeGroupType

Enumerator:

mwSametimeGroup_NORMAL
    a normal group of users

mwSametimeGroup_DYNAMIC
    a server-side group

mwSametimeGroup_UNKNOWN
    error determining group type

  enum mwSametimeUserType

Enumerator:

mwSametimeUser_NORMAL
    user on same community

mwSametimeUser_EXTERNAL
    external user

mwSametimeUser_UNKNOWN
    error determining user type

Function Documentation

  struct mwSametimeUser* mwSametimeGroup_findUser (struct mwSametimeGroup * g, struct mwIdBlock * user) [read]

  void mwSametimeGroup_free (struct mwSametimeGroup * g)

Remove a group from its list, and free it.

Also frees all users contained in the group

  const char* mwSametimeGroup_getAlias (struct mwSametimeGroup * g)

  struct mwSametimeList* mwSametimeGroup_getList (struct mwSametimeGroup * g) [read]

  const char* mwSametimeGroup_getName (struct mwSametimeGroup * g)

  enum mwSametimeGroupType mwSametimeGroup_getType (struct mwSametimeGroup * g)

  GList* mwSametimeGroup_getUsers (struct mwSametimeGroup * g)

Get a GList snapshot of the users in a list.

  gboolean mwSametimeGroup_isOpen (struct mwSametimeGroup * g)

  struct mwSametimeGroup* mwSametimeGroup_new (struct mwSametimeList * l, enum mwSametimeGroupType type, const char * name) [read]

Create a new group in a list.

  void mwSametimeGroup_setAlias (struct mwSametimeGroup * g, const char * alias)

  void mwSametimeGroup_setOpen (struct mwSametimeGroup * g, gboolean open)

  struct mwSametimeGroup* mwSametimeList_findGroup (struct mwSametimeList * l, const char * name) [read]

  void mwSametimeList_free (struct mwSametimeList * l)

Free the list, all of its groups, and all of the groups' members.

  void mwSametimeList_get (struct mwGetBuffer * b, struct mwSametimeList * l)

Load a sametime list from a buffer.

The list must be encapsulated as a string (eg, the first two bytes in the buffer should be the length of the string)

  GList* mwSametimeList_getGroups (struct mwSametimeList * l)

Get a GList snapshot of the groups in a list.

  guint mwSametimeList_getMajor (struct mwSametimeList * l)

  guint mwSametimeList_getMicro (struct mwSametimeList * l)

  guint mwSametimeList_getMinor (struct mwSametimeList * l)

  struct mwSametimeList* mwSametimeList_load (const char * str) [read]

convert a plain string into a sametime list

  struct mwSametimeList* mwSametimeList_new () [read]

Create a new list.

  void mwSametimeList_put (struct mwPutBuffer * b, struct mwSametimeList * l)

Write a sametime list onto a buffer.

The list will be encapsulated in a string (the first two bytes written will be the length of the rest of the written list data)

  void mwSametimeList_setMajor (struct mwSametimeList * l, guint v)

  void mwSametimeList_setMicro (struct mwSametimeList * l, guint v)

  void mwSametimeList_setMinor (struct mwSametimeList * l, guint v)

  char* mwSametimeList_store (struct mwSametimeList * l)

convert a sametime list into a string

  void mwSametimeUser_free (struct mwSametimeUser * u)

Remove user from its group, and free it.

  const char* mwSametimeUser_getAlias (struct mwSametimeUser * u)

  const char* mwSametimeUser_getCommunity (struct mwSametimeUser * u)

  struct mwSametimeGroup* mwSametimeUser_getGroup (struct mwSametimeUser * u) [read]

  const char* mwSametimeUser_getShortName (struct mwSametimeUser * u)

  enum mwSametimeUserType mwSametimeUser_getType (struct mwSametimeUser * u)

  const char* mwSametimeUser_getUser (struct mwSametimeUser * u)

  struct mwSametimeUser* mwSametimeUser_new (struct mwSametimeGroup * g, enum mwSametimeUserType type, struct mwIdBlock * user) [read]

Create a user in a group.

  void mwSametimeUser_setAlias (struct mwSametimeUser * u, const char * alias)

  void mwSametimeUser_setShortName (struct mwSametimeUser * u, const char * name)

Author

Generated automatically by Doxygen for meanwhile from the source code.