mirror of
https://github.com/cmosher01/Epple-II.git
synced 2024-09-27 07:54:58 +00:00
18 lines
270 B
C++
18 lines
270 B
C++
#ifndef MAGNETICFIELD_H
|
|
#define MAGNETICFIELD_H
|
|
|
|
class MagneticField {
|
|
public:
|
|
bool is_on() const;
|
|
int position() const;
|
|
|
|
void turn_off();
|
|
void turn_on_at(const int position);
|
|
|
|
private:
|
|
bool on = false;
|
|
int pos = 0;
|
|
};
|
|
|
|
#endif // MAGNETICFIELD_H
|