java.lang.Object
redis.clients.jedis.graph.entities.GraphEntity
redis.clients.jedis.graph.entities.Edge

public class Edge extends GraphEntity
A class represent an edge (graph entity). In addition to the base class id and properties, an edge shows its source, destination and relationship type
  • Field Details

    • relationshipType

      private String relationshipType
    • source

      private long source
    • destination

      private long destination
  • Constructor Details

    • Edge

      public Edge()
    • Edge

      public Edge(int propertiesCapacity)
      Use this constructor to reduce memory allocations when properties are added to the edge
      Parameters:
      propertiesCapacity - preallocate the capacity for the properties
  • Method Details

    • getRelationshipType

      public String getRelationshipType()
      Returns:
      the edge relationship type
    • setRelationshipType

      public void setRelationshipType(String relationshipType)
      Parameters:
      relationshipType - - the relationship type to be set.
    • getSource

      public long getSource()
      Returns:
      The id of the source node
    • setSource

      public void setSource(long source)
      Parameters:
      source - - The id of the source node to be set
    • getDestination

      public long getDestination()
      Returns:
      the id of the destination node
    • setDestination

      public void setDestination(long destination)
      Parameters:
      destination - - The id of the destination node to be set
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class GraphEntity
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class GraphEntity
    • toString

      public String toString()
      Specified by:
      toString in class GraphEntity