@Test void testCreateRfdModelNullValue() { when(objectEntity.getEntityType()).thenReturn(entityType); when(entityType.getAtomicAttributes()).thenReturn(List.of(attribute)); when(objectEntity.get("attributeName1")).thenReturn(null); when(attribute.getName()).thenReturn("attributeName1"); Model result = writer.createRdfModel(objectEntity); assertTrue(result.isEmpty()); }
public Model createRdfModel(Entity objectEntity) { Model model = createEmptyModel(); Resource subject = createResource(objectEntity); addEntityToModel(subject, objectEntity, model); return model; }
EntityModelWriter { public Model createRdfModel(Entity objectEntity) { Model model = createEmptyModel(); Resource subject = createResource(objectEntity); addEntityToModel(subject, objectEntity, model); return model; } }
EntityModelWriter { public Model createRdfModel(Entity objectEntity) { Model model = createEmptyModel(); Resource subject = createResource(objectEntity); addEntityToModel(subject, objectEntity, model); return model; } EntityModelWriter(
      TagService<LabeledResource, LabeledResource> tagService, SimpleValueFactory valueFactory); }
EntityModelWriter { public Model createRdfModel(Entity objectEntity) { Model model = createEmptyModel(); Resource subject = createResource(objectEntity); addEntityToModel(subject, objectEntity, model); return model; } EntityModelWriter(
      TagService<LabeledResource, LabeledResource> tagService, SimpleValueFactory valueFactory); Model createRdfModel(Entity objectEntity); Model createEmptyModel(); void addEntityToModel(Resource subject, Entity objectEntity, Model model); boolean isADcatResource(EntityType entityType); }
EntityModelWriter { public Model createRdfModel(Entity objectEntity) { Model model = createEmptyModel(); Resource subject = createResource(objectEntity); addEntityToModel(subject, objectEntity, model); return model; } EntityModelWriter(
      TagService<LabeledResource, LabeledResource> tagService, SimpleValueFactory valueFactory); Model createRdfModel(Entity objectEntity); Model createEmptyModel(); void addEntityToModel(Resource subject, Entity objectEntity, Model model); boolean isADcatResource(EntityType entityType); static final String NS_DCAT; static final String NS_FDP; static final String NS_R3D; static final String NS_DATACITE; static final String NS_DCT; static final String NS_RDF; }