Revision 50242
Added by Tsampikos Livisianos over 6 years ago
modules/dnet-openaire-stats/trunk/src/main/java/eu/dnetlib/data/mapreduce/hbase/statsExport/utils/Serializer.java | ||
---|---|---|
507 | 507 |
Qualifier bestLicense = null; |
508 | 508 |
LicenseComparator lc = new LicenseComparator(); |
509 | 509 |
for (Instance instance : (result.getInstanceList())) { |
510 |
if (lc.compare(bestLicense, instance.getLicence()) > 0) {
|
|
511 |
bestLicense = instance.getLicence();
|
|
510 |
if (lc.compare(bestLicense, instance.getAccessright()) > 0) {
|
|
511 |
bestLicense = instance.getAccessright();
|
|
512 | 512 |
} |
513 | 513 |
} |
514 | 514 |
if (bestLicense != null) { |
... | ... | |
522 | 522 |
private static String getAccessMode(Result result) { |
523 | 523 |
String accessMode = " "; |
524 | 524 |
for (Instance instance : (result.getInstanceList())) { |
525 |
if (instance.getLicence().getClassname() != null && !instance.getLicence().getClassname().isEmpty()) {
|
|
526 |
accessMode = instance.getLicence().getClassname();
|
|
525 |
if (instance.getAccessright().getClassname() != null && !instance.getAccessright().getClassname().isEmpty()) {
|
|
526 |
accessMode = instance.getAccessright().getClassname();
|
|
527 | 527 |
break; |
528 | 528 |
} |
529 | 529 |
|
Also available in: Unified diff
replace licence with accessright