memgraph/src/storage/vertex.hpp
florijan 463e86653d Vertex and Edge distributed storage support
Summary: Vertex and Edge now use Address for storing connections to other Edges and Vertices, to support distributed storage.

Reviewers: mislav.bradac, dgleich, buda

Reviewed By: mislav.bradac, dgleich

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D977
2017-11-14 15:18:06 +01:00

30 lines
791 B
C++

#pragma once
#include "database/graph_db_datatypes.hpp"
#include "mvcc/record.hpp"
#include "mvcc/version_list.hpp"
#include "storage/address.hpp"
#include "storage/edges.hpp"
#include "storage/property_value_store.hpp"
class Vertex : public mvcc::Record<Vertex> {
public:
Vertex() = default;
// Returns new Vertex with copy of data stored in this Vertex, but without
// copying superclass' members.
Vertex *CloneData() { return new Vertex(*this); }
Edges out_;
Edges in_;
std::vector<GraphDbTypes::Label> labels_;
PropertyValueStore<GraphDbTypes::Property> properties_;
private:
Vertex(const Vertex &other)
: mvcc::Record<Vertex>(),
out_(other.out_),
in_(other.in_),
labels_(other.labels_),
properties_(other.properties_) {}
};