Frameworks/libpurple.framework/Versions/0.5.6/Headers/buddy.h
branchadium-1.3
changeset 350 708bedafdc3a
parent 349 17ef128722b7
child 351 b01ab9b157f9
     1.1 --- a/Frameworks/libpurple.framework/Versions/0.5.6/Headers/buddy.h	Sun Jun 21 22:04:11 2009 -0400
     1.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.3 @@ -1,124 +0,0 @@
     1.4 -/**
     1.5 - * @file buddy.h Buddy handlers
     1.6 - *
     1.7 - * purple
     1.8 - *
     1.9 - * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
    1.10 - *
    1.11 - * This program is free software; you can redistribute it and/or modify
    1.12 - * it under the terms of the GNU General Public License as published by
    1.13 - * the Free Software Foundation; either version 2 of the License, or
    1.14 - * (at your option) any later version.
    1.15 - *
    1.16 - * This program is distributed in the hope that it will be useful,
    1.17 - * but WITHOUT ANY WARRANTY; without even the implied warranty of
    1.18 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    1.19 - * GNU General Public License for more details.
    1.20 - *
    1.21 - * You should have received a copy of the GNU General Public License
    1.22 - * along with this program; if not, write to the Free Software
    1.23 - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02111-1301  USA
    1.24 - */
    1.25 -#ifndef _PURPLE_JABBER_BUDDY_H_
    1.26 -#define _PURPLE_JABBER_BUDDY_H_
    1.27 -
    1.28 -typedef enum {
    1.29 -	JABBER_BUDDY_STATE_UNKNOWN = -2,
    1.30 -	JABBER_BUDDY_STATE_ERROR = -1,
    1.31 -	JABBER_BUDDY_STATE_UNAVAILABLE = 0,
    1.32 -	JABBER_BUDDY_STATE_ONLINE,
    1.33 -	JABBER_BUDDY_STATE_CHAT,
    1.34 -	JABBER_BUDDY_STATE_AWAY,
    1.35 -	JABBER_BUDDY_STATE_XA,
    1.36 -	JABBER_BUDDY_STATE_DND
    1.37 -} JabberBuddyState;
    1.38 -
    1.39 -#include "jabber.h"
    1.40 -#include "caps.h"
    1.41 -
    1.42 -#define AVATARNAMESPACEDATA "http://www.xmpp.org/extensions/xep-0084.html#ns-data"
    1.43 -#define AVATARNAMESPACEMETA "http://www.xmpp.org/extensions/xep-0084.html#ns-metadata"
    1.44 -
    1.45 -typedef struct _JabberBuddy {
    1.46 -	GList *resources;
    1.47 -	char *error_msg;
    1.48 -	enum {
    1.49 -		JABBER_INVISIBLE_NONE   = 0,
    1.50 -		JABBER_INVISIBLE_SERVER = 1 << 1,
    1.51 -		JABBER_INVIS_BUDDY      = 1 << 2
    1.52 -	} invisible;
    1.53 -	enum {
    1.54 -		JABBER_SUB_NONE    = 0,
    1.55 -		JABBER_SUB_PENDING = 1 << 1,
    1.56 -		JABBER_SUB_TO      = 1 << 2,
    1.57 -		JABBER_SUB_FROM    = 1 << 3,
    1.58 -		JABBER_SUB_BOTH    = (JABBER_SUB_TO | JABBER_SUB_FROM),
    1.59 -		JABBER_SUB_REMOVE  = 1 << 4
    1.60 -	} subscription;
    1.61 -} JabberBuddy;
    1.62 -
    1.63 -typedef struct _JabberAdHocCommands {
    1.64 -	char *jid;
    1.65 -	char *node;
    1.66 -	char *name;
    1.67 -} JabberAdHocCommands;
    1.68 -
    1.69 -typedef struct _JabberBuddyResource {
    1.70 -	JabberBuddy *jb;
    1.71 -	char *name;
    1.72 -	int priority;
    1.73 -	JabberBuddyState state;
    1.74 -	char *status;
    1.75 -	JabberCapabilities capabilities;
    1.76 -	char *thread_id;
    1.77 -	enum {
    1.78 -		JABBER_CHAT_STATES_UNKNOWN,
    1.79 -		JABBER_CHAT_STATES_UNSUPPORTED,
    1.80 -		JABBER_CHAT_STATES_SUPPORTED
    1.81 -	} chat_states;
    1.82 -	struct {
    1.83 -		char *version;
    1.84 -		char *name;
    1.85 -		char *os;
    1.86 -	} client;
    1.87 -	JabberCapsClientInfo *caps;
    1.88 -	GList *commands;
    1.89 -} JabberBuddyResource;
    1.90 -
    1.91 -void jabber_buddy_free(JabberBuddy *jb);
    1.92 -JabberBuddy *jabber_buddy_find(JabberStream *js, const char *name,
    1.93 -		gboolean create);
    1.94 -JabberBuddyResource *jabber_buddy_find_resource(JabberBuddy *jb,
    1.95 -		const char *resource);
    1.96 -JabberBuddyResource *jabber_buddy_track_resource(JabberBuddy *jb, const char *resource,
    1.97 -		int priority, JabberBuddyState state, const char *status);
    1.98 -void jabber_buddy_resource_free(JabberBuddyResource *jbr);
    1.99 -void jabber_buddy_remove_resource(JabberBuddy *jb, const char *resource);
   1.100 -const char *jabber_buddy_get_status_msg(JabberBuddy *jb);
   1.101 -void jabber_buddy_get_info(PurpleConnection *gc, const char *who);
   1.102 -
   1.103 -GList *jabber_blist_node_menu(PurpleBlistNode *node);
   1.104 -
   1.105 -void jabber_set_info(PurpleConnection *gc, const char *info);
   1.106 -void jabber_setup_set_info(PurplePluginAction *action);
   1.107 -void jabber_set_buddy_icon(PurpleConnection *gc, PurpleStoredImage *img);
   1.108 -void jabber_buddy_avatar_update_metadata(JabberStream *js, const char *from, xmlnode *items);
   1.109 -
   1.110 -const char *jabber_buddy_state_get_name(JabberBuddyState state);
   1.111 -const char *jabber_buddy_state_get_status_id(JabberBuddyState state);
   1.112 -const char *jabber_buddy_state_get_show(JabberBuddyState state);
   1.113 -JabberBuddyState jabber_buddy_status_id_get_state(const char *id);
   1.114 -JabberBuddyState jabber_buddy_show_get_state(const char *id);
   1.115 -
   1.116 -void jabber_user_search(JabberStream *js, const char *directory);
   1.117 -void jabber_user_search_begin(PurplePluginAction *);
   1.118 -
   1.119 -void jabber_buddy_remove_all_pending_buddy_info_requests(JabberStream *js);
   1.120 -
   1.121 -void jabber_vcard_fetch_mine(JabberStream *js);
   1.122 -
   1.123 -gboolean jabber_resource_has_capability(const JabberBuddyResource *jbr,
   1.124 -										const gchar *cap);
   1.125 -gboolean jabber_buddy_has_capability(const JabberBuddy *jb, const gchar *cap);
   1.126 -
   1.127 -#endif /* _PURPLE_JABBER_BUDDY_H_ */