Bitstream Interpretation Library (BIL)
0.1
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
configuration
V5AddressLayoutRegistry.hpp
Go to the documentation of this file.
1
6
#pragma once
7
#ifndef BIL_V5ADDRESSLAYOUTREGISTRY_HPP
8
#define BIL_V5ADDRESSLAYOUTREGISTRY_HPP
9
10
#include <cstring>
11
#include <map>
12
#include <utility>
13
#include <
configuration/V5AddressLayout.hpp
>
14
#include <
deviceinfo/DeviceID.hpp
>
15
16
17
namespace
bil {
18
26
class
V5AddressLayoutRegistry
{
27
public
:
28
29
/**********************************************************************/
30
/* CONSTRUCTION / DESTRUCTION */
31
/**********************************************************************/
32
36
V5AddressLayoutRegistry
();
37
38
39
/**********************************************************************/
40
/* MODIFIERS */
41
/**********************************************************************/
42
49
void
insert
(
DeviceID::ID_t
deviceID,
const
V5AddressLayout
& layout);
50
56
bool
erase
(
DeviceID::ID_t
deviceID);
57
61
void
clear
();
62
63
64
/**********************************************************************/
65
/* CONTENT ITERATION */
66
/**********************************************************************/
67
72
size_t
size
()
const
;
73
75
typedef
std::pair<const DeviceID::ID_t, V5AddressLayout>
pair_t
;
76
83
pair_t
&
at
(
size_t
index);
84
91
const
pair_t
&
at
(
size_t
index)
const
;
92
93
94
/**********************************************************************/
95
/* ADDRESS LAYOUT LOOKUP */
96
/**********************************************************************/
97
104
V5AddressLayout
*
lookup
(
DeviceID::ID_t
deviceID);
105
112
const
V5AddressLayout
*
lookup
(
DeviceID::ID_t
deviceID)
const
;
113
114
115
private
:
116
117
typedef
std::map<DeviceID::ID_t, V5AddressLayout> IDMap_t;
118
IDMap_t m_idMap;
119
120
};
121
122
}
123
124
#endif
Generated on Wed Aug 8 2012 21:57:40 for Bitstream Interpretation Library (BIL) by
1.8.1.1