Class JsonLdTripleImpl

    • Constructor Detail

      • JsonLdTripleImpl

        JsonLdTripleImpl​(com.github.jsonldjava.core.RDFDataset.Quad quad,
                         java.lang.String blankNodePrefix)
    • Method Detail

      • equals

        public boolean equals​(java.lang.Object obj)
        Description copied from interface: Triple
        Check it this Triple is equal to another Triple.

        Two Triples are equal if and only if their Triple.getSubject(), Triple.getPredicate() and Triple.getObject() are equal.

        Implementations MUST also override Triple.hashCode() so that two equal Triples produce the same hash code.

        Specified by:
        equals in interface Triple
        Overrides:
        equals in class java.lang.Object
        Parameters:
        obj - Another object
        Returns:
        true if other is a Triple and is equal to this
        See Also:
        Object.equals(Object)
      • hashCode

        public int hashCode()
        Description copied from interface: Triple
        Calculate a hash code for this Triple.

        The returned hash code MUST be equal to the result of Objects.hash(Object...) with the arguments Triple.getSubject(), Triple.getPredicate(), Triple.getObject().

        This method MUST be implemented in conjunction with Triple.equals(Object) so that two equal Triples produce the same hash code.

        Specified by:
        hashCode in interface Triple
        Overrides:
        hashCode in class java.lang.Object
        Returns:
        a hash code value for this Triple.
        See Also:
        Object.hashCode(), Objects.hash(Object...)