1
0
Fork 0

added default trust to context bulktagged

This commit is contained in:
Miriam Baglioni 2020-08-04 10:13:25 +02:00
parent f9342cb484
commit 88e4c3b751
1 changed files with 6 additions and 8 deletions

View File

@ -20,8 +20,6 @@ import eu.dnetlib.dhp.schema.oaf.*;
/** Created by miriam on 02/08/2018. */ /** Created by miriam on 02/08/2018. */
public class ResultTagger implements Serializable { public class ResultTagger implements Serializable {
private boolean clearContext(Result result) { private boolean clearContext(Result result) {
int tmp = result.getContext().size(); int tmp = result.getContext().size();
List<Context> clist = result List<Context> clist = result
@ -172,7 +170,7 @@ public class ResultTagger implements Serializable {
BULKTAG_DATA_INFO_TYPE, BULKTAG_DATA_INFO_TYPE,
CLASS_ID_SUBJECT, CLASS_ID_SUBJECT,
CLASS_NAME_BULKTAG_SUBJECT, CLASS_NAME_BULKTAG_SUBJECT,
TAGGING_TRUST)); TAGGING_TRUST));
if (datasources.contains(c.getId())) if (datasources.contains(c.getId()))
dataInfoList dataInfoList
.add( .add(
@ -180,7 +178,7 @@ public class ResultTagger implements Serializable {
BULKTAG_DATA_INFO_TYPE, BULKTAG_DATA_INFO_TYPE,
CLASS_ID_DATASOURCE, CLASS_ID_DATASOURCE,
CLASS_NAME_BULKTAG_DATASOURCE, CLASS_NAME_BULKTAG_DATASOURCE,
TAGGING_TRUST)); TAGGING_TRUST));
if (czenodo.contains(c.getId())) if (czenodo.contains(c.getId()))
dataInfoList dataInfoList
.add( .add(
@ -188,7 +186,7 @@ public class ResultTagger implements Serializable {
BULKTAG_DATA_INFO_TYPE, BULKTAG_DATA_INFO_TYPE,
CLASS_ID_CZENODO, CLASS_ID_CZENODO,
CLASS_NAME_BULKTAG_ZENODO, CLASS_NAME_BULKTAG_ZENODO,
TAGGING_TRUST)); TAGGING_TRUST));
} }
return c; return c;
}) })
@ -215,7 +213,7 @@ public class ResultTagger implements Serializable {
BULKTAG_DATA_INFO_TYPE, BULKTAG_DATA_INFO_TYPE,
CLASS_ID_SUBJECT, CLASS_ID_SUBJECT,
CLASS_NAME_BULKTAG_SUBJECT, CLASS_NAME_BULKTAG_SUBJECT,
TAGGING_TRUST)); TAGGING_TRUST));
if (datasources.contains(c)) if (datasources.contains(c))
dataInfoList dataInfoList
.add( .add(
@ -223,7 +221,7 @@ public class ResultTagger implements Serializable {
BULKTAG_DATA_INFO_TYPE, BULKTAG_DATA_INFO_TYPE,
CLASS_ID_DATASOURCE, CLASS_ID_DATASOURCE,
CLASS_NAME_BULKTAG_DATASOURCE, CLASS_NAME_BULKTAG_DATASOURCE,
TAGGING_TRUST)); TAGGING_TRUST));
if (czenodo.contains(c)) if (czenodo.contains(c))
dataInfoList dataInfoList
.add( .add(
@ -231,7 +229,7 @@ public class ResultTagger implements Serializable {
BULKTAG_DATA_INFO_TYPE, BULKTAG_DATA_INFO_TYPE,
CLASS_ID_CZENODO, CLASS_ID_CZENODO,
CLASS_NAME_BULKTAG_ZENODO, CLASS_NAME_BULKTAG_ZENODO,
TAGGING_TRUST)); TAGGING_TRUST));
context.setDataInfo(dataInfoList); context.setDataInfo(dataInfoList);
return context; return context;
}) })