libyui-ncurses-pkg
 
Loading...
Searching...
No Matches
NCPkgSelMapper.h
1/*
2 Copyright (c) 2002-2011 Novell, Inc.
3 Copyright (c) 2021 SUSE LLC
4
5 This library is free software; you can redistribute it and/or modify
6 it under the terms of the GNU Lesser General Public License as
7 published by the Free Software Foundation; either version 2.1 of the
8 License, or (at your option) version 3.0 of the License. This library
9 is distributed in the hope that it will be useful, but WITHOUT ANY
10 WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
12 License for more details. You should have received a copy of the GNU
13 Lesser General Public License along with this library; if not, write
14 to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
15 Floor, Boston, MA 02110-1301 USA
16
17
18 File: NCPkgSelMapper.h
19 Author: Stefan Hundhammer <shundhammer@suse.de>
20
21*/
22
23
24#ifndef NCPkgSelMapper_h
25#define NCPkgSelMapper_h
26
27#include "NCZypp.h"
28#include <map>
29
30
31
39{
40public:
41
46
51 virtual ~NCPkgSelMapper();
52
57
58 ZyppSel findZyppSel( ZyppPkg pkg );
59
64 static int refCount() { return _refCount; }
65
73 void rebuildCache();
74
75
76protected:
77
78 typedef std::map<ZyppPkg, ZyppSel> Cache;
79 typedef std::pair<ZyppPkg, ZyppSel> CachePair;
80 typedef Cache::iterator CacheIterator;
81
82 static int _refCount;
83 static Cache _cache;
84};
85
86
87
88#endif // NCPkgSelMapper_h
ZyppSel findZyppSel(ZyppPkg pkg)
Definition NCPkgSelMapper.cc:94
NCPkgSelMapper()
Definition NCPkgSelMapper.cc:37
virtual ~NCPkgSelMapper()
Definition NCPkgSelMapper.cc:44
void rebuildCache()
Definition NCPkgSelMapper.cc:54
static int refCount()
Definition NCPkgSelMapper.h:64