Revision 186

View differences:

org.gvsig.catalog/tags/org.gvsig.catalog-2.0.25/org.gvsig.catalog.lib/pom.xml
1
<?xml version="1.0" encoding="UTF-8"?>
2

  
3
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
4

  
5
  <modelVersion>4.0.0</modelVersion>
6
  <artifactId>org.gvsig.catalog.lib</artifactId>
7
  <packaging>jar</packaging>
8
  <name>${project.artifactId}</name>
9

  
10
  <description>Web Catalog Service library (geodata search)</description>
11
  
12
  <parent>
13
      <groupId>org.gvsig</groupId>
14
      <artifactId>org.gvsig.catalog</artifactId>
15
      <version>2.0.25</version>
16
  </parent>
17
  
18
  <dependencies>
19
  
20
        <dependency>
21
            <groupId>org.slf4j</groupId>
22
            <artifactId>slf4j-api</artifactId>
23
            <scope>compile</scope>
24
        </dependency>
25
        <dependency>
26
            <groupId>org.gvsig</groupId>
27
            <artifactId>org.gvsig.tools.lib</artifactId>
28
            <scope>compile</scope>
29
        </dependency>
30
		<dependency>
31
			<groupId>org.gvsig</groupId>
32
			<artifactId>org.gvsig.compat.api</artifactId>
33
            <scope>compile</scope>
34
		</dependency>
35
		<dependency>
36
			<groupId>org.gvsig</groupId>
37
			<artifactId>org.gvsig.i18n</artifactId>
38
            <scope>compile</scope>
39
		</dependency>
40
		<dependency>
41
			<groupId>org.gvsig</groupId>
42
			<artifactId>org.gvsig.utils</artifactId>
43
            <scope>compile</scope>
44
		</dependency>
45
		<dependency>
46
			<groupId>org.gvsig</groupId>
47
			<artifactId>org.gvsig.remoteclient</artifactId>
48
            <scope>compile</scope>
49
		</dependency>
50
		<dependency>
51
			<groupId>com.vividsolutions</groupId>
52
			<artifactId>jts</artifactId>
53
		</dependency>
54
		<dependency>
55
			<groupId>xerces</groupId>
56
			<artifactId>xercesImpl</artifactId>
57
            <scope>compile</scope>
58
		</dependency>
59
		<dependency>
60
			<groupId>org.dspace</groupId>
61
			<artifactId>cql-java</artifactId>
62
		</dependency>		
63
		<dependency>
64
			<groupId>jdom</groupId>
65
			<artifactId>jdom</artifactId>
66
		</dependency>
67
		<dependency>
68
			<groupId>commons-beanutils</groupId>
69
			<artifactId>commons-beanutils</artifactId>
70
            <scope>compile</scope>
71
		</dependency>
72
		<dependency>
73
			<groupId>commons-httpclient</groupId>
74
			<artifactId>commons-httpclient</artifactId>
75
            <scope>compile</scope>
76
		</dependency>
77
		<dependency>
78
			<groupId>soap</groupId>
79
			<artifactId>soap</artifactId>
80
            <scope>compile</scope>
81
		</dependency>
82
   		<dependency>
83
		    <groupId>org.jzkit</groupId>
84
   			<artifactId>jzkit2-core</artifactId>
85
            <scope>compile</scope>
86
   		</dependency>
87
           <dependency>
88
		    <groupId>org.jzkit</groupId>
89
   			<artifactId>jzkit2-z3950</artifactId>
90
            <scope>compile</scope>
91
   		</dependency>
92
           <dependency>
93
		    <groupId>org.jzkit</groupId>
94
   			<artifactId>jzkit2-origin</artifactId>
95
   		</dependency>
96
	    <dependency>
97
		    <groupId>org.jzkit</groupId>
98
   			<artifactId>a2j-runtime</artifactId>
99
   		</dependency>
100
           <dependency>
101
		    <groupId>org.jzkit</groupId>
102
   			<artifactId>a2j</artifactId>
103
            <scope>compile</scope>
104
   		</dependency>
105
		<dependency>
106
			<groupId>org.springframework</groupId>
107
			<artifactId>spring</artifactId>
108
            <scope>compile</scope>
109
		</dependency>  
110
		<dependency>
111
		    <groupId>net.swing</groupId>
112
   			<artifactId>amic-util</artifactId>
113
            <scope>compile</scope>
114
   		</dependency>	
115
    
116
  </dependencies>
117
  
118
  <build>
119
  
120
		<!-- TODO: MAKE TESTS WORK AND REMOVE THIS OPTION -->
121
		<plugins>
122
			<plugin>
123
				<groupId>org.apache.maven.plugins</groupId>
124
				<artifactId>maven-surefire-plugin</artifactId>
125
				<configuration>
126
					<skipTests>true</skipTests>
127
				</configuration>
128
			</plugin>
129
		</plugins>
130
  
131
  </build>
132

  
133
</project>
0 134

  
org.gvsig.catalog/tags/org.gvsig.catalog-2.0.25/org.gvsig.catalog.lib/src/test/java/org/gvsig/catalog/catalog/drivers/ExampleNewDriver.java
1
package org.gvsig.catalog.catalog.drivers;
2

  
3
import java.net.URI;
4

  
5
import org.gvsig.catalog.CatalogLocator;
6
import org.gvsig.catalog.CatalogManager;
7
import org.gvsig.catalog.drivers.AbstractCatalogServiceDriver;
8
import org.gvsig.catalog.drivers.CatalogCapabilities;
9
import org.gvsig.catalog.drivers.DiscoveryServiceCapabilities;
10
import org.gvsig.catalog.drivers.GetRecordsReply;
11
import org.gvsig.catalog.querys.CatalogQuery;
12
import org.gvsig.catalog.schemas.Record;
13
import org.gvsig.catalog.ui.search.SearchAditionalPropertiesPanel;
14

  
15

  
16
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
17
 *
