return list<string>();
}
-SimpleSPGoal::SimpleSPGoal(std::string to):_to(to){
+SimpleSPGoal::SimpleSPGoal(const std::string& to, int limit):_to(to), _limit(limit){
}
int SimpleSPGoal::operator()(const SPInfo* node) const{
+ if (_limit > 0 && node->cost >= _limit)
+ return -1;
if (node->name == _to)
return 1;
return 0;