Statistics
| Revision:

svn-gvsig-desktop / branches / v2_0_0_prep / applications / appgvSIG / src / org / gvsig / app / daltransform / gui / FeatureTransformWizardModel.java @ 28833

History | View | Annotate | Download (3.69 KB)

1
/* gvSIG. Geographic Information System of the Valencian Government
2
 *
3
 * Copyright (C) 2007-2008 Infrastructures and Transports Department
4
 * of the Valencian Government (CIT)
5
 * 
6
 * This program is free software; you can redistribute it and/or
7
 * modify it under the terms of the GNU General Public License
8
 * as published by the Free Software Foundation; either version 2
9
 * of the License, or (at your option) any later version.
10
 * 
11
 * This program is distributed in the hope that it will be useful,
12
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14
 * GNU General Public License for more details.
15
 * 
16
 * You should have received a copy of the GNU General Public License
17
 * along with this program; if not, write to the Free Software
18
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
19
 * MA  02110-1301, USA.
20
 * 
21
 */
22

    
23
/*
24
 * AUTHORS (In addition to CIT):
25
 * 2009 {Iver T.I.}   {Task}
26
 */
27

    
28
package org.gvsig.app.daltransform.gui;
29

    
30
import org.gvsig.fmap.dal.feature.FeatureStore;
31
import org.gvsig.fmap.dal.feature.FeatureStoreTransform;
32
import org.gvsig.fmap.mapcontext.MapContext;
33

    
34
import com.iver.andami.ui.wizard.WizardAndami;
35

    
36
/**
37
 * This class contains all the panels that are displayed 
38
 * in the wizard to apply a feature transformation.
39
 * 
40
 * @author <a href="mailto:jpiera@gvsig.org">Jorge Piera</a>
41
 */
42
public class FeatureTransformWizardModel {
43
        private WizardAndami wizard = null;
44
        private SelectTransformWizard selectTransformWizard = null;
45
        private SelectDataStoreWizard selectDataStoreWizard = null;
46
        private SelectTransformParamsWizard selectTransformParamsWizard = null;
47
        private LoadLayerWizard loadLayerWizard = null;
48
        
49
        /**
50
         * @param wizard
51
         */
52
        public FeatureTransformWizardModel(WizardAndami wizard) {
53
                super();
54
                this.wizard = wizard;
55
                initialize();
56
        }
57

    
58
        private void initialize(){        
59
                selectTransformWizard = new SelectTransformWizard(this);
60
                selectDataStoreWizard = new SelectDataStoreWizard(this);
61
                selectTransformParamsWizard = new SelectTransformParamsWizard(this);
62
                loadLayerWizard = new LoadLayerWizard(this);                
63
                wizard.getWizardComponents().addWizardPanel(
64
                                selectTransformWizard);
65
                wizard.getWizardComponents().addWizardPanel(
66
                                selectDataStoreWizard);
67
                wizard.getWizardComponents().addWizardPanel(
68
                                selectTransformParamsWizard);
69
                wizard.getWizardComponents().addWizardPanel(
70
                                loadLayerWizard);
71
        }
72
        
73
        public FeatureTransformGui getSelectedFeatureTransformGui(){
74
                return selectTransformWizard.getSelectedFeatureTransformGui();
75
        }
76
        
77
        public FeatureStore getSelectedFeatureStore(){
78
                 return selectDataStoreWizard.getSelectedFeatureStore();
79
        }
80
        
81
        public FeatureStoreTransform getTransform(){
82
                 return loadLayerWizard.getTransform();
83
        }        
84
        
85
        public boolean isLayerLoaded(){
86
                return loadLayerWizard.isLayerLoaded();
87
        }
88
        
89
        public MapContext getMapContext(){
90
                return loadLayerWizard.getMapContext();
91
        }
92
        
93
        /**
94
         * @return the wizard
95
         */
96
        public WizardAndami getWizard() {
97
                return wizard;
98
        }
99

    
100
        /**
101
         * @return the selectTransformWizard
102
         */
103
        public SelectTransformWizard getSelectTransformWizard() {
104
                return selectTransformWizard;
105
        }
106

    
107
        /**
108
         * @return the selectDataStoreWizard
109
         */
110
        public SelectDataStoreWizard getSelectDataStoreWizard() {
111
                return selectDataStoreWizard;
112
        }
113

    
114
        /**
115
         * @return the selectTransformParamsWizard
116
         */
117
        public SelectTransformParamsWizard getSelectTransformParamsWizard() {
118
                return selectTransformParamsWizard;
119
        }
120

    
121
        /**
122
         * @return the loadLayerWizard
123
         */
124
        public LoadLayerWizard getLoadLayerWizard() {
125
                return loadLayerWizard;
126
        }
127
        
128
        /**
129
         * @return the selected feature store
130
         */
131
        public boolean isSelectedFeatureStoreLoaded(){
132
                return selectDataStoreWizard.isSelectedFeatureStoreLoaded();
133
        }
134
}
135