Mercurial > dive4elements > river
diff flys-artifacts/src/main/java/de/intevation/flys/exports/AbstractExporter.java @ 2035:3ebbe497d7f7
#252 Set titles in waterlevel exports to named main values if those are existing for given Q values.
flys-artifacts/trunk@3504 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Wed, 21 Dec 2011 09:17:23 +0000 |
parents | a7c437c9547e |
children | f73036b991e2 |
line wrap: on
line diff
--- a/flys-artifacts/src/main/java/de/intevation/flys/exports/AbstractExporter.java Tue Dec 20 15:14:54 2011 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/exports/AbstractExporter.java Wed Dec 21 09:17:23 2011 +0000 @@ -124,7 +124,10 @@ return; } - addData(artifactFacet.getData(context)); + Object data = artifactFacet.getData(context); + prepareData(artifactFacet, data); + + addData(data); } @@ -202,6 +205,19 @@ /** + * This method can be used to prepare data items before they are injected + * into the exporter using <i>addData()</i>. The method in this + * implementation is empty and doesn't do anything. + * + * @param aaf The wrapper for the Artifact and Facet. + * @param data The data object. + */ + protected void prepareData(ArtifactAndFacet aaf, Object data) { + // override me in subclasses + } + + + /** * This method starts CSV creation. It makes use of writeCSVData() which has * to be implemented by concrete subclasses. */