forked from antonis.lempesis/dnet-hadoop
This commit is contained in:
parent
44e1c40c42
commit
d7d84c8217
|
@ -72,8 +72,9 @@ public class ResultTagger implements Serializable {
|
||||||
// tagging for Subject
|
// tagging for Subject
|
||||||
final Set<String> subjects = new HashSet<>();
|
final Set<String> subjects = new HashSet<>();
|
||||||
|
|
||||||
if (Objects.nonNull(result.getSubject())){
|
if (Objects.nonNull(result.getSubject())) {
|
||||||
result.getSubject()
|
result
|
||||||
|
.getSubject()
|
||||||
.stream()
|
.stream()
|
||||||
.map(subject -> subject.getValue())
|
.map(subject -> subject.getValue())
|
||||||
.filter(StringUtils::isNotBlank)
|
.filter(StringUtils::isNotBlank)
|
||||||
|
@ -91,13 +92,13 @@ public class ResultTagger implements Serializable {
|
||||||
|
|
||||||
if (Objects.nonNull(result.getInstance())) {
|
if (Objects.nonNull(result.getInstance())) {
|
||||||
for (Instance i : result.getInstance()) {
|
for (Instance i : result.getInstance()) {
|
||||||
if(Objects.nonNull(i.getCollectedfrom())){
|
if (Objects.nonNull(i.getCollectedfrom())) {
|
||||||
if(Objects.nonNull(i.getCollectedfrom().getKey())){
|
if (Objects.nonNull(i.getCollectedfrom().getKey())) {
|
||||||
tmp.add(StringUtils.substringAfter(i.getCollectedfrom().getKey(), "|"));
|
tmp.add(StringUtils.substringAfter(i.getCollectedfrom().getKey(), "|"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(Objects.nonNull(i.getHostedby())){
|
if (Objects.nonNull(i.getHostedby())) {
|
||||||
if(Objects.nonNull(i.getHostedby().getKey())){
|
if (Objects.nonNull(i.getHostedby().getKey())) {
|
||||||
tmp.add(StringUtils.substringAfter(i.getHostedby().getKey(), "|"));
|
tmp.add(StringUtils.substringAfter(i.getHostedby().getKey(), "|"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue