@Test public void testEquals() { assertTrue(getTestObject().equals(getTestObject())); EnumElementDef testObject = getTestObject(); assertTrue(testObject.equals(testObject)); assertTrue(testObject.equals(getTestObject())); assertFalse(getTestObject().equals(null)); assertFalse(getTestObject().equals("A String")); EnumElementDef differentObject = getTestObject(); differentObject.setValue("AnotherValue"); assertFalse(testObject.equals(differentObject)); }
@Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof EnumElementDef)) { return false; } EnumElementDef that = (EnumElementDef) o; return getOrdinal() == that.getOrdinal() && Objects.equals(getValue(), that.getValue()) && Objects.equals(getDescription(), that.getDescription()) && Objects.equals(getDescriptionGUID(), that.getDescriptionGUID()); }
EnumElementDef extends TypeDefElementHeader { @Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof EnumElementDef)) { return false; } EnumElementDef that = (EnumElementDef) o; return getOrdinal() == that.getOrdinal() && Objects.equals(getValue(), that.getValue()) && Objects.equals(getDescription(), that.getDescription()) && Objects.equals(getDescriptionGUID(), that.getDescriptionGUID()); } }
EnumElementDef extends TypeDefElementHeader { @Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof EnumElementDef)) { return false; } EnumElementDef that = (EnumElementDef) o; return getOrdinal() == that.getOrdinal() && Objects.equals(getValue(), that.getValue()) && Objects.equals(getDescription(), that.getDescription()) && Objects.equals(getDescriptionGUID(), that.getDescriptionGUID()); } EnumElementDef();  EnumElementDef(EnumElementDef  template); }
EnumElementDef extends TypeDefElementHeader { @Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof EnumElementDef)) { return false; } EnumElementDef that = (EnumElementDef) o; return getOrdinal() == that.getOrdinal() && Objects.equals(getValue(), that.getValue()) && Objects.equals(getDescription(), that.getDescription()) && Objects.equals(getDescriptionGUID(), that.getDescriptionGUID()); } EnumElementDef();  EnumElementDef(EnumElementDef  template); int getOrdinal(); void setOrdinal(int ordinal); String getValue(); void setValue(String value); String getDescription(); void setDescription(String description); String getDescriptionGUID(); void setDescriptionGUID(String descriptionGUID); @Override String toString(); @Override boolean equals(Object o); @Override int hashCode(); }
EnumElementDef extends TypeDefElementHeader { @Override public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof EnumElementDef)) { return false; } EnumElementDef that = (EnumElementDef) o; return getOrdinal() == that.getOrdinal() && Objects.equals(getValue(), that.getValue()) && Objects.equals(getDescription(), that.getDescription()) && Objects.equals(getDescriptionGUID(), that.getDescriptionGUID()); } EnumElementDef();  EnumElementDef(EnumElementDef  template); int getOrdinal(); void setOrdinal(int ordinal); String getValue(); void setValue(String value); String getDescription(); void setDescription(String description); String getDescriptionGUID(); void setDescriptionGUID(String descriptionGUID); @Override String toString(); @Override boolean equals(Object o); @Override int hashCode();  }