LeechCraft Azoth  %{LEECHCRAFT_VERSION}
Modular multiprotocol IM plugin for LeechCraft
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator
isupportriex.h
Go to the documentation of this file.
1 /**********************************************************************
2  * LeechCraft - modular cross-platform feature rich internet client.
3  * Copyright (C) 2006-2013 Georg Rudoy
4  *
5  * Boost Software License - Version 1.0 - August 17th, 2003
6  *
7  * Permission is hereby granted, free of charge, to any person or organization
8  * obtaining a copy of the software and accompanying documentation covered by
9  * this license (the "Software") to use, reproduce, display, distribute,
10  * execute, and transmit the Software, and to prepare derivative works of the
11  * Software, and to permit third-parties to whom the Software is furnished to
12  * do so, all subject to the following:
13  *
14  * The copyright notices in the Software and this entire statement, including
15  * the above license grant, this restriction and the following disclaimer,
16  * must be included in all copies of the Software, in whole or in part, and
17  * all derivative works of the Software, unless such copies or derivative
18  * works are solely in the form of machine-executable object code generated by
19  * a source language processor.
20  *
21  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22  * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23  * FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
24  * SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
25  * FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
26  * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
27  * DEALINGS IN THE SOFTWARE.
28  **********************************************************************/
29 
30 #ifndef PLUGINS_AZOTH_INTERFACES_ISUPPORTRIEX_H
31 #define PLUGINS_AZOTH_INTERFACES_ISUPPORTRIEX_H
32 #include <QFlags>
33 #include <QMetaType>
34 #include <QStringList>
35 
36 namespace LeechCraft
37 {
38 namespace Azoth
39 {
42  struct RIEXItem
43  {
51  enum Action
52  {
56 
60 
64  } Action_;
65 
78  QString ID_;
79 
84  QString Nick_;
85 
93  QStringList Groups_;
94  };
95 
96  inline bool operator== (const RIEXItem& r1, const RIEXItem& r2)
97  {
98  return r1.Action_ == r2.Action_ &&
99  r1.ID_ == r2.ID_ &&
100  r1.Nick_ == r2.Nick_ &&
101  r1.Groups_ == r2.Groups_;
102  }
103 
112  {
113  public:
114  virtual ~ISupportRIEX () {}
115 
126  virtual void SuggestItems (QList<RIEXItem> items, QObject *entry, QString message) = 0;
127 
145  virtual void riexItemsSuggested (QList<LeechCraft::Azoth::RIEXItem> items,
146  QObject *from, QString message) = 0;
147  };
148 }
149 }
150 
152  "org.Deviant.LeechCraft.Azoth.ISupportRIEX/1.0");
154 
155 #endif
Interface representing Roster Item Exchange-like things.
Definition: isupportriex.h:111
This item should be updated in the roster.
Definition: isupportriex.h:63
Q_DECLARE_METATYPE(LeechCraft::Azoth::State)
bool operator==(const EntryStatus &es1, const EntryStatus &es2)
Definition: iclentry.h:64
This item should be removed from the roster.
Definition: isupportriex.h:59
Q_DECLARE_INTERFACE(LeechCraft::Azoth::IAccount,"org.Deviant.LeechCraft.Azoth.IAccount/1.0")
Represents a single exchange entry.
Definition: isupportriex.h:42
virtual void riexItemsSuggested(QList< LeechCraft::Azoth::RIEXItem > items, QObject *from, QString message)=0
Notifies that other part suggested modifying roster.
QString Nick_
The suggested nickname of the entry.
Definition: isupportriex.h:84
QString ID_
The human-readable ID of the entry.
Definition: isupportriex.h:78
QStringList Groups_
The suggested groups for the entry.
Definition: isupportriex.h:93
Action
What should be done with this item.
Definition: isupportriex.h:51
enum LeechCraft::Azoth::RIEXItem::Action Action_
virtual void SuggestItems(QList< RIEXItem > items, QObject *entry, QString message)=0
Sends exchange request to the given entry.