memgraph/include/storage/label/label_collection.hpp
Kruno Tomola Fabro 77a3298d1e tmp
2016-08-28 15:47:13 +01:00

32 lines
600 B
C++

#pragma once
#include <vector>
// #include "storage/label/label.hpp"
#include "utils/reference_wrapper.hpp"
class Label;
using label_ref_t = ReferenceWrapper<const Label>;
class LabelCollection
{
public:
auto begin();
auto begin() const;
auto cbegin() const;
auto end();
auto end() const;
auto cend() const;
bool add(const Label &label);
bool has(const Label &label) const;
size_t count() const;
bool remove(const Label &label);
void clear();
const std::vector<label_ref_t> &operator()() const;
private:
std::vector<label_ref_t> _labels;
};