comparison flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/minfo/FlowVelocityMeasurementFacet.java @ 4452:bdf321802d3d

Add FlowVelocityMeasurementArtifact and -facet. Yet dummies.
author Felix Wolfsteller <felix.wolfsteller@intevation.de>
date Thu, 08 Nov 2012 16:50:46 +0100
parents
children b66285ece774
comparison
equal deleted inserted replaced
4451:e2d8f344491e 4452:bdf321802d3d
1 package de.intevation.flys.artifacts.model.minfo;
2
3 import de.intevation.artifacts.Artifact;
4 import de.intevation.artifacts.CallContext;
5 import de.intevation.flys.artifacts.FlowVelocityMeasurementArtifact;
6 import de.intevation.flys.artifacts.model.BlackboardDataFacet;
7 import de.intevation.flys.artifacts.model.FacetTypes;
8
9
10 /** Facet to show measured flow velocity. */
11 public class FlowVelocityMeasurementFacet
12 extends BlackboardDataFacet
13 implements FacetTypes {
14
15 public FlowVelocityMeasurementFacet(String description) {
16 this(FLOW_VELOCITY_MEASUREMENT, description);
17 }
18
19
20 public FlowVelocityMeasurementFacet(String name, String description) {
21 this.name = name;
22 this.description = description;
23 this.index = 0;
24 }
25
26
27 /**
28 * Returns the data this facet requires.
29 *
30 * @param artifact the owner artifact.
31 * @param context the CallContext (ignored).
32 *
33 * @return the data.
34 */
35 @Override
36 public Object getData(Artifact artifact, CallContext context) {
37 FlowVelocityMeasurementArtifact staticData =
38 (FlowVelocityMeasurementArtifact) artifact;
39 //TODO: impl like return staticData.getVelocity();
40 return null;
41 }
42
43
44 /**
45 * Create a deep copy of this Facet.
46 * @return a deep copy.
47 */
48 @Override
49 public FlowVelocityMeasurementFacet deepCopy() {
50 FlowVelocityMeasurementFacet copy = new FlowVelocityMeasurementFacet(description);
51 copy.set(this);
52 return copy;
53 }
54 }
55 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :

http://dive4elements.wald.intevation.org