Class: Neo4j::Driver::Types::Path::Segment

Inherits:
Object
  • Object
show all
Defined in:
lib/neo4j/driver/types/path.rb

Overview

Represents a segment of a path (a relationship and its start/end nodes)

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(start_node, end_node, relationship) ⇒ Segment

Returns a new instance of Segment.



56
57
58
59
60
# File 'lib/neo4j/driver/types/path.rb', line 56

def initialize(start_node, end_node, relationship)
  @start_node = start_node
  @end_node = end_node
  @relationship = relationship
end

Instance Attribute Details

#end_nodeObject (readonly) Also known as: end

Returns the value of attribute end_node.



54
55
56
# File 'lib/neo4j/driver/types/path.rb', line 54

def end_node
  @end_node
end

#relationshipObject (readonly)

Returns the value of attribute relationship.



54
55
56
# File 'lib/neo4j/driver/types/path.rb', line 54

def relationship
  @relationship
end

#start_nodeObject (readonly) Also known as: start

Returns the value of attribute start_node.



54
55
56
# File 'lib/neo4j/driver/types/path.rb', line 54

def start_node
  @start_node
end