forked from D-Net/dnet-hadoop
replaced null value
This commit is contained in:
parent
b0290dbcb7
commit
210a50e4f4
|
@ -167,10 +167,9 @@ public class PublicationToOaf implements Serializable {
|
||||||
final String source = getStringValue(rootElement, "sourceName");
|
final String source = getStringValue(rootElement, "sourceName");
|
||||||
if (StringUtils.isNotBlank(source)) {
|
if (StringUtils.isNotBlank(source)) {
|
||||||
Field<String> sourceField = mapStringField(source, null);
|
Field<String> sourceField = mapStringField(source, null);
|
||||||
if (sourceField==null) {
|
if (sourceField == null) {
|
||||||
publication.setSource(null);
|
publication.setSource(null);
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
publication.setSource(Arrays.asList(sourceField));
|
publication.setSource(Arrays.asList(sourceField));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -191,7 +190,7 @@ public class PublicationToOaf implements Serializable {
|
||||||
.map(t -> {
|
.map(t -> {
|
||||||
return mapStructuredProperty(t, q, null);
|
return mapStructuredProperty(t, q, null);
|
||||||
})
|
})
|
||||||
.filter(s -> s!=null)
|
.filter(s -> s != null)
|
||||||
.collect(Collectors.toList()));
|
.collect(Collectors.toList()));
|
||||||
// Adding identifier
|
// Adding identifier
|
||||||
final String id = getStringValue(rootElement, "id");
|
final String id = getStringValue(rootElement, "id");
|
||||||
|
@ -383,7 +382,8 @@ public class PublicationToOaf implements Serializable {
|
||||||
.map(r -> {
|
.map(r -> {
|
||||||
return mapStructuredProperty(r, q, null);
|
return mapStructuredProperty(r, q, null);
|
||||||
})
|
})
|
||||||
.filter(s -> s!=null).collect(Collectors.toList()));
|
.filter(s -> s != null)
|
||||||
|
.collect(Collectors.toList()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue