30 #include <fast_methods/utils/utils.h>
36 friend std::ostream& operator << (std::ostream & os,
Cell & c);
44 virtual inline void setValue(
double v) {
value_ = v;}
45 virtual inline void setOccupancy(
double o) {
occupancy_ = o;}
46 virtual std::string type() {
return std::string(
"Cell - Basic cell");}
47 virtual inline void setIndex(
int i) {
index_ = i;}
53 virtual inline double getValue()
const {
return value_;}
54 virtual inline double getOccupancy()
const {
return occupancy_;}
55 virtual inline unsigned int getIndex()
const {
return index_;}
57 virtual inline bool isOccupied()
const {
virtual void setDefault()
Sets default values for the cell. Concretely, restarts value_ = -1 but occupancy_ is not modified...
double occupancy_
Binary occupancy, true means clear, false occupied.
static constexpr double COMP_MARGIN
When comparing doubles if(a < b), do if(a+COMP_MARGIN < b) to avoid double precission issues...
double value_
Value of the cell.
Cell()
Default constructor: sets value_ to -1 and occupancy_ to true (clear cell, not occupied).