18
 * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
19
 *
20
 * This program is free software; you can redistribute it and/or
21
 * modify it under the terms of the GNU General Public License
22
 * as published by the Free Software Foundation; either version 2
23
 * of the License, or (at your option) any later version.
24
 *
25
 * This program is distributed in the hope that it will be useful,
26
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
27
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
28
 * GNU General Public License for more details.
29
 *
30
 * You should have received a copy of the GNU General Public License
31
 * along with this program; if not, write to the Free Software
32
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
33
 *
34
 * For more information, contact:
35
 *
36
 *  Generalitat Valenciana
37
 *   Conselleria d'Infraestructures i Transport
38
 *   Av. Blasco Ib??ez, 50
39
 *   46010 VALENCIA
40
 *   SPAIN
41
 *
42
 *      +34 963862235
43
 *   gvsig@gva.es
44
 *      www.gvsig.gva.es
45
 *
46
 *    or
47
 *
48
 *   IVER T.I. S.A
49
 *   Salamanca 50
50
 *   46005 Valencia
51
 *   Spain
52
 *
53
 *   +34 963163400
54
 *   dac@iver.es
55
 */
56
/* CVS MESSAGES:
57
 *
58
 * $Id: ExampleNewDriver.java 537 2007-07-26 11:21:10Z jpiera $
59
 * $Log$
60
 * Revision 1.1.2.1  2007/07/13 12:00:35  jorpiell
61
 * Add the posibility to add a new panel
62
 *
63
 *
64
 */
65
/**
66
 * @author Jorge Piera LLodr? (jorge.piera@iver.es)
67
 */
68
public class ExampleNewDriver extends AbstractCatalogServiceDriver {
69
	private static final CatalogManager catalogManager = CatalogLocator.getCatalogManager();
70
	
71
	/*
72
	 * (non-Javadoc)
73
	 * @see es.gva.cit.catalogClient.drivers.IDiscoveryServiceDriver#getCapabilities(java.net.URI)
74
	 */
75
	public DiscoveryServiceCapabilities getCapabilities(URI uri) {
76
		return new CatalogCapabilities();
77
	}
78

  
79
	/*
80
	 * (non-Javadoc)
81
	 * @see es.gva.cit.catalog.drivers.ICatalogServiceDriver#getRecords(java.net.URI, es.gva.cit.catalog.querys.CatalogQuery, int)
82
	 */
83
	public GetRecordsReply getRecords(URI uri, CatalogQuery query,
84
			int firstRecord) {
85
		GetRecordsReply reply = new GetRecordsReply(1);
86
		Record record = catalogManager.createRecord(uri, null);
87
		record.setTitle("Record example");
88
		record.setAbstract_("Just for testing");
89
		reply.addRecord(record);
90
		return reply;
91
	}
92

  
93
	/*
94
	 * (non-Javadoc)
95
	 * @see es.gva.cit.catalog.drivers.IDiscoveryServiceDriver#getServiceName()
96
	 */
97
	public String getServiceName() {
98
		return "My catalog service";
99
	}
100

  
101
	/*
102
	 * (non-Javadoc)
103
	 * @see es.gva.cit.gazetteer.drivers.IGazetteerServiceDriver#getAditionalSearchPanel()
104
	 */
105
	public SearchAditionalPropertiesPanel getAditionalSearchPanel(){
106
		return new ExampleNewPanel();
107
	}
108

  
109

  
110

  
111

  
112
}
0 113

  
org.gvsig.catalog/tags/org.gvsig.catalog-2.0.25/org.gvsig.catalog.lib/src/test/java/org/gvsig/catalog/catalog/drivers/ExampleNewDriverTest.java
1
package org.gvsig.catalog.catalog.drivers;
2

  
3
import javax.swing.UIManager;
4
import javax.swing.UnsupportedLookAndFeelException;
5

  
6
import org.gvsig.catalog.CatalogLocator;
7
import org.gvsig.catalog.ui.serverconnect.ServerConnectDialog;
8
import org.gvsig.tools.library.impl.DefaultLibrariesInitializer;
9

  
10

  
11
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
12
 *
13
 * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
14
 *
15
 * This program is free software; you can redistribute it and/or
16
 * modify it under the terms of the GNU General Public License
17
 * as published by the Free Software Foundation; either version 2
18
 * of the License, or (at your option) any later version.
19
 *
20
 * This program is distributed in the hope that it will be useful,
21
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
22
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
23
 * GNU General Public License for more details.
24
 *
25
 * You should have received a copy of the GNU General Public License
26
 * along with this program; if not, write to the Free Software
27
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
28
 *
29
 * For more information, contact:
30
 *
31
 *  Generalitat Valenciana
32
 *   Conselleria d'Infraestructures i Transport
33
 *   Av. Blasco Ib??ez, 50
34
 *   46010 VALENCIA
35
 *   SPAIN
36
 *
37
 *      +34 963862235
38
 *   gvsig@gva.es
39
 *      www.gvsig.gva.es
40
 *
41
 *    or
42
 *
43
 *   IVER T.I. S.A
44
 *   Salamanca 50
45
 *   46005 Valencia
46
 *   Spain
47
 *
48
 *   +34 963163400
49
 *   dac@iver.es
50
 */
