Mercurial > dive4elements > river
changeset 7204:292330854722
issue1435: Store id of sediment yield only.
author | Felix Wolfsteller <felix.wolfsteller@intevation.de> |
---|---|
date | Mon, 30 Sep 2013 17:30:31 +0200 (2013-09-30) |
parents | 99c5e4148859 |
children | e798658cc0ed |
files | artifacts/src/main/java/org/dive4elements/river/artifacts/SedimentDensityArtifact.java |
diffstat | 1 files changed, 5 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/SedimentDensityArtifact.java Mon Sep 30 17:30:06 2013 +0200 +++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/SedimentDensityArtifact.java Mon Sep 30 17:30:31 2013 +0200 @@ -57,7 +57,6 @@ protected transient State state = null; protected String DATA_ID = "ID"; - protected String DATA_YEAR = "YEAR"; /** * Trivial Constructor. @@ -77,10 +76,9 @@ private Object getSedimentDensity() { logger.debug("SedimentDensityArtifact.getSedimentDensity"); Integer id = getDataAsInteger(DATA_ID); - Integer year = getDataAsInteger(DATA_YEAR); // TODO use cache if possible - return SedimentDensityFactory.getSedimentDensityUncached(id, year); + return SedimentDensityFactory.getSedimentDensityUncached(id); } @@ -123,7 +121,6 @@ { logger.debug("SedimentDensityArtifact.setup"); - // Store id, yield yields. state = newDensityState(); if (logger.isDebugEnabled()) { logger.debug(XMLUtils.toString(data)); @@ -135,13 +132,12 @@ if (code != null) { //String name = SedimentDensityFactory.getSedimentDensityDescription(Integer.valueOf(code)); - //id: and year? String name = "facet"; Facet facet = new SedimentDensityFacet( 0, - SEDIMENT_LOAD_COARSE, + SEDIMENT_DENSITY, name, //???? ComputeType.ADVANCE, state.getID(), "hash" @@ -149,7 +145,9 @@ fs.add(facet); addFacets(state.getID(), fs); addStringData(DATA_ID, code); - addStringData(DATA_YEAR, code); + } + else { + logger.error("No id given."); } spawnState();