Revision 102, 0.8 KB
(checked in by bhilburn, 15 years ago)
|
Added the containers.h header to export commonly-used data container structs.
|
Rev | Line | |
---|
[102] | 1 | /* Virginia Tech Cognitive Radio Open Source Systems |
---|
| 2 | * Virginia Tech, 2009 |
---|
| 3 | * |
---|
| 4 | * LICENSE INFORMATION GOES HERE |
---|
| 5 | * |
---|
| 6 | */ |
---|
| 7 | |
---|
| 8 | #ifdef GCC_EXPERIMENTAL |
---|
| 9 | #include <cstdint> |
---|
| 10 | #else |
---|
| 11 | #include <stdint.h> |
---|
| 12 | #endif |
---|
| 13 | |
---|
| 14 | using namespace std; |
---|
| 15 | |
---|
| 16 | struct CE_Info { |
---|
| 17 | uint32_t numUtilities; |
---|
| 18 | uint32_t numParameters; |
---|
| 19 | uint32_t numObservables; |
---|
| 20 | uint32_t policy_engine; |
---|
| 21 | uint32_t policy_socket; |
---|
| 22 | uint32_t ce_socket; |
---|
| 23 | }; |
---|
| 24 | |
---|
| 25 | struct Utility { |
---|
| 26 | string name; |
---|
| 27 | string units; |
---|
| 28 | string goal; |
---|
| 29 | float target; |
---|
| 30 | float value; |
---|
| 31 | }; |
---|
| 32 | |
---|
| 33 | struct Affect { |
---|
| 34 | Utility *u; |
---|
| 35 | string relation; |
---|
| 36 | }; |
---|
| 37 | |
---|
| 38 | struct Parameter { |
---|
| 39 | string name; |
---|
| 40 | string units; |
---|
| 41 | float min; |
---|
| 42 | uint32_t numAffects; |
---|
| 43 | Affect affection_list[10]; |
---|
| 44 | float max; |
---|
| 45 | float step; |
---|
| 46 | float value; |
---|
| 47 | }; |
---|
| 48 | |
---|
| 49 | struct Observable { |
---|
| 50 | string name; |
---|
| 51 | Affect affection_list[10]; |
---|
| 52 | uint32_t numAffects; |
---|
| 53 | float value; |
---|
| 54 | }; |
---|
| 55 | |
---|
| 56 | |
---|