51
/* CVS MESSAGES:
52
 *
53
 * $Id: ExampleNewDriverTest.java 512 2007-07-24 11:25:43Z jorpiell $
54
 * $Log$
55
 * Revision 1.1.2.2  2007/07/24 11:25:42  jorpiell
56
 * The registers has been refactorized
57
 *
58
 * Revision 1.1.2.1  2007/07/13 12:00:35  jorpiell
59
 * Add the posibility to add a new panel
60
 *
61
 *
62
 */
63
/**
64
 * @author Jorge Piera LLodr? (jorge.piera@iver.es)
65
 */
66
public class ExampleNewDriverTest {
67

  
68
	/**
69
	 * @param args
70
	 */
71
	public static void main(String[] args) {
72
		new DefaultLibrariesInitializer().fullInitialize();
73
//		DefaultCatalogLibrary library = new DefaultCatalogLibrary();
74
//		library.initialize();
75
//		library.postInitialize();
76

  
77
		CatalogLocator.getCatalogManager().register("My catalog service", ExampleNewDriver.class);
78
		//Get the currently installed look and feel
79
		UIManager.getLookAndFeel();
80
		// Install a different look and feel; specifically, the Windows look and feel
81
		try {
82
			UIManager.setLookAndFeel(
83
					"com.sun.java.swing.plaf.windows.WindowsLookAndFeel");
84
		} catch (InstantiationException e) {
85
		} catch (ClassNotFoundException e) {
86
		} catch (UnsupportedLookAndFeelException e) {
87
		} catch (IllegalAccessException e) {
88
		}
89

  
90
		new ServerConnectDialog();
91
	}
92

  
93
}
0 94

  
org.gvsig.catalog/tags/org.gvsig.catalog-2.0.25/org.gvsig.catalog.lib/src/test/java/org/gvsig/catalog/catalog/drivers/ExampleNewPanel.java
1
package org.gvsig.catalog.catalog.drivers;
2

  
3
import java.util.Properties;
4

  
5
import javax.swing.JLabel;
6
import javax.swing.JTextField;
7

  
8
import org.gvsig.catalog.ui.search.SearchAditionalPropertiesPanel;
9

  
10

  
11
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
12
 *
13
 * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
14
 *
15
 * This program is free software; you can redistribute it and/or
16
 * modify it under the terms of the GNU General Public License
17
 * as published by the Free Software Foundation; either version 2
18
 * of the License, or (at your option) any later version.
19
 *
20
 * This program is distributed in the hope that it will be useful,
21
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
22
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
23
 * GNU General Public License for more details.
24
 *
25
 * You should have received a copy of the GNU General Public License
26
 * along with this program; if not, write to the Free Software
27
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
28
 *
29
 * For more information, contact:
30
 *
31
 *  Generalitat Valenciana
32
 *   Conselleria d'Infraestructures i Transport
33
 *   Av. Blasco Ib??ez, 50
34
 *   46010 VALENCIA
35
 *   SPAIN
36
 *
37
 *      +34 963862235
38
 *   gvsig@gva.es
39
 *      www.gvsig.gva.es
40
 *
41
 *    or
42
 *
43
 *   IVER T.I. S.A
44
 *   Salamanca 50
45
 *   46005 Valencia
46
 *   Spain
47
 *
48
 *   +34 963163400
49
 *   dac@iver.es
50
 */
51
/* CVS MESSAGES:
52
 *
53
 * $Id: ExampleNewPanel.java 537 2007-07-26 11:21:10Z jpiera $
54
 * $Log$
55
 * Revision 1.1.2.1  2007/07/13 12:00:35  jorpiell
56
 * Add the posibility to add a new panel
57
 *
58
 *
59
 */
60
/**
61
 * @author Jorge Piera LLodr? (jorge.piera@iver.es)
62
 */
63
public class ExampleNewPanel extends SearchAditionalPropertiesPanel{
64
	JLabel label = null;
65
	JTextField text = null;
66
	
67
	public ExampleNewPanel(){
68
		label = new JLabel();
69
		text = new JTextField();		
70
		setLayout(new java.awt.BorderLayout());
71
		label.setText("Label");
72
		add(label, java.awt.BorderLayout.WEST);		
73
		add(text, java.awt.BorderLayout.CENTER);
74
	}
75
	
76
	/*
77
	 * (non-Javadoc)
78
	 * @see es.gva.cit.gazetteer.ui.search.SearchAditionalPropertiesPanel#getProperties()
79
	 */
80
	public Properties getProperties() {
81
		Properties properties = new Properties();
82
		properties.put("PROP1", text.getText());
83
		return properties;
84
	}
85

  
86
}
0 87

  
org.gvsig.catalog/tags/org.gvsig.catalog-2.0.25/org.gvsig.catalog.lib/src/test/java/org/gvsig/catalog/catalog/utils/URIUtilsTest.java
1
package org.gvsig.catalog.catalog.utils;
2

  
3
import java.net.URI;
4
import java.net.URISyntaxException;
5

  
6
import junit.framework.TestCase;
7

  
8
import org.gvsig.catalog.utils.URIUtils;
9

  
10
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
11
 *
12
 * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
13
 *
14
 * This program is free software; you can redistribute it and/or
15
 * modify it under the terms of the GNU General Public License
16
 * as published by the Free Software Foundation; either version 2
17
 * of the License, or (at your option) any later version.
18
 *
19
 * This program is distributed in the hope that it will be useful,
20
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
21
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
22
 * GNU General Public License for more details.
23
 *
24
 * You should have received a copy of the GNU General Public License
25
 * along with this program; if not, write to the Free Software
26
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
27
 *
28
 * For more information, contact:
29
 *
30
 *  Generalitat Valenciana
31
 *   Conselleria d'Infraestructures i Transport
32
 *   Av. Blasco Ib??ez, 50
33
 *   46010 VALENCIA
34
 *   SPAIN
