00001 // 00002 // EvalCase.hpp 00003 // 00004 // Created on: 05.09.2011 00005 // Author: wahnfla 00006 // 00007 00008 #ifndef EVALCASE_HPP 00009 #define EVALCASE_HPP 00010 00011 #include "../BasicDatatypes.hpp" 00012 #include <vector> 00013 00014 namespace datatypes 00015 { 00016 00017 // 00018 // The parameters of an EvalCase. This *is* an EvalCase. 00019 // 00020 class EvalCase : public BasicData 00021 { 00022 public: 00023 enum EvaluationStrategy 00024 { 00025 BLANKING = 0, 00026 PIXEL = 1, 00027 CONTOUR = 2, 00028 IO_MAPPING = 3, 00029 FOCALPOSITION = 4 00030 }; 00031 00032 static std::string strategyToString(EvaluationStrategy strategy) 00033 { 00034 switch (strategy) 00035 { 00036 case BLANKING: 00037 return "BLANKING"; 00038 case PIXEL: 00039 return "PIXEL"; 00040 case CONTOUR: 00041 return "CONTOUR"; 00042 case IO_MAPPING: 00043 return "IO_MAPPING"; 00044 case FOCALPOSITION: 00045 return "FOCALPOSITION"; 00046 } 00047 return ""; 00048 } 00049 00050 enum InputState 00051 { 00052 INPUT_INACTIVE = 0, 00053 INPUT_LOW_ACTIVE = 1, 00054 INPUT_HIGH_ACTIVE = 2 00055 }; 00056 00058 enum ManipulationPrevention 00059 { 00060 ECS_INACTIVE = 0, 00061 ECS_ACTIVE = 1 00062 }; 00063 00065 enum FilterType 00066 { 00067 UNFILTERED = 0 00068 }; 00069 00070 // typedef std::vector<InputState> InputStateVector; 00071 00072 EvalCase(); 00073 00074 virtual ~EvalCase(); 00075 00076 virtual const UINT32 getUsedMemory() const; 00077 double getBlankingSize() const; 00078 const std::string& getCaseName() const; 00079 UINT8 getCaseNumber() const; 00080 const std::string& getComment() const; 00081 UINT16 getFieldNumber() const; 00082 FilterType getFilterType() const; 00083 // const InputStateVector& getHardwareInputs() const; 00084 const UINT8 getLogicalInputState_as_UINT8() const; 00085 double getMaxRadialCorridor() const; 00086 double getMinFieldExp() const; 00087 UINT8 getOutputNumber() const; 00088 UINT32 getResponseTime() const; 00089 UINT32 getResponseTimeExtended() const; 00090 EvaluationStrategy getStrategy() const; 00091 // UINT8 getStrategy() const; 00092 UINT32 getVersionNumberIntern() const; 00093 bool isDistDependent() const; 00094 bool isResultNegation() const; 00095 void setBlankingSize(double blankingSize); 00096 void setCaseName(const std::string& caseName); 00097 void setCaseNumber(UINT8 caseNumber); 00098 void setComment(const std::string& comment); 00099 void setDistDependent(bool distDependent); 00100 bool getDistDependent(); 00101 void setFieldNumber(UINT16 fieldNumber); 00102 void setFilterType(FilterType filterType); 00103 // void setHardwareInputs(const InputStateVector& hardwareInputs); 00104 // void setLogicalInputs(const InputStateVector& logicalInputs); 00105 void setMaxRadialCorridor(double maxRadialCorridor); 00106 void setMinFieldExp(double minFieldExp); 00107 void setOutputNumber(UINT8 outputNumber); 00108 void setResponseTime(UINT32 responseTime); 00109 void setResponseTimeExtended(UINT32 responseTimeExtended); 00110 void setResultNegation(bool resultNegation); 00111 bool getResultNegation(); 00112 void setStrategy(EvaluationStrategy strategy); 00113 void setVersionNumber(UINT16 versionNumber); 00114 UINT16 getVersionNumber(); 00115 00116 void setLogicalInputState_from_UINT8(UINT8 value); 00117 ManipulationPrevention getManipulationPrevention() const; 00118 void setManipulationPrevention(ManipulationPrevention manPrev); 00119 00120 private: 00121 InputState m_logicalInputState[2]; // two inputs 00122 UINT16 m_versionNumberIntern; 00123 UINT8 m_caseNumber; 00124 EvaluationStrategy m_strategy; 00125 bool m_resultNegation; 00126 UINT32 m_responseTime; 00127 UINT32 m_responseTimeExtended; 00128 UINT16 m_outputNumber; 00129 // InputStateVector m_hardwareInputs; 00130 // InputStateVector m_logicalInputs; 00131 bool m_distDependent; 00132 double m_maxRadialCorridor; 00133 ManipulationPrevention m_manipulationPrevention; 00134 double m_blankingSize; 00135 double m_minFieldExp; 00136 UINT16 m_fieldNumber; 00137 FilterType m_filterType; 00138 std::string m_caseName; 00139 std::string m_comment; 00140 }; 00141 00142 00143 } // namespace datatypes 00144 00145 #endif // EVALCASE_HPP