root / branches / v2_0_0_prep / libraries / libFMap_data / src / org / gvsig / fmap / data / feature / impl / DefaultFeatureRules.java @ 23754
History | View | Annotate | Download (736 Bytes)
1 |
package org.gvsig.fmap.data.feature.impl; |
---|---|
2 |
|
3 |
import java.util.ArrayList; |
4 |
|
5 |
import org.gvsig.fmap.data.feature.FeatureRule; |
6 |
import org.gvsig.fmap.data.feature.FeatureRules; |
7 |
|
8 |
public class DefaultFeatureRules extends ArrayList implements FeatureRules { |
9 |
|
10 |
/**
|
11 |
*
|
12 |
*/
|
13 |
private static final long serialVersionUID = -8084546505498274121L; |
14 |
|
15 |
public FeatureRule add(FeatureRule rule) {
|
16 |
if (super.add(rule)) { |
17 |
return rule;
|
18 |
} |
19 |
return null; |
20 |
} |
21 |
|
22 |
public FeatureRule getRule(int index) { |
23 |
return (FeatureRule) super.get(index); |
24 |
} |
25 |
|
26 |
public boolean remove(FeatureRule rule) { |
27 |
return super.remove(rule); |
28 |
} |
29 |
|
30 |
public FeatureRules getCopy() {
|
31 |
DefaultFeatureRules copy = new DefaultFeatureRules();
|
32 |
copy.addAll(this);
|
33 |
return copy;
|
34 |
} |
35 |
|
36 |
|
37 |
|
38 |
|
39 |
} |