@Test public void testEquals() { assertFalse(period1.equals(null)); assertEquals(period1, period1); assertFalse(period1.equals(period2)); }
@Override public boolean equals(final Object object) { if (object == this) { return true; } if (object instanceof DefaultPeriod) { final DefaultPeriod that = (DefaultPeriod) object; return Utilities.equals(this.begining, that.begining) && Utilities.equals(this.ending, that.ending); } return false; }
DefaultPeriod extends DefaultTemporalGeometricPrimitive implements Period { @Override public boolean equals(final Object object) { if (object == this) { return true; } if (object instanceof DefaultPeriod) { final DefaultPeriod that = (DefaultPeriod) object; return Utilities.equals(this.begining, that.begining) && Utilities.equals(this.ending, that.ending); } return false; } }
DefaultPeriod extends DefaultTemporalGeometricPrimitive implements Period { @Override public boolean equals(final Object object) { if (object == this) { return true; } if (object instanceof DefaultPeriod) { final DefaultPeriod that = (DefaultPeriod) object; return Utilities.equals(this.begining, that.begining) && Utilities.equals(this.ending, that.ending); } return false; } DefaultPeriod(Instant begining, Instant ending); }
DefaultPeriod extends DefaultTemporalGeometricPrimitive implements Period { @Override public boolean equals(final Object object) { if (object == this) { return true; } if (object instanceof DefaultPeriod) { final DefaultPeriod that = (DefaultPeriod) object; return Utilities.equals(this.begining, that.begining) && Utilities.equals(this.ending, that.ending); } return false; } DefaultPeriod(Instant begining, Instant ending); Instant getBeginning(); void setBegining(Instant begining); void setBegining(Date date); Instant getEnding(); void setEnding(Instant ending); void setEnding(Date date); @Override boolean equals(final Object object); @Override int hashCode(); @Override String toString(); }
DefaultPeriod extends DefaultTemporalGeometricPrimitive implements Period { @Override public boolean equals(final Object object) { if (object == this) { return true; } if (object instanceof DefaultPeriod) { final DefaultPeriod that = (DefaultPeriod) object; return Utilities.equals(this.begining, that.begining) && Utilities.equals(this.ending, that.ending); } return false; } DefaultPeriod(Instant begining, Instant ending); Instant getBeginning(); void setBegining(Instant begining); void setBegining(Date date); Instant getEnding(); void setEnding(Instant ending); void setEnding(Date date); @Override boolean equals(final Object object); @Override int hashCode(); @Override String toString();  }