Project

General

Profile

« Previous | Next » 

Revision 57188

removed project reference from src/test/resources/eu/dnetlib/data/transform/odf.xml, the test didn't include any check against it

View differences:

ProtoMapping.java
100 100
		return p;
101 101
	}
102 102

  
103
	protected static final List<Software> mapRelatedSoftwares(final OafEntity entity) {
104
		final Map<String, Oaf> softwareMap = Maps.newHashMap();
105
		for(Oaf rel : entity.getCachedOafRelList()) {
106
			final OafEntity p = rel.getRel().getCachedOafTarget().getEntity();
107
			softwareMap.put(p.getId(), Oaf.newBuilder(rel).build());
108
		}
109

  
110
		return softwareMap.values().stream()
111
				.map(o -> mapRelatedSoftware(o.getRel().getCachedOafTarget().getEntity().getResult()))
112
				.collect(Collectors.toList());
113
	}
114

  
103 115
	protected static final Software mapRelatedSoftware(final ResultProtos.Result result) {
104 116
		final Software s = new Software();
105 117
		final ResultProtos.Result.Metadata rp = result.getMetadata();

Also available in: Unified diff