1 #ifndef GRAIL_WORLD_STATE_H
2 #define GRAIL_WORLD_STATE_H
6 #include "WorldObject.hh"
7 #include "../Domain.hh"
18 const std::vector<WorldObject>& worldObjects);
26 bool operator==(
const WorldState& other)
const;
28 std::vector<class Action> GetLegalActions()
const;
29 std::vector<std::vector<unsigned int>> GenerateParameterLists(
30 const std::vector<std::vector<unsigned int>>& precedingParameterLists,
31 unsigned int searchedTypeIndex)
const;
33 const WorldObject* GetObjectByIndex(
unsigned int index)
const;
35 const std::map<unsigned int, WorldObject>& GetObjectMap()
const;
36 std::shared_ptr<Domain> GetDomain()
const;
38 WorldObject& AddObject(
const std::string& typeName);
43 void AddQueuedObjects();
44 void RemoveQueuedObjects();
47 std::vector<const WorldObject*>
GetObjectsOfType(
const std::string& typeName)
const;
56 std::shared_ptr<Domain> domain =
nullptr;
57 std::map<unsigned int, WorldObject> objects{};
58 std::vector<WorldObject> objectsToAdd{};
62 std::vector<unsigned int> indicesToRemove{};
63 unsigned int nextIndex = 0;
67 #endif //GRAIL_WORLD_STATE_H