public void RemoveAttribs(BlockAttribs attribs) { if (!_blockList.ContainsKey(attribs)) { throw new InvalidOperationException("Attribs don't exist"); } _blockList.Remove(attribs); }
public void RemoveBlock(BlockAttribs attribs, RABlock block) { if (!_blockList.ContainsKey(attribs)) { throw new InvalidOperationException("Attribs don't exist"); } if (!_blockList[attribs].Contains(block)) { throw new InvalidOperationException("Block doesn't exist"); } _blockList[attribs].Remove(block); }
public void Add(BlockAttribs attribs, RABlock block) { if (!_blockList.ContainsKey(attribs)) { _blockList.Add(attribs, new List <RABlock>() { block }); } else { _blockList[attribs].Add(block); } }
public BlockAttribs SetPrevAttribs(BlockAttribs attribs) { _prevAttribs = attribs; return(attribs); }