@Test void testTransformRefEntitiesEmptyMap() { EntityType entityType = mock(EntityType.class); RelationTransformer.transformRefEntities(entityType, emptyMap()); verify(entityType, never()).getAtomicAttributes(); }
static void transformRefEntities(EntityType entityType, Map<String, EntityType> newEntityTypes) { if (newEntityTypes.isEmpty()) { return; } stream(entityType.getAtomicAttributes()) .filter(EntityTypeUtils::isReferenceType) .forEach(attr -> transformRefEntity(attr, newEntityTypes)); }
RelationTransformer { static void transformRefEntities(EntityType entityType, Map<String, EntityType> newEntityTypes) { if (newEntityTypes.isEmpty()) { return; } stream(entityType.getAtomicAttributes()) .filter(EntityTypeUtils::isReferenceType) .forEach(attr -> transformRefEntity(attr, newEntityTypes)); } }
RelationTransformer { static void transformRefEntities(EntityType entityType, Map<String, EntityType> newEntityTypes) { if (newEntityTypes.isEmpty()) { return; } stream(entityType.getAtomicAttributes()) .filter(EntityTypeUtils::isReferenceType) .forEach(attr -> transformRefEntity(attr, newEntityTypes)); } private  RelationTransformer(); }
RelationTransformer { static void transformRefEntities(EntityType entityType, Map<String, EntityType> newEntityTypes) { if (newEntityTypes.isEmpty()) { return; } stream(entityType.getAtomicAttributes()) .filter(EntityTypeUtils::isReferenceType) .forEach(attr -> transformRefEntity(attr, newEntityTypes)); } private  RelationTransformer();  }
RelationTransformer { static void transformRefEntities(EntityType entityType, Map<String, EntityType> newEntityTypes) { if (newEntityTypes.isEmpty()) { return; } stream(entityType.getAtomicAttributes()) .filter(EntityTypeUtils::isReferenceType) .forEach(attr -> transformRefEntity(attr, newEntityTypes)); } private  RelationTransformer();   }