@Test public void testEquals() { assertFalse(getTestObject().equals(null)); assertFalse(getTestObject().equals("DummyString")); assertTrue(getTestObject().equals(getTestObject())); Annotation sameObject = getTestObject(); assertTrue(sameObject.equals(sameObject)); Annotation differentObject = getTestObject(); differentObject.setGUID("Different"); assertFalse(getTestObject().equals(differentObject)); }
@Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (objectToCompare == null || getClass() != objectToCompare.getClass()) { return false; } if (!super.equals(objectToCompare)) { return false; } Annotation that = (Annotation) objectToCompare; return getConfidenceLevel() == that.getConfidenceLevel() && Objects.equals(getAnnotationType(), that.getAnnotationType()) && Objects.equals(getSummary(), that.getSummary()) && Objects.equals(getExpression(), that.getExpression()) && Objects.equals(getExplanation(), that.getExplanation()) && Objects.equals(getAnalysisStep(), that.getAnalysisStep()) && Objects.equals(getJsonProperties(), that.getJsonProperties()) && getNumAttachedAnnotations() == that.getNumAttachedAnnotations() && getAnnotationStatus() == that.getAnnotationStatus() && Objects.equals(getReviewDate(), that.getReviewDate()) && Objects.equals(getSteward(), that.getSteward()) && Objects.equals(getReviewComment(), that.getReviewComment()) && Objects.equals(getAdditionalProperties(), that.getAdditionalProperties()) && Objects.equals(getExtendedProperties(), that.getExtendedProperties()); }
Annotation extends ElementHeader { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (objectToCompare == null || getClass() != objectToCompare.getClass()) { return false; } if (!super.equals(objectToCompare)) { return false; } Annotation that = (Annotation) objectToCompare; return getConfidenceLevel() == that.getConfidenceLevel() && Objects.equals(getAnnotationType(), that.getAnnotationType()) && Objects.equals(getSummary(), that.getSummary()) && Objects.equals(getExpression(), that.getExpression()) && Objects.equals(getExplanation(), that.getExplanation()) && Objects.equals(getAnalysisStep(), that.getAnalysisStep()) && Objects.equals(getJsonProperties(), that.getJsonProperties()) && getNumAttachedAnnotations() == that.getNumAttachedAnnotations() && getAnnotationStatus() == that.getAnnotationStatus() && Objects.equals(getReviewDate(), that.getReviewDate()) && Objects.equals(getSteward(), that.getSteward()) && Objects.equals(getReviewComment(), that.getReviewComment()) && Objects.equals(getAdditionalProperties(), that.getAdditionalProperties()) && Objects.equals(getExtendedProperties(), that.getExtendedProperties()); } }
Annotation extends ElementHeader { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (objectToCompare == null || getClass() != objectToCompare.getClass()) { return false; } if (!super.equals(objectToCompare)) { return false; } Annotation that = (Annotation) objectToCompare; return getConfidenceLevel() == that.getConfidenceLevel() && Objects.equals(getAnnotationType(), that.getAnnotationType()) && Objects.equals(getSummary(), that.getSummary()) && Objects.equals(getExpression(), that.getExpression()) && Objects.equals(getExplanation(), that.getExplanation()) && Objects.equals(getAnalysisStep(), that.getAnalysisStep()) && Objects.equals(getJsonProperties(), that.getJsonProperties()) && getNumAttachedAnnotations() == that.getNumAttachedAnnotations() && getAnnotationStatus() == that.getAnnotationStatus() && Objects.equals(getReviewDate(), that.getReviewDate()) && Objects.equals(getSteward(), that.getSteward()) && Objects.equals(getReviewComment(), that.getReviewComment()) && Objects.equals(getAdditionalProperties(), that.getAdditionalProperties()) && Objects.equals(getExtendedProperties(), that.getExtendedProperties()); } Annotation();  Annotation(Annotation template); }
Annotation extends ElementHeader { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (objectToCompare == null || getClass() != objectToCompare.getClass()) { return false; } if (!super.equals(objectToCompare)) { return false; } Annotation that = (Annotation) objectToCompare; return getConfidenceLevel() == that.getConfidenceLevel() && Objects.equals(getAnnotationType(), that.getAnnotationType()) && Objects.equals(getSummary(), that.getSummary()) && Objects.equals(getExpression(), that.getExpression()) && Objects.equals(getExplanation(), that.getExplanation()) && Objects.equals(getAnalysisStep(), that.getAnalysisStep()) && Objects.equals(getJsonProperties(), that.getJsonProperties()) && getNumAttachedAnnotations() == that.getNumAttachedAnnotations() && getAnnotationStatus() == that.getAnnotationStatus() && Objects.equals(getReviewDate(), that.getReviewDate()) && Objects.equals(getSteward(), that.getSteward()) && Objects.equals(getReviewComment(), that.getReviewComment()) && Objects.equals(getAdditionalProperties(), that.getAdditionalProperties()) && Objects.equals(getExtendedProperties(), that.getExtendedProperties()); } Annotation();  Annotation(Annotation template); String getAnnotationType(); void setAnnotationType(String annotationType); String getSummary(); void setSummary(String summary); int getConfidenceLevel(); void setConfidenceLevel(int confidenceLevel); String getExpression(); void setExpression(String expression); String getExplanation(); void setExplanation(String explanation); String getAnalysisStep(); void setAnalysisStep(String analysisStep); String getJsonProperties(); void setJsonProperties(String jsonProperties); AnnotationStatus getAnnotationStatus(); void setAnnotationStatus(AnnotationStatus annotationStatus); int getNumAttachedAnnotations(); void setAttachedAnnotations(int number); Date getReviewDate(); void setReviewDate(Date reviewDate); String getSteward(); void setSteward(String steward); String getReviewComment(); void setReviewComment(String reviewComment); Map<String, String> getAdditionalProperties(); void setAdditionalProperties(Map<String, String> additionalProperties); @Override String toString(); @Override boolean equals(Object objectToCompare); @Override int hashCode(); }
Annotation extends ElementHeader { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (objectToCompare == null || getClass() != objectToCompare.getClass()) { return false; } if (!super.equals(objectToCompare)) { return false; } Annotation that = (Annotation) objectToCompare; return getConfidenceLevel() == that.getConfidenceLevel() && Objects.equals(getAnnotationType(), that.getAnnotationType()) && Objects.equals(getSummary(), that.getSummary()) && Objects.equals(getExpression(), that.getExpression()) && Objects.equals(getExplanation(), that.getExplanation()) && Objects.equals(getAnalysisStep(), that.getAnalysisStep()) && Objects.equals(getJsonProperties(), that.getJsonProperties()) && getNumAttachedAnnotations() == that.getNumAttachedAnnotations() && getAnnotationStatus() == that.getAnnotationStatus() && Objects.equals(getReviewDate(), that.getReviewDate()) && Objects.equals(getSteward(), that.getSteward()) && Objects.equals(getReviewComment(), that.getReviewComment()) && Objects.equals(getAdditionalProperties(), that.getAdditionalProperties()) && Objects.equals(getExtendedProperties(), that.getExtendedProperties()); } Annotation();  Annotation(Annotation template); String getAnnotationType(); void setAnnotationType(String annotationType); String getSummary(); void setSummary(String summary); int getConfidenceLevel(); void setConfidenceLevel(int confidenceLevel); String getExpression(); void setExpression(String expression); String getExplanation(); void setExplanation(String explanation); String getAnalysisStep(); void setAnalysisStep(String analysisStep); String getJsonProperties(); void setJsonProperties(String jsonProperties); AnnotationStatus getAnnotationStatus(); void setAnnotationStatus(AnnotationStatus annotationStatus); int getNumAttachedAnnotations(); void setAttachedAnnotations(int number); Date getReviewDate(); void setReviewDate(Date reviewDate); String getSteward(); void setSteward(String steward); String getReviewComment(); void setReviewComment(String reviewComment); Map<String, String> getAdditionalProperties(); void setAdditionalProperties(Map<String, String> additionalProperties); @Override String toString(); @Override boolean equals(Object objectToCompare); @Override int hashCode();  }