State.h
Go to the documentation of this file.
1 /*
2  * A footstep planner for humanoid robots
3  *
4  * Copyright 2010-2011 Johannes Garimort, Armin Hornung, University of Freiburg
5  * http://www.ros.org/wiki/footstep_planner
6  *
7  *
8  * This program is free software: you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation, version 3.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  */
20 
21 #ifndef FOOTSTEP_PLANNER_STATE_H_
22 #define FOOTSTEP_PLANNER_STATE_H_
23 
25 
26 
27 namespace footstep_planner
28 {
34 class State
35 {
36 public:
37  State();
38  State(double x, double y, double theta, Leg leg);
39  ~State();
40 
41  void setX(double x) { ivX = x; }
42  void setY(double y) { ivY = y; }
43  void setTheta(double theta) { ivTheta = theta; }
44  void setLeg(Leg leg) { ivLeg = leg; }
45 
46  double getX() const { return ivX; }
47  double getY() const { return ivY; };
48  double getTheta() const { return ivTheta; }
49  Leg getLeg() const { return ivLeg; }
50 
55  bool operator ==(const State& s2) const;
56 
61  bool operator !=(const State& s2) const;
62 
63 private:
65  double ivX;
67  double ivY;
69  double ivTheta;
72 };
73 }
74 #endif /* FOOTSTEP_PLANNER_STATE_H_ */
double getTheta() const
Definition: State.h:48
bool operator!=(const State &s2) const
Inequality operator for two states (negates the equality operator).
Definition: State.cpp:53
void setTheta(double theta)
Definition: State.h:43
bool operator==(const State &s2) const
Compare two states on equality of x, y, theta, leg upon a certain degree of float precision...
Definition: State.cpp:41
double getX() const
Definition: State.h:46
A class representing the robot&#39;s pose (i.e. position and orientation) in the (continuous) world view...
Definition: State.h:34
void setY(double y)
Definition: State.h:42
double ivX
The robot&#39;s position in x direction.
Definition: State.h:65
double getY() const
Definition: State.h:47
double ivTheta
The robot&#39;s orientation.
Definition: State.h:69
Leg ivLeg
The robot&#39;s supporting leg.
Definition: State.h:71
double ivY
The robot&#39;s position in y direction.
Definition: State.h:67
void setLeg(Leg leg)
Definition: State.h:44
Leg getLeg() const
Definition: State.h:49
void setX(double x)
Definition: State.h:41


footstep_planner
Author(s): Johannes Garimort, Armin Hornung
autogenerated on Mon Jun 10 2019 13:38:24