summaryrefslogtreecommitdiffstats
path: root/xbmc/addons/PluginSource.h
diff options
context:
space:
mode:
Diffstat (limited to 'xbmc/addons/PluginSource.h')
-rw-r--r--xbmc/addons/PluginSource.h58
1 files changed, 0 insertions, 58 deletions
diff --git a/xbmc/addons/PluginSource.h b/xbmc/addons/PluginSource.h
deleted file mode 100644
index 87e1f34..0000000
--- a/xbmc/addons/PluginSource.h
+++ /dev/null
@@ -1,58 +0,0 @@
1/*
2 * Copyright (C) 2005-2013 Team XBMC
3 * http://xbmc.org
4 *
5 * This Program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2, or (at your option)
8 * any later version.
9 *
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.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with XBMC; see the file COPYING. If not, see
17 * <http://www.gnu.org/licenses/>.
18 *
19 */
20#pragma once
21
22#include "Addon.h"
23
24namespace ADDON
25{
26
27class CPluginSource : public CAddon
28{
29public:
30
31 enum Content { UNKNOWN, AUDIO, IMAGE, EXECUTABLE, VIDEO };
32
33 CPluginSource(const cp_extension_t *ext);
34 CPluginSource(const AddonProps &props);
35 virtual ~CPluginSource() {}
36 virtual AddonPtr Clone() const;
37 virtual bool IsType(TYPE type) const;
38 bool Provides(const Content& content) const
39 {
40 return content == UNKNOWN ? false : m_providedContent.count(content) > 0;
41 }
42
43 bool ProvidesSeveral() const
44 {
45 return m_providedContent.size() > 1;
46 }
47
48 static Content Translate(const std::string &content);
49private:
50 /*! \brief Set the provided content for this plugin
51 If no valid content types are passed in, we set the EXECUTABLE type
52 \param content a space-separated list of content types
53 */
54 void SetProvides(const std::string &content);
55 std::set<Content> m_providedContent;
56};
57
58} /*namespace ADDON*/