6 * Purple is the legal property of its developers, whose names are too numerous
7 * to list here. Please refer to the COPYRIGHT file distributed with this
10 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
20 * You should have received a copy of the GNU General Public License
21 * along with this program; if not, write to the Free Software
22 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
25 #ifndef PURPLE_JABBER_JINGLE_TRANSPORT_H
26 #define PURPLE_JABBER_JINGLE_TRANSPORT_H
29 #include <glib-object.h>
36 #define JINGLE_TYPE_TRANSPORT jingle_transport_get_type()
38 typedef struct _JingleTransport JingleTransport
;
40 /** The transport class */
41 struct _JingleTransportClass
43 GObjectClass parent_class
; /**< The parent class. */
45 const gchar
*transport_type
;
46 PurpleXmlNode
*(*to_xml
) (JingleTransport
*transport
, PurpleXmlNode
*content
, JingleActionType action
);
47 JingleTransport
*(*parse
) (PurpleXmlNode
*transport
);
48 void (*add_local_candidate
) (JingleTransport
*transport
, const gchar
*id
, guint generation
, PurpleMediaCandidate
*candidate
);
49 GList
*(*get_remote_candidates
) (JingleTransport
*transport
);
53 * Gets the transport class's GType
55 * @return The transport class's GType.
58 G_DECLARE_DERIVABLE_TYPE(JingleTransport
, jingle_transport
, JINGLE
, TRANSPORT
,
62 * Registers the JingleTransport type in the type system.
64 void jingle_transport_register(PurplePlugin
*plugin
);
66 JingleTransport
*jingle_transport_create(const gchar
*type
);
67 const gchar
*jingle_transport_get_transport_type(JingleTransport
*transport
);
69 void jingle_transport_add_local_candidate(JingleTransport
*transport
, const gchar
*id
, guint generation
, PurpleMediaCandidate
*candidate
);
70 GList
*jingle_transport_get_remote_candidates(JingleTransport
*transport
);
72 JingleTransport
*jingle_transport_parse(PurpleXmlNode
*transport
);
73 PurpleXmlNode
*jingle_transport_to_xml(JingleTransport
*transport
, PurpleXmlNode
*content
, JingleActionType action
);
77 #endif /* PURPLE_JABBER_JINGLE_TRANSPORT_H */