@Test public void testEquals() { assertFalse(getTestObject().equals(null)); assertFalse(getTestObject().equals("DummyString")); assertTrue(getTestObject().equals(getTestObject())); AssetInformalTag sameObject = getTestObject(); assertTrue(sameObject.equals(sameObject)); assertFalse(getTestObject().equals(getDifferentObject())); assertFalse(getTestObject().equals(getAnotherDifferentObject())); }
@Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof AssetInformalTag)) { return false; } if (!super.equals(objectToCompare)) { return false; } AssetInformalTag that = (AssetInformalTag) objectToCompare; return Objects.equals(getInformalTagBean(), that.getInformalTagBean()); }
AssetInformalTag extends AssetElementHeader { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof AssetInformalTag)) { return false; } if (!super.equals(objectToCompare)) { return false; } AssetInformalTag that = (AssetInformalTag) objectToCompare; return Objects.equals(getInformalTagBean(), that.getInformalTagBean()); } }
AssetInformalTag extends AssetElementHeader { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof AssetInformalTag)) { return false; } if (!super.equals(objectToCompare)) { return false; } AssetInformalTag that = (AssetInformalTag) objectToCompare; return Objects.equals(getInformalTagBean(), that.getInformalTagBean()); } AssetInformalTag(InformalTag   informalTagBean);  AssetInformalTag(AssetDescriptor  parentAsset,
                            InformalTag      informalTagBean);  AssetInformalTag(AssetDescriptor parentAsset, AssetInformalTag templateInformalTag); }
AssetInformalTag extends AssetElementHeader { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof AssetInformalTag)) { return false; } if (!super.equals(objectToCompare)) { return false; } AssetInformalTag that = (AssetInformalTag) objectToCompare; return Objects.equals(getInformalTagBean(), that.getInformalTagBean()); } AssetInformalTag(InformalTag   informalTagBean);  AssetInformalTag(AssetDescriptor  parentAsset,
                            InformalTag      informalTagBean);  AssetInformalTag(AssetDescriptor parentAsset, AssetInformalTag templateInformalTag); boolean isPublic(); boolean isPrivateTag(); String getUser(); String getName(); String getDescription(); @Override String toString(); @Override boolean equals(Object objectToCompare); }
AssetInformalTag extends AssetElementHeader { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof AssetInformalTag)) { return false; } if (!super.equals(objectToCompare)) { return false; } AssetInformalTag that = (AssetInformalTag) objectToCompare; return Objects.equals(getInformalTagBean(), that.getInformalTagBean()); } AssetInformalTag(InformalTag   informalTagBean);  AssetInformalTag(AssetDescriptor  parentAsset,
                            InformalTag      informalTagBean);  AssetInformalTag(AssetDescriptor parentAsset, AssetInformalTag templateInformalTag); boolean isPublic(); boolean isPrivateTag(); String getUser(); String getName(); String getDescription(); @Override String toString(); @Override boolean equals(Object objectToCompare);  }