Sha256: e7cf4d006f2e94c5b08ca072803731b7913cc042e7a1e3bdf378820fcbb1417d
Contents?: true
Size: 801 Bytes
Versions: 17
Compression:
Stored size: 801 Bytes
Contents
module Neo4j module ToJava def type_to_java(type) org.neo4j.graphdb.DynamicRelationshipType.withName(type.to_s) end def dir_from_java(dir) case dir when org.neo4j.graphdb.Direction::OUTGOING then :outgoing when org.neo4j.graphdb.Direction::BOTH then :both when org.neo4j.graphdb.Direction::INCOMING then :incoming else raise "unknown direction '#{dir} / #{dir.class}'" end end def dir_to_java(dir) case dir when :outgoing then org.neo4j.graphdb.Direction::OUTGOING when :both then org.neo4j.graphdb.Direction::BOTH when :incoming then org.neo4j.graphdb.Direction::INCOMING else raise "unknown direction '#{dir}', expects :outgoing, :incoming or :both" end end end end
Version data entries
17 entries across 17 versions & 1 rubygems