MultiAgentDecisionProcess
Release 0.2.1
Main Page
Namespaces
Classes
Files
File List
File Members
OGet.h
Go to the documentation of this file.
1
28
/* Only include this header file once. */
29
#ifndef _OGET_H_
30
#define _OGET_H_ 1
31
32
/* the include directives */
33
#include "
Globals.h
"
34
35
#include "
ObservationModelMapping.h
"
36
#include "
ObservationModelMappingSparse.h
"
37
39
class
OGet
40
{
41
public
:
42
virtual
~OGet
() = 0;
43
//get (data) functions:
44
virtual
double
Get
(
Index
jaI,
Index
sucSI,
Index
joI)
const
= 0;
45
};
46
47
//http://www.parashift.com/c++-faq-lite/pointers-to-members.html
48
//says "defined even though it's pure virtual; it's faster this way; trust me"
49
inline
OGet::~OGet
() {}
50
53
class
OGet_ObservationModelMapping
:
public
OGet
54
{
55
56
private
:
57
std::vector<ObservationModelMapping::Matrix* >
_m_O
;
58
public
:
59
OGet_ObservationModelMapping
(
ObservationModelMapping
* om)
60
{
61
_m_O
= om->
_m_O
;
62
};
63
64
virtual
double
Get
(
Index
jaI,
Index
sucSI,
Index
joI)
const
65
{ {
return
((*
_m_O
[jaI])(sucSI,joI)); } }
66
67
};
68
71
class
OGet_ObservationModelMappingSparse
:
public
OGet
72
{
73
74
private
:
75
std::vector<ObservationModelMappingSparse::SparseMatrix* >
_m_O
;
76
public
:
77
OGet_ObservationModelMappingSparse
(
ObservationModelMappingSparse
* om)
78
{
79
_m_O
= om->
_m_O
;
80
};
81
82
virtual
double
Get
(
Index
jaI,
Index
sucSI,
Index
joI)
const
83
{ {
return
((*
_m_O
[jaI])(sucSI,joI)); } }
84
85
};
86
87
#endif
/* !_OGET_H_ */
88
89
// Local Variables: ***
90
// mode:c++ ***
91
// End: ***
src
base
OGet.h
Generated on Mon Sep 23 2013 14:50:05 for MultiAgentDecisionProcess by
1.8.1.2