[Neo] getRelationships(RelationshipType... types)

Sumanth Thikka sumanth at truesparrow.com
Tue Feb 23 15:32:49 CET 2010


Hi,

I am newbie to neo4j and I am enjoying it.

I have started to create nodes, relationships and assigning properties to
the nodes etc.
I've got a problem in accessing relationships of a node.

If 'knows = DynamicRelationshipType.withName("KNOWS")' is a relation
defined.

When a relationship 'knows' is formed from node1 to node2, I should be able
to access relationship of node1 by one of node1.getRelationships()
or node1.getRelationships(knows, direction)
or node1.getRelationships(direction) or node1.getRelationships(knows)
methods.

There is no problem with the first three, but the last method throws an
error.
Error is:
         NameError: no getRelationships with arguments matching [class
org.neo4j.graphdb.DynamicRelationshipType] on object
#<#<Class:01xf38cf0>:0x1aa0a15>



More information about the User mailing list