Statistics
| Revision:

root / trunk / libraries / libGPE / src-test / org / gvsig / gpe / containers / Layer.java @ 11247

History | View | Annotate | Download (3.41 KB)

1
package org.gvsig.gpe.containers;
2

    
3
import java.util.ArrayList;
4

    
5
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
6
 *
7
 * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
8
 *
9
 * This program is free software; you can redistribute it and/or
10
 * modify it under the terms of the GNU General Public License
11
 * as published by the Free Software Foundation; either version 2
12
 * of the License, or (at your option) any later version.
13
 *
14
 * This program is distributed in the hope that it will be useful,
15
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17
 * GNU General Public License for more details.
18
 *
19
 * You should have received a copy of the GNU General Public License
20
 * along with this program; if not, write to the Free Software
21
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
22
 *
23
 * For more information, contact:
24
 *
25
 *  Generalitat Valenciana
26
 *   Conselleria d'Infraestructures i Transport
27
 *   Av. Blasco Ib??ez, 50
28
 *   46010 VALENCIA
29
 *   SPAIN
30
 *
31
 *      +34 963862235
32
 *   gvsig@gva.es
33
 *      www.gvsig.gva.es
34
 *
35
 *    or
36
 *
37
 *   IVER T.I. S.A
38
 *   Salamanca 50
39
 *   46005 Valencia
40
 *   Spain
41
 *
42
 *   +34 963163400
43
 *   dac@iver.es
44
 */
45
/* CVS MESSAGES:
46
 *
47
 * $Id: Layer.java 11247 2007-04-19 07:30:40Z jorpiell $
48
 * $Log$
49
 * Revision 1.2  2007-04-19 07:23:20  jorpiell
50
 * Add the add methods to teh contenhandler and change the register mode
51
 *
52
 * Revision 1.1  2007/04/14 16:06:35  jorpiell
53
 * Add the container classes
54
 *
55
 *
56
 */
57
/**
58
 * @author Jorge Piera LLodr? (jorge.piera@iver.es)
59
 */
60
public class Layer {
61
        private String name = null;
62
        private String description = null;
63
        private String id = null;
64
        private Layer parentLayer = null;
65
        private ArrayList features = new ArrayList();
66
        private String srs = null;
67
        private Bbox bbox = null;
68
        
69
        /**
70
         * @return the bbox
71
         */
72
        public Bbox getBbox() {
73
                return bbox;
74
        }
75

    
76
        /**
77
         * @param bbox the bbox to set
78
         */
79
        public void setBbox(Object bbox) {
80
                if (bbox != null){
81
                        this.bbox = (Bbox)bbox;
82
                }
83
        }
84

    
85
        /**
86
         * @return the srs
87
         */
88
        public String getSrs() {
89
                return srs;
90
        }
91

    
92
        /**
93
         * @param srs the srs to set
94
         */
95
        public void setSrs(String srs) {
96
                this.srs = srs;
97
        }
98

    
99
        public Layer() {
100
                super();
101
        }
102

    
103
        /**
104
         * @return the description
105
         */
106
        public String getDescription() {
107
                return description;
108
        }
109

    
110
        /**
111
         * @param description the description to set
112
         */
113
        public void setDescription(String description) {
114
                this.description = description;
115
        }
116

    
117
        /**
118
         * @return the id
119
         */
120
        public String getId() {
121
                return id;
122
        }
123

    
124
        /**
125
         * @param id the id to set
126
         */
127
        public void setId(String id) {
128
                this.id = id;
129
        }
130

    
131
        /**
132
         * @return the name
133
         */
134
        public String getName() {
135
                return name;
136
        }
137

    
138
        /**
139
         * @param name the name to set
140
         */
141
        public void setName(String name) {
142
                this.name = name;
143
        }
144
        
145
        /**
146
         * @return the features
147
         */
148
        public ArrayList getFeatures() {
149
                return features;
150
        }
151
        
152
        /**
153
         * Adds a new layer
154
         * @param layer
155
         */
156
        public void addFeature(Feature feature){
157
                features.add(feature);
158
        }
159
        
160
        /**
161
         * Adds a new layer
162
         * @param layer
163
         */
164
        public void addFeature(Object feature){
165
                if (feature instanceof Feature){
166
                        features.add(feature);
167
                }
168
        }
169

    
170
        /**
171
         * @return the parentLayer
172
         */
173
        public Layer getParentLayer() {
174
                return parentLayer;
175
        }
176

    
177
        /**
178
         * @param parentLayer the parentLayer to set
179
         */
180
        public void setParentLayer(Object parentLayer) {
181
                if (parentLayer != null){
182
                        this.parentLayer = (Layer)parentLayer;
183
                }
184
        }
185
}