@Test public void testFindAllInSchema() throws Exception { List<MetadataField> found = metadataFieldService .findAllInSchema(context, metadataSchemaService.find(context, MetadataSchemaEnum.DC.getName())); assertThat("testFindAllInSchema 0", found, notNullValue()); assertTrue("testFindAllInSchema 1", found.size() >= 1); assertTrue("testFindAllInSchema 2", found.size() <= metadataFieldService.findAll(context).size()); boolean added = false; for (MetadataField mdf : found) { if (mdf.equals(mf)) { added = true; } } assertTrue("testFindAllInSchema 3", added); }
@Override public boolean equals(Object obj) { if (obj == null) { return false; } Class<?> objClass = HibernateProxyHelper.getClassWithoutInitializingProxy(obj); if (!getClass().equals(objClass)) { return false; } final MetadataField other = (MetadataField) obj; if (!this.getID().equals(other.getID())) { return false; } if (!getMetadataSchema().equals(other.getMetadataSchema())) { return false; } return true; }
MetadataField implements ReloadableEntity<Integer> { @Override public boolean equals(Object obj) { if (obj == null) { return false; } Class<?> objClass = HibernateProxyHelper.getClassWithoutInitializingProxy(obj); if (!getClass().equals(objClass)) { return false; } final MetadataField other = (MetadataField) obj; if (!this.getID().equals(other.getID())) { return false; } if (!getMetadataSchema().equals(other.getMetadataSchema())) { return false; } return true; } }
MetadataField implements ReloadableEntity<Integer> { @Override public boolean equals(Object obj) { if (obj == null) { return false; } Class<?> objClass = HibernateProxyHelper.getClassWithoutInitializingProxy(obj); if (!getClass().equals(objClass)) { return false; } final MetadataField other = (MetadataField) obj; if (!this.getID().equals(other.getID())) { return false; } if (!getMetadataSchema().equals(other.getMetadataSchema())) { return false; } return true; } protected  MetadataField(); }
MetadataField implements ReloadableEntity<Integer> { @Override public boolean equals(Object obj) { if (obj == null) { return false; } Class<?> objClass = HibernateProxyHelper.getClassWithoutInitializingProxy(obj); if (!getClass().equals(objClass)) { return false; } final MetadataField other = (MetadataField) obj; if (!this.getID().equals(other.getID())) { return false; } if (!getMetadataSchema().equals(other.getMetadataSchema())) { return false; } return true; } protected  MetadataField(); Integer getID(); String getElement(); void setElement(String element); String getQualifier(); void setQualifier(String qualifier); String getScopeNote(); void setScopeNote(String scopeNote); MetadataSchema getMetadataSchema(); void setMetadataSchema(MetadataSchema metadataSchema); @Override boolean equals(Object obj); @Override int hashCode(); String toString(char separator); @Override String toString(); }
MetadataField implements ReloadableEntity<Integer> { @Override public boolean equals(Object obj) { if (obj == null) { return false; } Class<?> objClass = HibernateProxyHelper.getClassWithoutInitializingProxy(obj); if (!getClass().equals(objClass)) { return false; } final MetadataField other = (MetadataField) obj; if (!this.getID().equals(other.getID())) { return false; } if (!getMetadataSchema().equals(other.getMetadataSchema())) { return false; } return true; } protected  MetadataField(); Integer getID(); String getElement(); void setElement(String element); String getQualifier(); void setQualifier(String qualifier); String getScopeNote(); void setScopeNote(String scopeNote); MetadataSchema getMetadataSchema(); void setMetadataSchema(MetadataSchema metadataSchema); @Override boolean equals(Object obj); @Override int hashCode(); String toString(char separator); @Override String toString();  }