comparison gnv-artifacts/src/main/java/de/intevation/gnv/artifacts/GNVArtifactBase.java @ 594:5b9b74c08bbb

Changed Method signatures because of Interfacemodifications in the Artifact-Module gnv-artifacts/trunk@650 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Tim Englich <tim.englich@intevation.de>
date Mon, 01 Feb 2010 14:03:01 +0000
parents ca5048e4e515
children 9681ac6b6527
comparison
equal deleted inserted replaced
593:b248531fa20b 594:5b9b74c08bbb
1 /** 1 /**
2 * 2 *
3 */ 3 */
4 package de.intevation.gnv.artifacts; 4 package de.intevation.gnv.artifacts;
5 5
6 import java.io.IOException;
7 import java.io.OutputStream;
8 import java.util.ArrayList;
9 import java.util.Collection;
10 import java.util.HashMap;
11 import java.util.Iterator;
12 import java.util.List;
13 import java.util.Map;
14
15 import javax.xml.xpath.XPathConstants;
16
17 import net.sf.ehcache.Cache;
18
19 import org.apache.log4j.Logger;
20 import org.w3c.dom.Document;
21 import org.w3c.dom.Element;
22 import org.w3c.dom.Node;
23 import org.w3c.dom.NodeList;
24
6 import de.intevation.artifactdatabase.Config; 25 import de.intevation.artifactdatabase.Config;
7 import de.intevation.artifactdatabase.ProxyArtifact; 26 import de.intevation.artifactdatabase.ProxyArtifact;
8 import de.intevation.artifactdatabase.XMLUtils; 27 import de.intevation.artifactdatabase.XMLUtils;
9
10 import de.intevation.artifacts.Artifact; 28 import de.intevation.artifacts.Artifact;
11 import de.intevation.artifacts.ArtifactDatabase; 29 import de.intevation.artifacts.ArtifactDatabase;
12 import de.intevation.artifacts.ArtifactFactory; 30 import de.intevation.artifacts.ArtifactFactory;
13 import de.intevation.artifacts.ArtifactNamespaceContext; 31 import de.intevation.artifacts.ArtifactNamespaceContext;
14 import de.intevation.artifacts.CallContext; 32 import de.intevation.artifacts.CallContext;
15 import de.intevation.artifacts.CallMeta; 33 import de.intevation.artifacts.CallMeta;
16
17 import de.intevation.gnv.artifacts.cache.CacheFactory; 34 import de.intevation.gnv.artifacts.cache.CacheFactory;
18
19 import de.intevation.gnv.artifacts.context.GNVArtifactContext; 35 import de.intevation.gnv.artifacts.context.GNVArtifactContext;
20
21 import de.intevation.gnv.artifacts.fis.product.Product; 36 import de.intevation.gnv.artifacts.fis.product.Product;
22
23 import de.intevation.gnv.artifacts.ressource.RessourceFactory; 37 import de.intevation.gnv.artifacts.ressource.RessourceFactory;
24
25 import de.intevation.gnv.state.DefaultInputData; 38 import de.intevation.gnv.state.DefaultInputData;
26 import de.intevation.gnv.state.InputData; 39 import de.intevation.gnv.state.InputData;
27 import de.intevation.gnv.state.InputValue; 40 import de.intevation.gnv.state.InputValue;
28 import de.intevation.gnv.state.OutputMode; 41 import de.intevation.gnv.state.OutputMode;
29 import de.intevation.gnv.state.OutputState; 42 import de.intevation.gnv.state.OutputState;
30 import de.intevation.gnv.state.State; 43 import de.intevation.gnv.state.State;
31 import de.intevation.gnv.state.StateBase; 44 import de.intevation.gnv.state.StateBase;
32 import de.intevation.gnv.state.StateFactory; 45 import de.intevation.gnv.state.StateFactory;
33
34 import de.intevation.gnv.state.exception.StateException; 46 import de.intevation.gnv.state.exception.StateException;
35
36 import de.intevation.gnv.transition.Transition; 47 import de.intevation.gnv.transition.Transition;
37 import de.intevation.gnv.transition.TransitionFactory; 48 import de.intevation.gnv.transition.TransitionFactory;
38
39 import de.intevation.gnv.utils.ArtifactXMLUtilities; 49 import de.intevation.gnv.utils.ArtifactXMLUtilities;
40
41 import java.io.IOException;
42 import java.io.OutputStream;
43
44 import java.util.ArrayList;
45 import java.util.Collection;
46 import java.util.HashMap;
47 import java.util.Iterator;
48 import java.util.List;
49 import java.util.Map;
50
51 import javax.xml.xpath.XPathConstants;
52
53 import net.sf.ehcache.Cache;
54
55 import org.apache.log4j.Logger;
56
57 import org.w3c.dom.Document;
58 import org.w3c.dom.Element;
59 import org.w3c.dom.Node;
60 import org.w3c.dom.NodeList;
61 50
62 /** 51 /**
63 * @author Tim Englich (tim.englich@intevation.de) 52 * @author Tim Englich (tim.englich@intevation.de)
64 * @author Ingo Weinzierl (ingo.weinzierl@intevation.de) 53 * @author Ingo Weinzierl (ingo.weinzierl@intevation.de)
65 * @author Sascha L. Teichmann (sascha.teichmann@intevation.de) 54 * @author Sascha L. Teichmann (sascha.teichmann@intevation.de)
210 String fis = product.getArtifactFactory(); 199 String fis = product.getArtifactFactory();
211 ArtifactDatabase db = context.getDatabase(); 200 ArtifactDatabase db = context.getDatabase();
212 GNVProductArtifactFactory fac = (GNVProductArtifactFactory) 201 GNVProductArtifactFactory fac = (GNVProductArtifactFactory)
213 db.getInternalArtifactFactory(fis); 202 db.getInternalArtifactFactory(fis);
214 203
215 Artifact select = fac.createArtifact(identifier, context); 204 Artifact select = fac.createArtifact(identifier, context, null);
216 context.putContextValue(ProxyArtifact.REPLACE_PROXY, select); 205 context.putContextValue(ProxyArtifact.REPLACE_PROXY, select);
217 206
218 resetDescribeData(current, identifier, INITIAL_STATE); 207 resetDescribeData(current, identifier, INITIAL_STATE);
219 208
220 result = createReport( 209 result = createReport(
449 438
450 return document; 439 return document;
451 } 440 }
452 441
453 /** 442 /**
454 * @see de.intevation.artifactdatabase.DefaultArtifact#setup(java.lang.String, 443 * @see de.intevation.artifactdatabase.DefaultArtifact#setup(java.lang.String, de.intevation.artifacts.ArtifactFactory, java.lang.Object, org.w3c.dom.Document)
455 * java.lang.Object)
456 */ 444 */
457 @Override 445 @Override
458 public void setup(String identifier, ArtifactFactory factory, Object context) { 446 public void setup(String identifier, ArtifactFactory factory,
447 Object context,Document data) {
459 log.debug("GNVArtifactBase.setup"); 448 log.debug("GNVArtifactBase.setup");
460 super.setup(identifier, factory, context); 449 super.setup(identifier, factory, context, data);
461 450
462 Object localContext = context; 451 Object localContext = context;
463 if (context instanceof CallContext) { 452 if (context instanceof CallContext) {
464 localContext = ((CallContext) context).globalContext(); 453 localContext = ((CallContext) context).globalContext();
465 454

http://dive4elements.wald.intevation.org