Skip to content
Snippets Groups Projects

Resolve "New data structure for storing stateblocks"

Merged Joan Solà Ortega requested to merge 256-new-data-structure-for-storing-stateblocks into devel
1 file
+ 10
1
Compare changes
  • Side-by-side
  • Inline
@@ -44,13 +44,22 @@ class HasStateBlocks
void unfix();
bool isFixed() const;
protected:
public:
StateBlockPtr setStateBlock(const std::string& _sb_type, const StateBlockPtr& _sb);
StateBlockPtr setStateBlock(const char& _sb_type, const StateBlockPtr& _sb)
{
return setStateBlock(std::string(1,_sb_type), _sb);
}
StateBlockPtr getStateBlock(const std::string& _sb_type) const;
StateBlockPtr getStateBlock(const char& _sb_type) const {return getStateBlock(std::string(1,_sb_type));}
unsigned int removeStateBlock(const std::string& _sb_type)
{
return state_block_map_.erase(_sb_type);
}
unsigned int removeStateBlock(const char& _sb_type)
{
return removeStateBlock(std::string(1,_sb_type));
}
// Emplace derived state blocks (angle, quaternion, etc).
template<typename SB, typename ... Args>
Loading