Interface BNode

All Superinterfaces:
Resource, Serializable, Value
All Known Implementing Classes:
AbstractBNode, CorruptIRIOrBNode, LmdbBNode, MemBNode, NativeBNode, SimpleBNode

public interface BNode extends Resource
An RDF-1.1 blank node (aka bnode, aka anonymous node). A blank node has an identifier to be able to compare it to other blank nodes internally. Please note that, conceptually, blank node equality can only be determined by examining the statements that refer to them.
See Also:
  • Method Summary Link icon

    Modifier and Type
    Method
    Description
    boolean
    Compares this blank node to another object.
    Retrieves this blank node's identifier.
    int
    Computes the hash code of this blank node.
    default boolean
    Check if the object is an instance of the given type.

    Methods inherited from interface org.eclipse.rdf4j.model.Resource Link icon

    isResource

    Methods inherited from interface org.eclipse.rdf4j.model.Value Link icon

    isIRI, isLiteral, isTriple, stringValue
  • Method Details Link icon

    • isBNode Link icon

      default boolean isBNode()
      Description copied from interface: Value
      Check if the object is an instance of the given type. Typically 2x than using instanceof.

      For implementers: This default implementation is overridden in the repsective sub-interface.

      Specified by:
      isBNode in interface Value
      Returns:
      true if instance of BNode
    • getID Link icon

      String getID()
      Retrieves this blank node's identifier.
      Returns:
      A blank node identifier.
    • equals Link icon

      boolean equals(Object o)
      Compares this blank node to another object.
      Overrides:
      equals in class Object
      Parameters:
      o - the object to compare this blank node to
      Returns:
      true, if the other object is an instance of BNode and their IDs are equal; false, otherwise.
    • hashCode Link icon

      int hashCode()
      Computes the hash code of this blank node.
      Overrides:
      hashCode in class Object
      Returns:
      a hash code for this blank node computed as getID().hashCode()