comparison artifacts/src/main/java/org/dive4elements/river/exports/process/BedDiffHeightYearProcessor.java @ 9123:1cc7653ca84f

Cleanup of ChartGenerator and ChartGenerator2 code. Put some of the copy/pasted code into a common abstraction.
author gernotbelger
date Tue, 05 Jun 2018 19:21:16 +0200
parents 5e38e2924c07
children 9b8e8fc1f408
comparison
equal deleted inserted replaced
9122:b8e7f6becf78 9123:1cc7653ca84f
41 DiagramGenerator generator, 41 DiagramGenerator generator,
42 ArtifactAndFacet bundle, 42 ArtifactAndFacet bundle,
43 ThemeDocument theme, 43 ThemeDocument theme,
44 boolean visible 44 boolean visible
45 ) { 45 ) {
46 CallContext context = generator.getCallContext(); 46 CallContext context = generator.getContext();
47 Object data = bundle.getData(context); 47 Object data = bundle.getData(context);
48 Map<String, String> metaData = bundle.getFacet().getMetaData( 48 Map<String, String> metaData = bundle.getFacet().getMetaData(
49 bundle.getArtifact(), context); 49 bundle.getArtifact(), context);
50 50
51 if (!(data instanceof double[][])) { 51 if (!(data instanceof double[][])) {
72 ArtifactAndFacet bundle, 72 ArtifactAndFacet bundle,
73 ThemeDocument theme, 73 ThemeDocument theme,
74 boolean visible, 74 boolean visible,
75 int index 75 int index
76 ) { 76 ) {
77 CallContext context = generator.getCallContext(); 77 CallContext context = generator.getContext();
78 Object data = bundle.getData(context); 78 Object data = bundle.getData(context);
79 79
80 if (!(data instanceof double[][])) { 80 if (!(data instanceof double[][])) {
81 // Should not happen if canHandle is correct 81 // Should not happen if canHandle is correct
82 log.error("Can't process " + data.getClass().getName() 82 log.error("Can't process " + data.getClass().getName()

http://dive4elements.wald.intevation.org