GLStats  0.3.3
data.h
1 
2 /* Copyright (c) 2012-2013, Stefan Eilemann <eile@eyescale.ch>
3  *
4  * This library is free software; you can redistribute it and/or modify it under
5  * the terms of the GNU Lesser General Public License version 2.1 as published
6  * by the Free Software Foundation.
7  *
8  * This library is distributed in the hope that it will be useful, but WITHOUT
9  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
10  * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
11  * details.
12  *
13  * You should have received a copy of the GNU Lesser General Public License
14  * along with this library; if not, write to the Free Software Foundation, Inc.,
15  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
16  */
17 
18 #ifndef GLSTATS_DATA_H
19 #define GLSTATS_DATA_H
20 
21 #include <GLStats/api.h>
22 #include <GLStats/types.h>
23 
24 namespace GLStats
25 {
26 namespace detail
27 {
28 class Data;
29 }
30 
32 class Data
33 {
34 public:
36  GLSTATS_API Data();
37 
39  GLSTATS_API Data(const Data& from);
40 
42  GLSTATS_API virtual ~Data();
43 
45  GLSTATS_API void setEntity(const uint32_t identifier, const Entity& entity);
46 
48  const Entity& getEntity(const uint32_t identifier) const;
49 
51  GLSTATS_API void setThread(const uint32_t identifier, const Thread& thread);
52 
54  const Thread& getThread(const uint32_t identifier) const;
55 
57  GLSTATS_API void setType(const uint32_t identifier, const Type& type);
58 
60  const Type& getType(const uint32_t identifier) const;
61 
63  GLSTATS_API const TypeMap& getTypes() const;
64 
66  GLSTATS_API void addItem(const Item& item);
67 
69  GLSTATS_API const Items& getItems() const;
70 
72  GLSTATS_API uint128_t computeMinMax() const;
73 
75  GLSTATS_API void setText(const std::string& text);
76 
78  GLSTATS_API const std::string& getText() const;
79 
81  GLSTATS_API void obsolete(const uint32_t nFrames);
82 
84  GLSTATS_API void clear();
85 
86 private:
87  detail::Data* const impl_;
88 };
89 }
90 
91 #endif // GLSTATS_DATA_H
Defines export visibility macros for library GLStats.
One statistics type.
Definition: type.h:26
The data storage.
Definition: data.h:32
Basic type definitions not provided by the operating system.
Definition: data.h:24
One statistics item.
Definition: item.h:27
One statistics entity.
Definition: entity.h:26
One statistics thread.
Definition: thread.h:26