applied intellij code cleanup
This commit is contained in:
parent
0e5cf7a7d8
commit
1271bec1f8
|
@ -26,7 +26,7 @@ import eu.dnetlib.dhp.schema.oaf.*;
|
|||
public class ModelSupport {
|
||||
|
||||
/** Defines the mapping between the actual entity type and the main entity type */
|
||||
private static Map<EntityType, MainEntityType> entityMapping = Maps.newHashMap();
|
||||
private static final Map<EntityType, MainEntityType> entityMapping = Maps.newHashMap();
|
||||
|
||||
static {
|
||||
entityMapping.put(EntityType.publication, MainEntityType.result);
|
||||
|
|
|
@ -32,7 +32,7 @@ public class Context extends Qualifier {
|
|||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
String provenance = new String();
|
||||
String provenance = "";
|
||||
this.provenance.forEach(p -> provenance.concat(p.toString()));
|
||||
return Objects.hash(getCode(), getLabel(), provenance);
|
||||
}
|
||||
|
|
|
@ -22,7 +22,7 @@ public class AccessRight extends Qualifier {
|
|||
String s = super.toComparableString();
|
||||
return Optional
|
||||
.ofNullable(getOpenAccessRoute())
|
||||
.map(x -> s + "::" + x.toString())
|
||||
.map(x -> s + "::" + x)
|
||||
.orElse(s);
|
||||
}
|
||||
|
||||
|
|
|
@ -37,10 +37,7 @@ public class CleaningFunctions {
|
|||
if (CleaningFunctions.PID_BLACKLIST.contains(pidValue)) {
|
||||
return false;
|
||||
}
|
||||
if (PidBlacklistProvider.getBlacklist(s.getQualifier().getClassid()).contains(pidValue)) {
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
return !PidBlacklistProvider.getBlacklist(s.getQualifier().getClassid()).contains(pidValue);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -11,7 +11,7 @@ import eu.dnetlib.dhp.schema.oaf.StructuredProperty;
|
|||
|
||||
public class PidComparator<T extends OafEntity> implements Comparator<StructuredProperty> {
|
||||
|
||||
private T entity;
|
||||
private final T entity;
|
||||
|
||||
public PidComparator(T entity) {
|
||||
this.entity = entity;
|
||||
|
|
|
@ -16,7 +16,7 @@ import eu.dnetlib.dhp.schema.oaf.Publication;
|
|||
|
||||
public class IdentifierFactoryTest {
|
||||
|
||||
private static ObjectMapper OBJECT_MAPPER = new ObjectMapper()
|
||||
private static final ObjectMapper OBJECT_MAPPER = new ObjectMapper()
|
||||
.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);
|
||||
|
||||
@Test
|
||||
|
|
Loading…
Reference in New Issue