35
 *
36
 *      +34 963862235
37
 *   gvsig@gva.es
38
 *      www.gvsig.gva.es
39
 *
40
 *    or
41
 *
42
 *   IVER T.I. S.A
43
 *   Salamanca 50
44
 *   46005 Valencia
45
 *   Spain
46
 *
47
 *   +34 963163400
48
 *   dac@iver.es
49
 */
50
/* CVS MESSAGES:
51
 *
52
 * $Id: URIUtilsTest.java,v 1.1.2.1 2007/07/10 11:18:04 jorpiell Exp $
53
 * $Log: URIUtilsTest.java,v $
54
 * Revision 1.1.2.1  2007/07/10 11:18:04  jorpiell
55
 * Added the registers
56
 *
57
 *
58
 */
59
/**
60
 * @author Jorge Piera LLodr? (jorge.piera@iver.es)
61
 */
62
public class URIUtilsTest extends TestCase {
63
	
64
	public void test1() throws URISyntaxException{
65
		URI uri = URIUtils.createUri("http://www.upv.es", "http", 80);	
66
		assertEquals(uri.getHost(), "www.upv.es");
67
		assertEquals(uri.getScheme(), "http");
68
		assertEquals(uri.getPort(), 80);
69
		assertEquals(uri.getPath(), "");
70
	}
71
	
72
	public void test2() throws URISyntaxException{
73
		URI uri = URIUtils.createUri("www.upv.es", "http", 80);	
74
		assertEquals(uri.getHost(), "www.upv.es");
75
		assertEquals(uri.getScheme(), "http");
76
		assertEquals(uri.getPort(), 80);
77
		assertEquals(uri.getPath(), "");
78
	}
79
	
80
	public void test3() throws URISyntaxException{
81
		URI uri = URIUtils.createUri("www.upv.es", "z3950", 2100);	
82
		assertEquals(uri.getHost(), "www.upv.es");
83
		assertEquals(uri.getScheme(), "z3950");
84
		assertEquals(uri.getPort(), 2100);
85
		assertEquals(uri.getPath(), "");
86
	}
87
	
88
	public void test4() throws URISyntaxException{
89
		URI uri = URIUtils.createUri("http://193.144.250.29/webservices/services/IDEC_GeoServeisPort", "http", 80);	
90
		assertEquals(uri.getHost(), "193.144.250.29");
91
		assertEquals(uri.getScheme(), "http");
92
		assertEquals(uri.getPort(), 80);
93
		assertEquals(uri.getPath(), "/webservices/services/IDEC_GeoServeisPort");
94
	}
95
}
0 96

  
org.gvsig.catalog/tags/org.gvsig.catalog-2.0.25/org.gvsig.catalog.lib/src/main/resources/META-INF/services/org.gvsig.tools.library.Library
1
org.gvsig.catalog.CatalogLibrary
2
org.gvsig.catalog.impl.DefaultCatalogLibrary
org.gvsig.catalog/tags/org.gvsig.catalog-2.0.25/org.gvsig.catalog.lib/src/main/java/org/gvsig/catalog/ui/chooseresource/ChooseResourceDialog.java
1

  
2
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
3
*
4
* Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
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., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
19
*
20
* For more information, contact:
21
*
22
*  Generalitat Valenciana
23
*   Conselleria d'Infraestructures i Transport
24
*   Av. Blasco Ib??ez, 50
25
*   46010 VALENCIA
26
*   SPAIN
27
*
28
*      +34 963862235
29
*   gvsig@gva.es
30
*      www.gvsig.gva.es
31
*
32
*    or
33
*
34
*   IVER T.I. S.A
35
*   Salamanca 50
36
*   46005 Valencia
37
*   Spain
38
*
39
*   +34 963163400
40
*   dac@iver.es
41
*/
42
package org.gvsig.catalog.ui.chooseresource;
43
import java.awt.event.WindowEvent;
44
import java.awt.event.WindowListener;
45
import java.util.Collection;
46

  
47
import javax.swing.JFrame;
48

  
49
import org.gvsig.catalog.schemas.Resource;
50
import org.gvsig.catalog.utils.Frames;
51

  
52
/**
53
 * 
54
 * 
55
 * 
56
 * @author Jorge Piera Llodra (piera_jor@gva.es)
57
 */
