@Test public void inequality() throws Exception { InvariantSpan s1 = new InvariantSpan(10, 60, "ted: InvariantSpan s2 = new InvariantSpan(10, 50, "ted: assertFalse(s1.equals(s2)); }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (getClass() != obj.getClass()) return false; InvariantSpan other = (InvariantSpan) obj; if (documentHash == null) { if (other.documentHash != null) return false; } else if (!documentHash.equals(other.documentHash)) return false; if (start != other.start) return false; if (width != other.width) return false; return true; }
InvariantSpan implements Invariant { @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (getClass() != obj.getClass()) return false; InvariantSpan other = (InvariantSpan) obj; if (documentHash == null) { if (other.documentHash != null) return false; } else if (!documentHash.equals(other.documentHash)) return false; if (start != other.start) return false; if (width != other.width) return false; return true; } }
InvariantSpan implements Invariant { @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (getClass() != obj.getClass()) return false; InvariantSpan other = (InvariantSpan) obj; if (documentHash == null) { if (other.documentHash != null) return false; } else if (!documentHash.equals(other.documentHash)) return false; if (start != other.start) return false; if (width != other.width) return false; return true; } InvariantSpan();  InvariantSpan(long start, long width, String documentHash); }
InvariantSpan implements Invariant { @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (getClass() != obj.getClass()) return false; InvariantSpan other = (InvariantSpan) obj; if (documentHash == null) { if (other.documentHash != null) return false; } else if (!documentHash.equals(other.documentHash)) return false; if (start != other.start) return false; if (width != other.width) return false; return true; } InvariantSpan();  InvariantSpan(long start, long width, String documentHash); @Override InvariantSpan copy(); @Override boolean equals(Object obj); String getDocumentHash(); long getStart(); @Override long getWidth(); @Override int hashCode(); boolean hashDocumentHash(); void setStart(long start); @Override void setWidth(long width); @Override StreamElementPartition<InvariantSpan> split(long leftPartitionWidth); @Override String toString(); }
InvariantSpan implements Invariant { @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (getClass() != obj.getClass()) return false; InvariantSpan other = (InvariantSpan) obj; if (documentHash == null) { if (other.documentHash != null) return false; } else if (!documentHash.equals(other.documentHash)) return false; if (start != other.start) return false; if (width != other.width) return false; return true; } InvariantSpan();  InvariantSpan(long start, long width, String documentHash); @Override InvariantSpan copy(); @Override boolean equals(Object obj); String getDocumentHash(); long getStart(); @Override long getWidth(); @Override int hashCode(); boolean hashDocumentHash(); void setStart(long start); @Override void setWidth(long width); @Override StreamElementPartition<InvariantSpan> split(long leftPartitionWidth); @Override String toString();  }