from storage.Node import Node from storage.NodeFile import NodeFile from storage.Property import Property from storage.PropertyFile import PropertyFile from storage.Relationship import Relationship from storage.RelationshipFile import RelationshipFile from storage.Label import Label from storage.LabelFile import LabelFile from storage.StorageManager import StorageManager nodeFile = NodeFile() relationshipFile = RelationshipFile() propFile = PropertyFile() labelFile = LabelFile() storageManager = StorageManager(nodeFile, relationshipFile, propFile, labelFile) # create two nodes node0 = storageManager.createNode() node1 = storageManager.createNode() rel0 = storageManager.createRelationship(node0, node1, "friendship") node0.addRelationship(rel0) node1.addRelationship(rel0) prop0 = storageManager.createProperty("1", "2") prop1 = storageManager.createProperty("3", "4") prop2 = storageManager.createProperty("5", "1") prop3 = storageManager.createProperty("years", "9") prop4 = storageManager.createProperty("years", 9) prop5 = storageManager.createProperty(">18 years", False)
def __init__(self): """ Initialize the TagsManager """ self._storage = StorageManager()