gloox  1.0.28
jinglepluginfactory.h
1 /*
2  Copyright (c) 2013-2023 by Jakob Schröter <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 JINGLEPLUGINFACTORY_H__
15 #define JINGLEPLUGINFACTORY_H__
16 
17 #include "jingleplugin.h"
18 #include "jinglesession.h"
19 
20 namespace gloox
21 {
22 
23  class Tag;
24 
25  namespace Jingle
26  {
27 
37  {
38  friend class SessionManager;
39 
40  public:
44  virtual ~PluginFactory();
45 
50  void registerPlugin( Plugin* plugin );
51 
58  void addPlugins( Plugin& plugin, const Tag* tag );
59 
66  void addPlugins( Session::Jingle& jingle, const Tag* tag );
67 
68  private:
72  PluginFactory();
73 
74  PluginList m_plugins;
75 
76  };
77 
78  }
79 
80 }
81 
82 #endif // JINGLEPLUGINFACTORY_H__
A factory for which creates Plugin instances based on Tags. This is part of Jingle (XEP-0166).
void addPlugins(Plugin &plugin, const Tag *tag)
void registerPlugin(Plugin *plugin)
An abstraction of a Jingle plugin. This is part of Jingle (XEP-0166 et al.)
Definition: jingleplugin.h:68
The SessionManager is responsible for creating and destroying Jingle sessions, as well as for delegat...
This is an abstraction of Jingle's (XEP-0166) <jingle> element as a StanzaExtension.
This is an abstraction of an XML element.
Definition: tag.h:47
std::list< const Plugin * > PluginList
Definition: jingleplugin.h:52
The namespace for the gloox library.
Definition: adhoc.cpp:28