Bitstream Interpretation Library (BIL)
0.1
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
packetprocessor
Register.cpp
Go to the documentation of this file.
1
6
#include <
packetprocessor/Register.hpp
>
7
#include <
exception/Exception.hpp
>
8
9
using namespace
bil;
10
11
12
Register::Register
(
RegisterAddress::address_t
address,
const
std::string& name,
bool
writable,
bool
readable):
13
m_name(name),
14
m_address(address),
15
m_writable(writable),
16
m_readable(readable)
17
{
18
19
}
20
21
22
Register::~Register
()
23
{
24
25
}
26
27
28
RegisterAddress::address_t
Register::address
()
const
29
{
30
return
m_address;
31
}
32
33
34
const
std::string&
Register::name
()
const
35
{
36
return
m_name;
37
}
38
39
40
bool
Register::writable
()
const
41
{
42
return
m_writable;
43
}
44
45
46
bool
Register::readable
()
const
47
{
48
return
m_readable;
49
}
50
51
52
void
Register::write
(
const
boost::uint32_t*,
size_t
)
53
{
54
if
(!m_writable)
throw
Exception
();
55
}
56
57
58
void
Register::read
(boost::uint32_t*,
size_t
)
const
59
{
60
if
(!m_readable)
throw
Exception
();
61
}
Generated on Wed Aug 8 2012 21:57:40 for Bitstream Interpretation Library (BIL) by
1.8.1.1