58
public class ChooseResourceDialog extends JFrame implements WindowListener {
59

  
60
/**
61
 * Crea un nuevo ChooseResourceDialog.
62
 * 
63
 * @param cliente DOCUMENT ME!
64
 * 
65
 * @param resources 
66
 */
67
    public  ChooseResourceDialog(Collection resources) {        
68
        super();
69
        initialize(resources);
70
    } 
71

  
72
/**
73
 * This method initializes jDialog
74
 * 
75
 * 
76
 * @param resources 
77
 */
78
    private void initialize(Collection resources) {        
79
        Frames.centerFrame(this,600,175);
80
        this.setTitle("Busqueda de Cat?logo");
81
        //setResizable(false);
82
        setName("chooseResources");
83
        ChooseResourceDialogPanel panel = new ChooseResourceDialogPanel(resources);
84
        panel.setParent(this);
85
        getContentPane().add(panel);
86
       
87
        setVisible(true);
88
    } 
89
/* (non-Javadoc)
90
 * @see java.awt.event.WindowListener#windowActivated(java.awt.event.WindowEvent)
91
 */
92

  
93
/**
94
 * 
95
 * 
96
 * 
97
 * @param e 
98
 */
99
    public void windowActivated(WindowEvent e) {        
100
    // TODO Auto-generated method stub
101
    } 
102
/* (non-Javadoc)
103
 * @see java.awt.event.WindowListener#windowClosed(java.awt.event.WindowEvent)
104
 */
105

  
106
/**
107
 * 
108
 * 
109
 * 
110
 * @param e 
111
 */
112
    public void windowClosed(WindowEvent e) {        
113
    // TODO Auto-generated method stub
114
    } 
115
/* (non-Javadoc)
116
 * @see java.awt.event.WindowListener#windowClosing(java.awt.event.WindowEvent)
117
 */
118

  
119
/**
120
 * 
121
 * 
122
 * 
123
 * @param e 
124
 */
125
    public void windowClosing(WindowEvent e) {        
126
    // TODO Auto-generated method stub
127
    } 
128
/* (non-Javadoc)
129
 * @see java.awt.event.WindowListener#windowDeactivated(java.awt.event.WindowEvent)
130
 */
131

  
132
/**
133
 * 
134
 * 
135
 * 
136
 * @param e 
137
 */
138
    public void windowDeactivated(WindowEvent e) {        
139
    // TODO Auto-generated method stub
140
    } 
141
/* (non-Javadoc)
142
 * @see java.awt.event.WindowListener#windowDeiconified(java.awt.event.WindowEvent)
143
 */
144

  
145
/**
146
 * 
147
 * 
148
 * 
149
 * @param e 
150
 */
151
    public void windowDeiconified(WindowEvent e) {        
152
    // TODO Auto-generated method stub
153
    } 
154
/* (non-Javadoc)
155
 * @see java.awt.event.WindowListener#windowIconified(java.awt.event.WindowEvent)
156
 */
157

  
158
/**
159
 * 
160
 * 
161
 * 
162
 * @param e 
163
 */
164
    public void windowIconified(WindowEvent e) {        
165
    // TODO Auto-generated method stub
166
    } 
167
/* (non-Javadoc)
168
 * @see java.awt.event.WindowListener#windowOpened(java.awt.event.WindowEvent)
169
 */
170

  
171
/**
172
 * 
173
 * 
174
 * 
175
 * @param e 
176
 */
177
    public void windowOpened(WindowEvent e) {        
178
    // TODO Auto-generated method stub
179
    } 
180
/* (non-Javadoc)
181
 * @see es.gva.cit.catalogClient.ui.ILoadResource#loadResource(es.gva.cit.catalogClient.parsers.Resource)
182
 */
183

  
184
/**
185
 * 
186
 * 
187
 * 
188
 * @param resource 
189
 */
190
    public void loadResource(Resource resource) {        
191
    System.out.println(resource.getLinkage() + " solo puede ser cargado usando gvSIG");
192
    } 
193
 }
0 194

  
org.gvsig.catalog/tags/org.gvsig.catalog-2.0.25/org.gvsig.catalog.lib/src/main/java/org/gvsig/catalog/ui/chooseresource/ChooseResourceDialogPanel.java
1

  
2
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
3
*
4
* Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
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., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
19
*
20
* For more information, contact:
21
*
22
*  Generalitat Valenciana
23
*   Conselleria d'Infraestructures i Transport
24
*   Av. Blasco Ib??ez, 50
25
*   46010 VALENCIA
26
*   SPAIN
27
*
28
*      +34 963862235
29
*   gvsig@gva.es
30
*      www.gvsig.gva.es
31
*
32
*    or
33
*
34
*   IVER T.I. S.A
35
*   Salamanca 50
36
*   46005 Valencia
37
*   Spain
38
*
39
*   +34 963163400
40
*   dac@iver.es
41
*/
42
package org.gvsig.catalog.ui.chooseresource;
43
import java.awt.Dimension;
44
import java.awt.FlowLayout;
45
import java.awt.event.ActionEvent;
46
import java.awt.event.ActionListener;
47
import java.util.Collection;
48

  
49
import javax.swing.BoxLayout;
50
import javax.swing.JButton;
51
import javax.swing.JCheckBox;
52
import javax.swing.JFrame;
53
import javax.swing.JPanel;
54

  
55
import org.gvsig.catalog.schemas.Resource;
56
import org.gvsig.catalog.utils.resourcestable.ButtonEditor;
57
import org.gvsig.catalog.utils.resourcestable.ButtonRenderer;
58
import org.gvsig.i18n.Messages;
59

  
60
/**
61
 * this class represent the "choose resource frame". It is basically
62
 * contains a list with all the geo-resources that can be loaded. *
63
 * 
64
 * 
65
 * @author Jorge Piera Llodra (piera_jor@gva.es)
66
 */
67
public class ChooseResourceDialogPanel extends JPanel implements ActionListener {
68
//It is needed to close the frame
69
/**
70
 * 
71
 * 
72
 */
73
    private JFrame parent;
74
//Panels
75
/**
76
 * 
77
 * 
78
 */
79
    private JPanel ppalPanel = null;
80
/**
81
 * 
82
 * 
83
 */
84
    private ChooseResourcePanel controlsPanel = null;
85
/**
86
 * 
87
 * 
88
 */
89
    private JPanel buttonsPanel = null;
90
//Buttons
91
/**
92
 * 
93
 * 
94
 */
95
    private JButton cerrar = null;
96
//Others
97

  
98
/**
99
 * 
100
 * 
101
 */
102
    private java.util.Collection resources = new java.util.ArrayList();
103

  
104
/**
105
 * This method initializes
106
 * 
107
 * 
108
 * @param resources 
109
 * @param translator 
110
 */
111
    public  ChooseResourceDialogPanel(Collection resources) {        
112
               
113
        this.resources = resources;
114
          
115
        ppalPanel = new JPanel();
116
        ppalPanel.setLayout(new BoxLayout(ppalPanel, BoxLayout.Y_AXIS));
117
        
118
        ppalPanel.add(getControlsPanel(), null);
119
        ppalPanel.add(getButtonPanel(), null);
120
        
121
        
122
        add(ppalPanel);
123
        setDefaultButtonListeners();
124
    } 
125

  
126
/**
127
 * 
128
 * 
129
 * 
130
 * @return 
131
 */
132
    public ChooseResourcePanel getControlsPanel() {        
133
        if (controlsPanel == null) {
134
            controlsPanel = new ChooseResourcePanel(resources);
135
            controlsPanel.setPreferredSize(new java.awt.Dimension(575, 110));
136
            controlsPanel.setLocation(0, 0);
137
        }
138
        return controlsPanel;
139
    } 
140

  
141
/**
142
 * 
143
 * 
144
 * 
145
 * @return 
146
 */
147
    public JPanel getButtonPanel() {        
148
        if (buttonsPanel == null) {
149
            FlowLayout flowLayout = new FlowLayout();
150
            flowLayout.setAlignment(FlowLayout.RIGHT);
151
        	buttonsPanel = new JPanel(flowLayout);
152
            buttonsPanel.add(getCloseButton());
153
        }
154
        return buttonsPanel;
155
    } 
156

  
157
/**
158
 * 
159
 * 
160
 * 
161
 * @return 
162
 */
163
    public JButton getCloseButton() {        
164
        if (cerrar == null) {
165
            cerrar = new JButton(Messages.getText("close"));
166
            cerrar.setPreferredSize(new Dimension(80, 23));
167
            cerrar.setActionCommand("close");
168
        }
169
        return cerrar;
170
    } 
171

  
172
/**
173
 * 
174
 * 
175
 */
176
    public void setDefaultButtonListeners() {        
177
        getCloseButton().addActionListener(this);
178
        getControlsPanel().getTable().getColumn(Messages.getText("resourceShowColumn")).setCellRenderer(new ButtonRenderer());
179
        getControlsPanel().getTable().getColumn(Messages.getText("resourceShowColumn")).setCellEditor(new ButtonEditor(new JCheckBox(),resources,this));
180
        
181
    } 
182

  
183
/**
184
 * 
185
 * 
186
 * 
187
 * @param e 
188
 */
189
    public void actionPerformed(ActionEvent e) {        
190
        //Cerrar
191
        if (e.getActionCommand() == "close") {
192
           closeButtonActionPerformed();
193
        }   
194
        System.out.println(e.getActionCommand());
195
        
196
    } 
197

  
198
/**
199
 * 
200
 * 
201
 * 
202
 * @param resource 
203
 */
204
    public void resourceButtonActionPerformed(Resource resource) {        
205
        System.out.println(resource.getLinkage() + " no se puede cargar sin usar gvSIG");
206
    } 
207

  
208
/**
209
 * 
210
 * 
211
 */
212
    public void closeButtonActionPerformed() {        
213
       parent.setVisible(false);
214
    } 
215

  
216
/**
217
 * 
218
 * 
219
 * 
220
 * @param parent The parent to set.
221
 */
222
    public void setParent(JFrame parent) {        
223
        this.parent = parent;
224
    } 
225
 }
0 226

  
org.gvsig.catalog/tags/org.gvsig.catalog-2.0.25/org.gvsig.catalog.lib/src/main/java/org/gvsig/catalog/ui/chooseresource/ChooseResourcePanel.java
1

  
2
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
3
*
4
* Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
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., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
19
*
20
* For more information, contact:
21
*
22
*  Generalitat Valenciana
23
*   Conselleria d'Infraestructures i Transport
24
*   Av. Blasco Ib??ez, 50
25
*   46010 VALENCIA
26
*   SPAIN
27
*
28
*      +34 963862235
29
*   gvsig@gva.es
30
*      www.gvsig.gva.es
31
*
32
*    or
33
*
34
*   IVER T.I. S.A
35
*   Salamanca 50
36
*   46005 Valencia
37
*   Spain
38
*
39
*   +34 963163400
40
*   dac@iver.es
41
*/
42
package org.gvsig.catalog.ui.chooseresource;
43
import java.util.Collection;
44

  
45
import javax.swing.JButton;
46
import javax.swing.JPanel;
47
import javax.swing.JScrollPane;
48
import javax.swing.JTable;
49

  
50
import org.gvsig.catalog.schemas.Resource;
51
import org.gvsig.catalog.utils.resourcestable.TableModel;
52
import org.gvsig.i18n.Messages;
53

  
54
/**
55
 * 
56
 * 
57
 * 
58
 * @author Jorge Piera Llodra (piera_jor@gva.es)
59
 */
