Package org.neo4j.gds.core.loading
Class CSRGraphStore
- java.lang.Object
-
- org.neo4j.gds.core.loading.CSRGraphStore
-
- All Implemented Interfaces:
GraphStore
public class CSRGraphStore extends java.lang.Object implements GraphStore
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedCSRGraphStore(DatabaseId databaseId, Capabilities capabilities, org.neo4j.gds.api.schema.GraphSchema schema, IdMap nodes, NodePropertyStore nodeProperties, java.util.Map<org.neo4j.gds.RelationshipType,Relationships.Topology> relationships, java.util.Map<org.neo4j.gds.RelationshipType,RelationshipPropertyStore> relationshipProperties, GraphPropertyStore graphProperties, int concurrency)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddGraphProperty(java.lang.String propertyKey, GraphPropertyValues propertyValues)voidaddNodeProperty(java.util.Set<org.neo4j.gds.NodeLabel> labels, java.lang.String propertyKey, NodePropertyValues propertyValues)voidaddRelationshipType(org.neo4j.gds.RelationshipType relationshipType, java.util.Optional<java.lang.String> relationshipPropertyKey, java.util.Optional<org.neo4j.values.storable.NumberType> relationshipPropertyType, Relationships relationships)voidcanRelease(boolean canRelease)Capabilitiescapabilities()DatabaseIddatabaseId()DeletionResultdeleteRelationships(org.neo4j.gds.RelationshipType relationshipType)CompositeRelationshipIteratorgetCompositeRelationshipIterator(org.neo4j.gds.RelationshipType relationshipType, java.util.List<java.lang.String> propertyKeys)CSRGraphgetGraph(java.util.Collection<org.neo4j.gds.NodeLabel> nodeLabels)Returns a graph containing only nodes with the given node labels and no relationships.CSRGraphgetGraph(java.util.Collection<org.neo4j.gds.NodeLabel> nodeLabels, java.util.Collection<org.neo4j.gds.RelationshipType> relationshipTypes, java.util.Optional<java.lang.String> maybeRelationshipProperty)CSRGraphgetUnion()GraphPropertygraphProperty(java.lang.String propertyKey)java.util.Set<java.lang.String>graphPropertyKeys()org.neo4j.gds.api.nodeproperties.ValueTypegraphPropertyType(java.lang.String propertyKey)GraphPropertyValuesgraphPropertyValues(java.lang.String propertyKey)booleanhasGraphProperty(java.lang.String propertyKey)booleanhasNodeProperty(java.lang.String propertyKey)booleanhasNodeProperty(java.util.Collection<org.neo4j.gds.NodeLabel> labels, java.lang.String propertyKey)booleanhasNodeProperty(org.neo4j.gds.NodeLabel label, java.lang.String propertyKey)booleanhasRelationshipProperty(org.neo4j.gds.RelationshipType relType, java.lang.String propertyKey)booleanhasRelationshipType(org.neo4j.gds.RelationshipType relationshipType)java.time.ZonedDateTimemodificationTime()longnodeCount()java.util.Set<org.neo4j.gds.NodeLabel>nodeLabels()NodePropertynodeProperty(java.lang.String propertyKey)java.util.Set<java.lang.String>nodePropertyKeys()java.util.Set<java.lang.String>nodePropertyKeys(org.neo4j.gds.NodeLabel label)IdMapnodes()static CSRGraphStoreof(DatabaseId databaseId, Capabilities capabilities, org.neo4j.gds.api.schema.GraphSchema schema, IdMap nodes, @Nullable NodePropertyStore nodePropertyStore, java.util.Map<org.neo4j.gds.RelationshipType,Relationships.Topology> relationships, java.util.Map<org.neo4j.gds.RelationshipType,RelationshipPropertyStore> relationshipPropertyStores, java.util.Optional<GraphPropertyStore> graphProperties, int concurrency)longrelationshipCount()longrelationshipCount(org.neo4j.gds.RelationshipType relationshipType)java.util.Set<java.lang.String>relationshipPropertyKeys()java.util.Set<java.lang.String>relationshipPropertyKeys(org.neo4j.gds.RelationshipType relationshipType)org.neo4j.gds.api.nodeproperties.ValueTyperelationshipPropertyType(java.lang.String propertyKey)RelationshipPropertyrelationshipPropertyValues(org.neo4j.gds.RelationshipType relationshipType, java.lang.String propertyKey)java.util.Set<org.neo4j.gds.RelationshipType>relationshipTypes()voidrelease()voidremoveGraphProperty(java.lang.String propertyKey)voidremoveNodeProperty(java.lang.String propertyKey)org.neo4j.gds.api.schema.GraphSchemaschema()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.neo4j.gds.api.GraphStore
getGraph, getGraph, getGraph, getGraph, getGraph, getGraph, getGraph, nodePropertyKeys, relationshipPropertyKeys
-
-
-
-
Constructor Detail
-
CSRGraphStore
protected CSRGraphStore(DatabaseId databaseId, Capabilities capabilities, org.neo4j.gds.api.schema.GraphSchema schema, IdMap nodes, NodePropertyStore nodeProperties, java.util.Map<org.neo4j.gds.RelationshipType,Relationships.Topology> relationships, java.util.Map<org.neo4j.gds.RelationshipType,RelationshipPropertyStore> relationshipProperties, GraphPropertyStore graphProperties, int concurrency)
-
-
Method Detail
-
of
@Factory public static CSRGraphStore of(DatabaseId databaseId, Capabilities capabilities, org.neo4j.gds.api.schema.GraphSchema schema, IdMap nodes, @Nullable @Nullable NodePropertyStore nodePropertyStore, java.util.Map<org.neo4j.gds.RelationshipType,Relationships.Topology> relationships, java.util.Map<org.neo4j.gds.RelationshipType,RelationshipPropertyStore> relationshipPropertyStores, java.util.Optional<GraphPropertyStore> graphProperties, int concurrency)
-
databaseId
public DatabaseId databaseId()
- Specified by:
databaseIdin interfaceGraphStore
-
schema
public org.neo4j.gds.api.schema.GraphSchema schema()
- Specified by:
schemain interfaceGraphStore
-
modificationTime
public java.time.ZonedDateTime modificationTime()
- Specified by:
modificationTimein interfaceGraphStore
-
capabilities
public Capabilities capabilities()
- Specified by:
capabilitiesin interfaceGraphStore
-
graphPropertyKeys
public java.util.Set<java.lang.String> graphPropertyKeys()
- Specified by:
graphPropertyKeysin interfaceGraphStore
-
hasGraphProperty
public boolean hasGraphProperty(java.lang.String propertyKey)
- Specified by:
hasGraphPropertyin interfaceGraphStore
-
graphProperty
public GraphProperty graphProperty(java.lang.String propertyKey)
- Specified by:
graphPropertyin interfaceGraphStore
-
graphPropertyType
public org.neo4j.gds.api.nodeproperties.ValueType graphPropertyType(java.lang.String propertyKey)
- Specified by:
graphPropertyTypein interfaceGraphStore
-
graphPropertyValues
public GraphPropertyValues graphPropertyValues(java.lang.String propertyKey)
- Specified by:
graphPropertyValuesin interfaceGraphStore
-
addGraphProperty
public void addGraphProperty(java.lang.String propertyKey, GraphPropertyValues propertyValues)- Specified by:
addGraphPropertyin interfaceGraphStore
-
removeGraphProperty
public void removeGraphProperty(java.lang.String propertyKey)
- Specified by:
removeGraphPropertyin interfaceGraphStore
-
nodes
public IdMap nodes()
- Specified by:
nodesin interfaceGraphStore
-
nodeLabels
public java.util.Set<org.neo4j.gds.NodeLabel> nodeLabels()
- Specified by:
nodeLabelsin interfaceGraphStore
-
nodePropertyKeys
public java.util.Set<java.lang.String> nodePropertyKeys(org.neo4j.gds.NodeLabel label)
- Specified by:
nodePropertyKeysin interfaceGraphStore
-
nodePropertyKeys
public java.util.Set<java.lang.String> nodePropertyKeys()
- Specified by:
nodePropertyKeysin interfaceGraphStore
-
hasNodeProperty
public boolean hasNodeProperty(java.lang.String propertyKey)
- Specified by:
hasNodePropertyin interfaceGraphStore
-
hasNodeProperty
public boolean hasNodeProperty(org.neo4j.gds.NodeLabel label, java.lang.String propertyKey)- Specified by:
hasNodePropertyin interfaceGraphStore
-
hasNodeProperty
public boolean hasNodeProperty(java.util.Collection<org.neo4j.gds.NodeLabel> labels, java.lang.String propertyKey)- Specified by:
hasNodePropertyin interfaceGraphStore
-
addNodeProperty
public void addNodeProperty(java.util.Set<org.neo4j.gds.NodeLabel> labels, java.lang.String propertyKey, NodePropertyValues propertyValues)- Specified by:
addNodePropertyin interfaceGraphStore
-
removeNodeProperty
public void removeNodeProperty(java.lang.String propertyKey)
- Specified by:
removeNodePropertyin interfaceGraphStore
-
nodeProperty
public NodeProperty nodeProperty(java.lang.String propertyKey)
- Specified by:
nodePropertyin interfaceGraphStore
-
relationshipTypes
public java.util.Set<org.neo4j.gds.RelationshipType> relationshipTypes()
- Specified by:
relationshipTypesin interfaceGraphStore
-
hasRelationshipType
public boolean hasRelationshipType(org.neo4j.gds.RelationshipType relationshipType)
- Specified by:
hasRelationshipTypein interfaceGraphStore
-
relationshipCount
public long relationshipCount()
- Specified by:
relationshipCountin interfaceGraphStore
-
relationshipCount
public long relationshipCount(org.neo4j.gds.RelationshipType relationshipType)
- Specified by:
relationshipCountin interfaceGraphStore
-
hasRelationshipProperty
public boolean hasRelationshipProperty(org.neo4j.gds.RelationshipType relType, java.lang.String propertyKey)- Specified by:
hasRelationshipPropertyin interfaceGraphStore
-
relationshipPropertyType
public org.neo4j.gds.api.nodeproperties.ValueType relationshipPropertyType(java.lang.String propertyKey)
- Specified by:
relationshipPropertyTypein interfaceGraphStore
-
relationshipPropertyKeys
public java.util.Set<java.lang.String> relationshipPropertyKeys()
- Specified by:
relationshipPropertyKeysin interfaceGraphStore
-
relationshipPropertyKeys
public java.util.Set<java.lang.String> relationshipPropertyKeys(org.neo4j.gds.RelationshipType relationshipType)
- Specified by:
relationshipPropertyKeysin interfaceGraphStore
-
relationshipPropertyValues
public RelationshipProperty relationshipPropertyValues(org.neo4j.gds.RelationshipType relationshipType, java.lang.String propertyKey)
- Specified by:
relationshipPropertyValuesin interfaceGraphStore
-
addRelationshipType
public void addRelationshipType(org.neo4j.gds.RelationshipType relationshipType, java.util.Optional<java.lang.String> relationshipPropertyKey, java.util.Optional<org.neo4j.values.storable.NumberType> relationshipPropertyType, Relationships relationships)- Specified by:
addRelationshipTypein interfaceGraphStore
-
deleteRelationships
public DeletionResult deleteRelationships(org.neo4j.gds.RelationshipType relationshipType)
- Specified by:
deleteRelationshipsin interfaceGraphStore
-
getGraph
public CSRGraph getGraph(java.util.Collection<org.neo4j.gds.NodeLabel> nodeLabels)
Description copied from interface:GraphStoreReturns a graph containing only nodes with the given node labels and no relationships.- Specified by:
getGraphin interfaceGraphStore- Parameters:
nodeLabels- node label filter- Returns:
- a node-only graph
-
getGraph
public CSRGraph getGraph(java.util.Collection<org.neo4j.gds.NodeLabel> nodeLabels, java.util.Collection<org.neo4j.gds.RelationshipType> relationshipTypes, java.util.Optional<java.lang.String> maybeRelationshipProperty)
- Specified by:
getGraphin interfaceGraphStore
-
getUnion
public CSRGraph getUnion()
- Specified by:
getUnionin interfaceGraphStore
-
canRelease
public void canRelease(boolean canRelease)
- Specified by:
canReleasein interfaceGraphStore
-
getCompositeRelationshipIterator
public CompositeRelationshipIterator getCompositeRelationshipIterator(org.neo4j.gds.RelationshipType relationshipType, java.util.List<java.lang.String> propertyKeys)
- Specified by:
getCompositeRelationshipIteratorin interfaceGraphStore
-
release
public void release()
- Specified by:
releasein interfaceGraphStore
-
nodeCount
public long nodeCount()
- Specified by:
nodeCountin interfaceGraphStore
-
-