100 virtual std::vector<std::shared_ptr<Action>>
actions(std::shared_ptr<State> state) = 0;
Represents an abstract action that can be performed on a state.
std::shared_ptr< State > effect
std::shared_ptr< State > source_state
Action(const std::string &name, double cost, std::shared_ptr< State > source_state, std::shared_ptr< State > effect)
Represents an abstract problem that needs to be solved.
virtual bool goal_test(State *state)=0
Tests if a given state satisfies the goal condition.
virtual double heuristic(State *state)=0
Computes a heuristic estimate for a given state.
virtual std::vector< std::shared_ptr< Action > > actions(std::shared_ptr< State > state)=0
Retrieves the set of actions applicable to a given state.
virtual State * initial_state()
Retrieves the initial state of the problem.
State * initial_state_
Pointer to the initial state of the problem.
Problem()
Constructor for the Problem class.
virtual ~Problem()
Virtual destructor for the Problem class.
Represents an abstract state in a problem.
virtual void print()
Prints the state details.
virtual ~State()
Virtual destructor for the State class.
State()
Constructor for the State class.