60
public class ChooseResourcePanel extends JPanel {
61
/**
62
 * 
63
 * 
64
 */
65
    private JTable table = null;
66
/**
67
 * 
68
 * 
69
 */
70
    private JScrollPane tablePane = null;
71

  
72
/**
73
 * 
74
 * 
75
 */
76
    private java.util.Collection resources = new java.util.ArrayList();
77

  
78
/**
79
 * This method initializes
80
 * 
81
 * 
82
 * @param resources 
83
 * @param translator 
84
 */
85
    public  ChooseResourcePanel(Collection resources) {        
86
		super();
87
		this.resources = resources; 
88
		initialize();
89
    } 
90

  
91
/**
92
 * It creates the table model
93
 * 
94
 * 
95
 * @return 
96
 */
97
    private TableModel createTableModel() {        
98
	    Object[][] columnValues = new Object[resources.size()][3];
99
	    String[] columnNames = {Messages.getText("resourceTypeColumn"),
100
	            Messages.getText("resourceLinkColumn"),
101
	            Messages.getText("resourceShowColumn")};	    
102
	    
103
	    for (int i=0 ; i<resources.size() ; i++){
104
	        Resource resource = (Resource)resources.toArray()[i];
105
            columnValues[i][0] = resource.getProtocol();
106
	        columnValues[i][1] = resource.getLinkage();
107
	        columnValues[i][2] = getNameButton(resource.getProtocol());
108
	   }
109
	   
110
	    return new TableModel(columnValues,columnNames);
111
    } 
112

  
113
/**
114
 * 
115
 * 
116
 * 
117
 * @return 
118
 * @param protocol 
119
 */
120
    private String getNameButton(String protocol) {        
121
	    if (protocol.toUpperCase().indexOf(Resource.WCS) >= 0)
122
			return  Messages.getText("wcsColumn");
123
	    if (protocol.toUpperCase().indexOf(Resource.WMS_SERVICE) >= 0)
124
			return Messages.getText("Servicio WMS");
125
		
126
		if (protocol.toUpperCase().indexOf(Resource.WMS) >= 0)
127
			return Messages.getText("wmsColumn");
128
		
129
		if (protocol.toUpperCase().indexOf(Resource.WFS) >= 0)
130
			return Messages.getText("wfsColumn");
131
		
132
		if (protocol.toUpperCase().indexOf(Resource.POSTGIS) >= 0)
133
			return Messages.getText("postgisColumn");
134
		
135
		if (protocol.toUpperCase().indexOf(Resource.WEBSITE) >= 0)
136
		    return Messages.getText("linkColumn");
137
		
138
		if (protocol.toUpperCase().indexOf(Resource.DOWNLOAD) >= 0)
139
		    return Messages.getText("downloadColumn");
140
		
141
		if (protocol.toUpperCase().indexOf(Resource.ARCIMS_IMAGE) >= 0)
142
		    return Messages.getText("arcims_image_resource");
143
		
144
		if (protocol.toUpperCase().indexOf(Resource.ARCIMS_VECTORIAL) >= 0)
145
		    return Messages.getText("arcims_vect_resource");
146
		
147
		return Messages.getText("unknown");
148
    } 
149

  
150
/**
151
 * 
152
 * 
153
 */
154
    private void initialize() {        
155
	    this.setSize(510, 125);
156
        this.add(getTablePane(), null);
157
			
158
    } 
159

  
160
/**
161
 * 
162
 * 
163
 * 
164
 * @return 
165
 */
166
    public JScrollPane getTablePane() {        
167
		if (tablePane == null) {
168
		    tablePane = new JScrollPane(getTable());
169
		    tablePane.setPreferredSize(new java.awt.Dimension(575,100));
170
		    
171
		}
172
		return tablePane;
173
    } 
174

  
175
/**
176
 * This method initializes table
177
 * 
178
 * 
179
 * @return javax.swing.JTable
180
 */
181
    public JTable getTable() {        
182
		if (table == null) {
183
		    table = new JTable(createTableModel());
184
		    
185
		}
186
		return table;
187
    } 
188

  
189
/**
190
 * It Return the JButtons array
191
 * 
192
 * 
193
 * @return 
194
 */
195
    public JButton[] getButtons() {        
196
	    JButton[] buttons = new JButton[resources.size()];
197
	    for (int i=0 ; i<resources.size() ; i++)
198
	        buttons[i] = (JButton) getTable().getModel().getValueAt(i,2); 
199
	    
200
	    return buttons;
201
    } 
202
 }
0 203

  
org.gvsig.catalog/tags/org.gvsig.catalog-2.0.25/org.gvsig.catalog.lib/src/main/java/org/gvsig/catalog/ui/serverconnect/ServerConnectDialog.java
1

  
2
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
3
 *
4
 * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
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., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
19
 *
20
 * For more information, contact:
21
 *
22
 *  Generalitat Valenciana
23
 *   Conselleria d'Infraestructures i Transport
24
 *   Av. Blasco Ib??ez, 50
25
 *   46010 VALENCIA
26
 *   SPAIN
27
 *
28
 *      +34 963862235
29
 *   gvsig@gva.es
30
 *      www.gvsig.gva.es
31
 *
32
 *    or
33
 *
34
 *   IVER T.I. S.A
35
 *   Salamanca 50
36
 *   46005 Valencia
37
 *   Spain
38
 *
39
 *   +34 963163400
40
 *   dac@iver.es
41
 */
42
package org.gvsig.catalog.ui.serverconnect;
43
import java.awt.event.WindowEvent;
44
import java.awt.event.WindowListener;
45

  
46
import javax.swing.JFrame;
47

  
48
import org.gvsig.catalog.utils.Frames;
49

  
50
/**
51
 * This class implements the JFrame for the server
52
 * connect panel that will be used when the catalog
53
 * client is runned without gvSIG
54
 * @author Jorge Piera Llodr? (jorge.piera@iver.es)
55
 */
