Skip to content
Snippets Groups Projects
Commit 8b28f969 authored by Joan Solà Ortega's avatar Joan Solà Ortega
Browse files

Add HasStateBlocks::getStateBlockVec()

parent 3cc47101
No related branches found
No related tags found
1 merge request!323Resolve "New data structure for storing stateblocks"
Pipeline #4705 passed
This commit is part of merge request !323. Comments created here will be created in the context of that merge request.
...@@ -27,6 +27,15 @@ class HasStateBlocks ...@@ -27,6 +27,15 @@ class HasStateBlocks
void appendToStructure(const std::string& _frame_type){structure_ += _frame_type;} void appendToStructure(const std::string& _frame_type){structure_ += _frame_type;}
const std::map<std::string, StateBlockPtr>& getStateBlockMap() const; const std::map<std::string, StateBlockPtr>& getStateBlockMap() const;
std::map<std::string, StateBlockPtr>& getStateBlockMap(); std::map<std::string, StateBlockPtr>& getStateBlockMap();
std::vector<StateBlockPtr> getStateBlockVec() const
{
std::vector<StateBlockPtr> sbv;
for (auto& key : structure_)
{
sbv.push_back(getStateBlock(key));
}
return sbv;
}
public: public:
// Some typical shortcuts -- not all should be coded here, see notes below. // Some typical shortcuts -- not all should be coded here, see notes below.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment