You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

47 lines
833 B

//
// Created by cflin on 4/7/23.
//
#ifndef RIGIDIPC_SIMTARGETOPTION_H
#define RIGIDIPC_SIMTARGETOPTION_H
namespace ssim {
class SimTargetOption {
public:
static const int NUM_TARGETS = 10;
enum Target{
U_NORM = 0,S_NORM, S_X, S_Y, S_Z
};
SimTargetOption(int init_state=0) : state(init_state) {}
void set_option(int option) {
state |= (1 << option);
}
void unset_option(int option) {
state &= ~(1 << option);
}
bool is_option_set(int option) const {
return state & (1 << option);
}
void clear() {
state = 0;
}
void set() {
state = INT_MAX;
}
private:
int state;
};
} // ssim
#endif //RIGIDIPC_SIMTARGETOPTION_H