/[schmitzm]/trunk/src/skrueger/AttributeMetadataInterface.java
ViewVC logotype

Annotation of /trunk/src/skrueger/AttributeMetadataInterface.java

Parent Directory Parent Directory | Revision Log Revision Log


Revision 772 - (hide annotations)
Sun Mar 21 14:05:26 2010 UTC (14 years, 11 months ago) by alfonx
File size: 3328 byte(s)
The new Interface AttributeMetadata has been renamed to AttributeMetadataInterface. 

1 alfonx 244 package skrueger;
2    
3 alfonx 772 import java.io.Serializable;
4 alfonx 658 import java.util.HashSet;
5 alfonx 772 import java.util.Set;
6 alfonx 518
7 alfonx 770 import org.geotools.feature.NameImpl;
8 alfonx 464 import org.opengis.feature.type.Name;
9 alfonx 244
10 alfonx 420 import skrueger.geotools.Copyable;
11 alfonx 244 import skrueger.i8n.Translation;
12    
13 alfonx 772 public interface AttributeMetadataInterface extends Copyable<AttributeMetadataInterface>,
14     Comparable<AttributeMetadataInterface> {
15 alfonx 681
16 alfonx 534 /**
17 alfonx 769 * @return a translatable title for this attribute..
18 alfonx 244 */
19 alfonx 769 public Translation getTitle();
20 alfonx 464
21 alfonx 244 /**
22 alfonx 769 * Set a translatable title for this attribute..
23 alfonx 658 */
24 alfonx 769 public void setTitle(Translation title);
25 alfonx 772
26     /**
27     * Set an untranslated title for this attribute or pass a {@link Translation} encryped as a {@link String}
28     */
29     public void setTitle(String title);
30 alfonx 658
31     /**
32 alfonx 769 * @return a translatable description for this attribute
33 alfonx 534 */
34 alfonx 769 public Translation getDesc();
35 alfonx 534
36     /**
37 alfonx 769 * Set a translatable description for this attribute.
38 alfonx 534 */
39 alfonx 769 public void setDesc(Translation desc);
40 alfonx 534
41     /**
42 alfonx 772 * Set an untranslated description for this attribute or pass a {@link Translation} encryped as a {@link String}
43     */
44     public void setDesc(String desc);
45    
46    
47     /**
48 alfonx 769 * The local name. E.g. the name of the DBF column as a {@link String}.
49 alfonx 244 */
50 alfonx 769 public String getLocalName();
51 alfonx 244
52 alfonx 464 /**
53 alfonx 769 * A short form for #setName(new NameImpl(localName))
54 alfonx 464 */
55 alfonx 769 public void setLocalName(String localName);
56 alfonx 464
57     /**
58 alfonx 769 * The fully qualified {@link Name} of the attribute, e.g.
59     * <code>org.bla.plo:blub</code>. The second part equals the
60     * {@link #getLocalName()} value. The first may be <code>null</code> or
61     * represent the layer name.
62 alfonx 464 */
63 alfonx 770 public NameImpl getName();
64 alfonx 464
65     /**
66 alfonx 769 * set the fully qualified {@link Name} of this attribute.
67 alfonx 464 */
68 alfonx 770 public void setName(NameImpl name);
69 alfonx 464
70     /**
71 alfonx 769 * A list og objects that represent NODATA-values for this attribute. The
72     * objects are supporsed to be correctly casted already. That means that the
73     * NODATA objects listed here have must have the same type as the values of
74     * this object.
75 alfonx 464 */
76 alfonx 769 public HashSet<Object> getNodataValues();
77 alfonx 464
78 alfonx 534 /**
79 alfonx 769 * Takes any value object and checks it against the NODATA values. If the
80     * value equals a NODATA value, <code>null</code> is returned. Otherwise the
81     * same object is returned.
82     *
83     * Note: This method is called often.
84 alfonx 534 */
85 alfonx 769 public Object fiterNodata(Object value);
86 alfonx 534
87     /**
88 alfonx 769 * @return a non-translatable unit {@link String} for this attribute values.
89 alfonx 534 */
90 alfonx 769 public String getUnit();
91 alfonx 244
92 alfonx 534 /**
93 alfonx 769 * Set a unit {@link String} for this attribute values.
94 alfonx 534 */
95 alfonx 769 public void setUnit(String unit);
96 alfonx 244
97 alfonx 534 /**
98 alfonx 769 * @return A value defining the position of this attribute whenever the
99     * attributes are listed to an end-user. The higher the weight, the
100     * lower the position. (heavy goes down, light goes up)
101 alfonx 534 */
102 alfonx 769 public double getWeight();
103 alfonx 534
104     /**
105 alfonx 769 * set a value defining the position of this attribute whenever the
106     * attributes are listed to an end-user. The higher the weight, the lower
107     * the position. (heavy goes down, light goes up)
108 alfonx 534 */
109 alfonx 769 public void setWeight(double weight);
110 alfonx 464
111     /**
112 alfonx 769 * @return <code>false</code> if this attribute should not be selectable or
113     * shown to the end-user.
114 alfonx 464 */
115 alfonx 769 public boolean isVisible();
116 alfonx 464
117     /**
118 alfonx 769 * Set <code>false</code> if this attribute should not be shown to the
119     * end-user.
120 alfonx 464 */
121 alfonx 769 public void setVisible(boolean visible);
122 alfonx 464
123 alfonx 769 String getNoDataValuesFormatted();
124 alfonx 681
125 alfonx 244 }

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26