CCPlane implements Cloneable, Externalizable { @Override public boolean equals(final Object theObject) { if (this == theObject) { return true; } if (!(theObject instanceof CCPlane)) { return false; } final CCPlane comp = (CCPlane) theObject; return constant() == comp.constant() && _myNormal.equals(comp.normal()); } CCPlane();  CCPlane(final CCPlane theSource);  CCPlane(final CCVector3 theNormal, final double theConstant);  CCPlane(CCVector3 theOrigin, CCVector3 theNormal);  CCPlane(final CCVector3 theV1, final CCVector3 theV2, final CCVector3 theV3); double constant(); CCVector3 normal(); CCPlane set(final CCPlane theSource); void setConstant(final double theConstant); void setNormal(final CCVector3 theNormal); double pseudoDistance(final CCVector3 thePoint); double distance(final CCVector3 thePoint); Side whichSide(final CCVector3 thePoint); void setOriginNormal(CCVector3 theOrigin, CCVector3 theNormal); CCPlane setPlanePoints(final CCVector3 theA, final CCVector3 theB, final CCVector3 theC); CCVector3 reflectVector(final CCVector3 theUnitVector, final CCVector3 theStore); static boolean isValid(final CCPlane thePlane); @Override String toString(); @Override int hashCode(); @Override boolean equals(final Object theObject); @Override CCPlane clone(); @Override void readExternal(final ObjectInput in); @Override void writeExternal(final ObjectOutput out); static final CCPlane XZ; static final CCPlane XY; static final CCPlane YZ; }
@Test public void testEquals() { final CCPlane plane1 = new CCPlane(); assertEquals(plane1, plane1); assertFalse(plane1.equals(null)); assertFalse(plane1.equals(new CCVector2())); assertFalse(plane1.equals(new CCPlane(CCVector3.UNIT_X, 0))); }