comparison gnv-artifacts/src/test/java/de/intevation/gnv/artifacts/TestCallContext.java @ 875:5e9efdda6894

merged gnv-artifacts/1.0
author Thomas Arendsen Hein <thomas@intevation.de>
date Fri, 28 Sep 2012 12:13:56 +0200
parents 9d2891068ba5
children f953c9a559d8
comparison
equal deleted inserted replaced
722:bb3ffe7d719e 875:5e9efdda6894
1 package de.intevation.gnv.artifacts;
2
3 import de.intevation.artifacts.ArtifactDatabase;
4 import de.intevation.artifacts.ArtifactFactory;
5 import de.intevation.artifacts.CallContext;
6 import de.intevation.artifacts.CallMeta;
7
8 /**
9 * @author <a href="mailto:tim.englich@intevation.de">Tim Englich</a>
10 *
11 */
12 public class TestCallContext implements CallContext {
13
14
15
16 private Object globalContext = null;
17 private CallMeta callMeta = null;
18 private ArtifactFactory artifactFactory = null;
19 private ArtifactDatabase artifactDatabase = null;
20 /**
21 * Constructor
22 */
23 public TestCallContext(Object globalContext,
24 CallMeta callMeta,
25 ArtifactFactory artifactFactory) {
26 this.globalContext = globalContext;
27 this.callMeta = callMeta;
28 this.artifactDatabase = new TestArtifactDatabase(artifactFactory);
29 }
30
31 /**
32 * @see de.intevation.artifacts.CallContext#afterBackground(int)
33 */
34 public void afterBackground(int action) {
35 }
36
37 /**
38 * @see de.intevation.artifacts.CallContext#afterCall(int)
39 */
40 public void afterCall(int action) {
41 }
42
43 /**
44 * @see de.intevation.artifacts.CallContext#globalContext()
45 */
46 public Object globalContext() {
47 return this.globalContext;
48 }
49
50 public CallMeta getMeta() {
51 return this.callMeta;
52 }
53
54 public Object getContextValue(Object key) {
55 return null;
56 }
57
58 public Object putContextValue(Object key, Object value) {
59 return null;
60 }
61
62 public ArtifactDatabase getDatabase() {
63 return this.artifactDatabase;
64 }
65
66 public Long getTimeToLive() {
67 throw new UnsupportedOperationException("Not supported yet.");
68 }
69 }

http://dive4elements.wald.intevation.org