mark PurpleImageClass as private
[pidgin-git.git] / libpurple / protocols / novell / nmconference.h
blob919cd97f12076c8c80a3ca66271a03b80306540b
1 /*
2 * nmconference.h
4 * Copyright (c) 2004 Novell, Inc. All Rights Reserved.
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; version 2 of the License.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
21 #ifndef PURPLE_NOVELL_NMCONFERENCE_H
22 #define PURPLE_NOVELL_NMCONFERENCE_H
24 typedef struct _NMConference NMConference;
26 #include "nmuserrecord.h"
28 /* A blank GUID -- represents an uninstatiated conference */
29 #define BLANK_GUID "[00000000-00000000-00000000-0000-0000]"
31 /* This is how much of the conference GUIDs to compare when testing
32 * to see if two conferences are the same. We cannot compare the
33 * entire GUID because the last part is the session count.
35 #define CONF_GUID_END 27
37 /**
38 * Creates an conference object.
40 * The conference should be released by calling
41 * nm_release_conference
43 * @param guid The GUID for the conference.
45 * @return The new NMConference
47 NMConference *nm_create_conference(const char *guid);
49 /**
50 * Increments the reference count for the conference.
52 * The reference to the conference should be released
53 * by calling nm_release_conference
55 * @param conference The conference to reference
57 void nm_conference_add_ref(NMConference * conference);
59 /**
60 * Releases the resources associated with the conference
61 * if there are no more references to it, otherwise just
62 * decrements the reference count.
64 * @param conf The conference to release
67 void nm_release_conference(NMConference * conf);
69 /**
70 * Set the GUID for the conference.
72 * @param conference The conference
73 * @param guid The new conference GUID
76 void nm_conference_set_guid(NMConference * conference, const char *guid);
78 /**
79 * Return the GUID for the conference.
81 * @param conference The conference
83 * @return The GUID for the conference
85 const char *nm_conference_get_guid(NMConference * conference);
87 /**
88 * Add a participant to the conference.
90 * @param conference The conference
91 * @param user_record The user record to add as a participant
93 * @return
95 void nm_conference_add_participant(NMConference * conference,
96 NMUserRecord * user_record);
98 /**
99 * Remove a participant to the conference.
101 * @param conference The conference
102 * @param dn The dn of the participant to remove
105 void nm_conference_remove_participant(NMConference * conference, const char *dn);
108 * Return the total number of participants in the conference.
110 * @param conference The conference
112 * @return The number of participants for the conference
115 int nm_conference_get_participant_count(NMConference * conference);
118 * Return a participant given an index.
120 * @param conference The conference
121 * @param index The index of the participant to get
123 * @return The participant or NULL if the index is out of range.
126 NMUserRecord *nm_conference_get_participant(NMConference * conference, int index);
129 * Check to see if the conference has been instantiated
131 * @param conference The conference
133 * @return TRUE if the conference has been instantiated,
134 * FALSE otherwise.
137 gboolean nm_conference_is_instantiated(NMConference * conf);
140 * Set the flags for the conference.
142 * @param conference The conference
143 * @param flags The conference flags.
146 void nm_conference_set_flags(NMConference * conference, guint32 flags);
149 * Set the user defined data for the conference.
151 * @param conference The conference
152 * @param data User defined data
155 void nm_conference_set_data(NMConference * conference, gpointer data);
158 * Get the user defined data for the conference.
160 * @param conference The conference
162 * @return The data if it has been set, NULL otherwise.
165 gpointer nm_conference_get_data(NMConference * conference);
167 #endif /* PURPLE_NOVELL_NMCONFERENCE_H */