@Test public void testEquals() { assertFalse(getTestObject().equals(null)); assertFalse(getTestObject().equals("DummyString")); assertTrue(getTestObject().equals(getTestObject())); APISchemaType sameObject = getTestObject(); assertTrue(sameObject.equals(sameObject)); APISchemaType differentObject = getTestObject(); differentObject.setGUID("Different"); assertFalse(getTestObject().equals(differentObject)); }
@Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof APISchemaType)) { return false; } if (!super.equals(objectToCompare)) { return false; } APISchemaType that = (APISchemaType) objectToCompare; return Objects.equals(getOperationCount(), that.getOperationCount()); }
APISchemaType extends SchemaType { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof APISchemaType)) { return false; } if (!super.equals(objectToCompare)) { return false; } APISchemaType that = (APISchemaType) objectToCompare; return Objects.equals(getOperationCount(), that.getOperationCount()); } }
APISchemaType extends SchemaType { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof APISchemaType)) { return false; } if (!super.equals(objectToCompare)) { return false; } APISchemaType that = (APISchemaType) objectToCompare; return Objects.equals(getOperationCount(), that.getOperationCount()); } APISchemaType();  APISchemaType(APISchemaType template); }
APISchemaType extends SchemaType { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof APISchemaType)) { return false; } if (!super.equals(objectToCompare)) { return false; } APISchemaType that = (APISchemaType) objectToCompare; return Objects.equals(getOperationCount(), that.getOperationCount()); } APISchemaType();  APISchemaType(APISchemaType template); int getOperationCount(); void setOperationCount(int operationCount); @Override SchemaElement cloneSchemaElement(); @Override SchemaType cloneSchemaType(); @Override String toString(); @Override boolean equals(Object objectToCompare); }
APISchemaType extends SchemaType { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof APISchemaType)) { return false; } if (!super.equals(objectToCompare)) { return false; } APISchemaType that = (APISchemaType) objectToCompare; return Objects.equals(getOperationCount(), that.getOperationCount()); } APISchemaType();  APISchemaType(APISchemaType template); int getOperationCount(); void setOperationCount(int operationCount); @Override SchemaElement cloneSchemaElement(); @Override SchemaType cloneSchemaType(); @Override String toString(); @Override boolean equals(Object objectToCompare);  }