minor improvements: variable names, comments

This commit is contained in:
Robert Haschke 2018-04-09 17:36:26 +02:00
parent 564f3b0514
commit 51e1dda6ec
3 changed files with 5 additions and 5 deletions

View File

@ -106,7 +106,7 @@ public:
InterfaceState(const planning_scene::PlanningSceneConstPtr& ps);
/// copy an existing InterfaceState, but not including incoming/outgoing trajectories
InterfaceState(const InterfaceState& existing);
InterfaceState(const InterfaceState& other);
inline const planning_scene::PlanningSceneConstPtr& scene() const { return scene_; }
inline const Solutions& incomingTrajectories() const { return incoming_trajectories_; }

View File

@ -867,7 +867,7 @@ void ParallelContainerBase::spawn(InterfaceState &&state, SubTrajectory&& t)
it->setEndState(*state_it);
impl->failures_.push_back(&*it);
} else {
// directly spawn states in push interfaces
// directly spawn states into push interfaces
impl->prevEnds()->add(InterfaceState(state), NULL, &*it);
impl->nextStarts()->add(std::move(state), &*it, NULL);
impl->solutions_.insert(&*it);

View File

@ -50,8 +50,8 @@ InterfaceState::InterfaceState(const planning_scene::PlanningSceneConstPtr &ps)
{
}
InterfaceState::InterfaceState(const InterfaceState &existing)
: scene_(existing.scene_), properties_(existing.properties_)
InterfaceState::InterfaceState(const InterfaceState &other)
: scene_(other.scene_), properties_(other.properties_)
{
}
@ -69,7 +69,7 @@ Interface::iterator Interface::add(InterfaceState &&state, SolutionBase* incomin
// move state to a list node
std::list<InterfaceState> container;
auto it = container.insert(container.end(), std::move(state));
assert(it->owner_ == nullptr);
assert(it->owner_ == nullptr); // state can only be added once to an interface
it->owner_ = this;
// configure state: inherit priority from other end's state and add current solution's cost