56
public class ServerConnectDialog extends JFrame implements WindowListener {
57
	private static final long serialVersionUID = 4678818428679670480L;
58

  
59
	public ServerConnectDialog() {        
60
		super();        
61
		initialize();
62
	} 
63

  
64
	/**
65
	 * This method initializes jDialog
66
	 * 
67
	 */
68
	protected void initialize() {        
69
		Frames.centerFrame(this, 625, 290);
70
		this.setTitle("Metadata catalog");
71
		setName("serverConnect");
72
		getContentPane().add(new ServerConnectDialogPanel(
73
				this));
74
		addWindowListener(this);
75
		setVisible(true);
76
	} 
77
	
78
	/*
79
	 * (non-Javadoc)
80
	 * @see java.awt.event.WindowListener#windowActivated(java.awt.event.WindowEvent)
81
	 */
82
	public void windowActivated(WindowEvent e) {        
83
		// TODO Auto-generated method stub
84
	} 
85

  
86
	/*
87
	 * (non-Javadoc)
88
	 * @see java.awt.event.WindowListener#windowClosing(java.awt.event.WindowEvent)
89
	 */
90
	public void windowClosing(WindowEvent arg0) {        
91
		System.exit(0);
92
	} 
93
	
94
	/*
95
	 * (non-Javadoc)
96
	 * @see java.awt.event.WindowListener#windowClosed(java.awt.event.WindowEvent)
97
	 */
98
	public void windowClosed(WindowEvent arg0) {        
99
		System.exit(0);
100
	} 
101
	
102
	/*
103
	 * (non-Javadoc)
104
	 * @see java.awt.event.WindowListener#windowDeactivated(java.awt.event.WindowEvent)
105
	 */
106
	public void windowDeactivated(WindowEvent e) {        
107
		// TODO Auto-generated method stub
108
	} 
109
	
110
	/*
111
	 * (non-Javadoc)
112
	 * @see java.awt.event.WindowListener#windowDeiconified(java.awt.event.WindowEvent)
113
	 */
114
	public void windowDeiconified(WindowEvent e) {        
115
		// TODO Auto-generated method stub
116
	} 
117
	
118
	/*
119
	 * (non-Javadoc)
120
	 * @see java.awt.event.WindowListener#windowIconified(java.awt.event.WindowEvent)
121
	 */
122
	public void windowIconified(WindowEvent e) {        
123
		// TODO Auto-generated method stub
124
	} 
125
	
126
	/*
127
	 * (non-Javadoc)
128
	 * @see java.awt.event.WindowListener#windowOpened(java.awt.event.WindowEvent)
129
	 */
130
	public void windowOpened(WindowEvent e) {        
131
		// TODO Auto-generated method stub
132
	} 
133
}
0 134

  
org.gvsig.catalog/tags/org.gvsig.catalog-2.0.25/org.gvsig.catalog.lib/src/main/java/org/gvsig/catalog/ui/serverconnect/ServerConnectDialogPanel.java
1

  
2
/* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
3
 *
4
 * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
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., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
19
 *
20
 * For more information, contact:
21
 *
22
 *  Generalitat Valenciana
23
 *   Conselleria d'Infraestructures i Transport
24
 *   Av. Blasco Ib??ez, 50
25
 *   46010 VALENCIA
26
 *   SPAIN
27
 *
28
 *      +34 963862235
29
 *   gvsig@gva.es
30
 *      www.gvsig.gva.es
31
 *
32
 *    or
33
 *
34
 *   IVER T.I. S.A
35
 *   Salamanca 50
36
 *   46005 Valencia
37
 *   Spain
38
 *
39
 *   +34 963163400
40
 *   dac@iver.es
41
 */
42
package org.gvsig.catalog.ui.serverconnect;
43
import java.awt.BorderLayout;
44
import java.awt.Cursor;
45
import java.awt.event.ActionEvent;
46
import java.awt.event.ActionListener;
47
import java.util.Iterator;
48
import java.util.Map;
49

  
50
import javax.swing.Icon;
51
import javax.swing.ImageIcon;
52
import javax.swing.JFrame;
53
import javax.swing.JPanel;
54

  
55
import org.gvsig.catalog.CatalogClient;
56
import org.gvsig.catalog.CatalogLocator;
57
import org.gvsig.catalog.CatalogManager;
58
import org.gvsig.catalog.drivers.DiscoveryServiceCapabilities;
59
import org.gvsig.catalog.drivers.ICatalogServiceDriver;
60
import org.gvsig.catalog.ui.search.SearchDialog;
61
import org.gvsig.catalog.ui.serverproperties.ServerPropertiesDialog;
62
import org.gvsig.catalog.utils.CatalogConstants;
63
import org.gvsig.i18n.Messages;
64
import org.gvsig.utils.swing.jcomboServer.ServerData;
65
import org.slf4j.Logger;
66
import org.slf4j.LoggerFactory;
67

  
68
/**
69
 *
70
 *
71
 *
72
 * @author Jorge Piera Llodra (piera_jor@gva.es)
73
 */
74
public class ServerConnectDialogPanel extends JPanel implements ActionListener {
75
	private static final long serialVersionUID = 1224880378648403038L;
76
	 private static Logger logger =
77
		        LoggerFactory.getLogger(ServerConnectDialogPanel.class);
78

  
79
	private static final CatalogManager catalogManager = CatalogLocator.getCatalogManager();
80
	private ServerConnectPanel controlsPanel = null;
81
	private JFrame parent = null;
82
	protected CatalogClient client = null;
83
	protected String currentServer = "";
84
	private ConnectThread connectThread = null;
85

  
86
	/**
87
	 * Constructor
88
	 * @param parent
89
	 */
90
	public  ServerConnectDialogPanel(JFrame parent) {
91
		this.parent = parent;
92
		this.setLayout(new BorderLayout());
93
		add(getControlsPanel(),BorderLayout.CENTER);
94
		//Loads the servers
95
		int n_servers = loadServerList();
96

  
97
	      //Load the protocols
98
        controlsPanel.loadDrivers(
99
                catalogManager.getDrivers());
100
        getControlsPanel().setPropertiesIcon(getPropertiesIcon());
101

  
102
		if (n_servers == 0) {
103
		    return;
104
		}
105

  
106
		//Load the selected server protocol
107
		controlsPanel.updateProtocol();
108
		enableServerPropertiesButton();
109
	}
... This diff was truncated because it exceeds the maximum size that can be displayed.

Also available in: Unified diff