gloox  1.0.9
pubsubitem.h
1 /*
2  Copyright (c) 2005-2013 by Jakob Schroeter <js@camaya.net>
3  This file is part of the gloox library. http://camaya.net/gloox
4 
5  This software is distributed under a license. The full license
6  agreement can be found in the file LICENSE in this distribution.
7  This software may not be copied, modified, sold or distributed
8  other than expressed in the named license agreement.
9 
10  This software is distributed without any warranty.
11 */
12 
13 
14 #ifndef PUBSUBITEM_H__
15 #define PUBSUBITEM_H__
16 
17 #include "gloox.h"
18 
19 #include <string>
20 
21 namespace gloox
22 {
23 
24  class Tag;
25 
26  namespace PubSub
27  {
28 
37  class GLOOX_API Item
38  {
39  public:
43  Item();
44 
49  Item( const Tag* tag );
50 
55  Item( const Item& item );
56 
60  ~Item();
61 
66  const Tag* payload() const { return m_payload; }
67 
72  const std::string& id() const { return m_id; }
73 
78  Tag* tag() const;
79 
80  private:
81  Tag* m_payload;
82  std::string m_id;
83 
84  };
85 
86  }
87 
88 }
89 
90 #endif // PUBSUBITEM_H__