49template <
class K,
class T,
class C,
class A,
class Predicate>
53 for(
auto i =
c.begin(),
last =
c.end(); i !=
last;)
85 std::pair<std::map<std::size_t, Bucket>::iterator,
bool> ret;
87 if(ret.second ==
false)
94 ret.first->second.push_back(spectrum_int.
getId());
108 std::vector<Bucket> bucketList;
114 if(map_pair.second.size() > 1)
115 bucketList.push_back(map_pair.second);
119 std::sort(bucketList.begin(), bucketList.end());
127 std::size_t spectrum_idx_end)
130 qDebug() <<
"spectrum_idx_begin=" << spectrum_idx_begin
131 <<
" spectrum_idx_end=" << spectrum_idx_end;
133 return ((item.second.front() >= spectrum_idx_begin) &&
134 (item.second.back() <= spectrum_idx_end));
std::size_t m_itemCartCount
void addItemCart(const ItemCart &item_cart)
add ItemCart to Bucket list Each item in the cart is a key to build dedicated buckets for one item Th...
std::vector< Bucket > asSortedList() const
std::size_t getItemCartCount() const
std::map< std::size_t, Bucket > m_bucketMap
void removeBucketsWithinCartIdRange(std::size_t spectrum_idx_begin, std::size_t spectrum_idx_end)
removes buckets only showing intra relations in the spectrum index range
container for spectree items
const std::vector< std::size_t > & getItemList() const
std::size_t getId() const
void erase_if(std::map< K, T, C, A > &c, Predicate pred)
tries to keep as much as possible monoisotopes, removing any possible C13 peaks and changes multichar...