| 74 | } |
| 75 | |
| 76 | bool CChannelOrder::AddChannel(stChannelID chan) { |
| 77 | std::size_t index = order_.size(); |
| 78 | if (indices_.try_emplace(chan, index).second) { |
| 79 | order_.push_back(chan); |
| 80 | return true; |
| 81 | } |
| 82 | return false; |
| 83 | } |
| 84 | |
| 85 | bool CChannelOrder::RemoveChannel(stChannelID chan) { |
| 86 | if (auto it = indices_.find(chan); it != indices_.end()) { |
no test coverage detected