Examples of WSDataStoreFactory


Examples of org.geotools.data.ws.WSDataStoreFactory

     */
    @Test
    public void testCreate() throws IOException {
       
        Map<Object, Object> properties = new HashMap<Object, Object>();
        WSDataStoreFactory dsf = new WSDataStoreFactory();
        properties.put("WSDataStoreFactory:GET_CONNECTION_URL", "http://d00109:8080/xaware/XADocSoapServlet");    
        properties.put("WSDataStoreFactory:TIMEOUT", new Integer(30000));
        properties.put("WSDataStoreFactory:TEMPLATE_DIRECTORY", TEST_DIRECTORY);
        properties.put("WSDataStoreFactory:TEMPLATE_NAME", "request.ftl");
        properties.put("WSDataStoreFactory:CAPABILITIES_FILE_LOCATION", TEST_DIRECTORY + "ws_capabilities_equals_removed.xml");

        XmlDataStore ds = dsf.createDataStore(properties);
        assertNotNull(ds);
    }
View Full Code Here

Examples of org.geotools.data.ws.WSDataStoreFactory

    private Map<String, Serializable> params;

    @Before
    public void setUp() throws Exception {
        dsf = new WSDataStoreFactory();
        params = new HashMap<String, Serializable>();
    }
View Full Code Here

Examples of org.geotools.data.ws.WSDataStoreFactory

        capabilitiesFile = "ws_capabilities_equals_removed.xml";
        testCreateDataStore_WS(capabilitiesFile);
    }

    private void testCreateDataStore_WS(final String capabilitiesFile) throws IOException {
         final WSDataStoreFactory dsf = new WSDataStoreFactory();
        Map<String, Serializable> params = new HashMap<String, Serializable>();
        
           
        File file = new File(BASE_DIRECTORY + capabilitiesFile);
        if (!file.exists()) {
            throw new IllegalArgumentException(capabilitiesFile + " not found");
        }   
        URL url = file.toURL();
      
        params.put(WSDataStoreFactory.GET_CONNECTION_URL.key, url);
        params.put(WSDataStoreFactory.TEMPLATE_DIRECTORY.key, new URL("file:" + BASE_DIRECTORY));
        params.put(WSDataStoreFactory.TEMPLATE_NAME.key, "request.ftl");
        params.put(WSDataStoreFactory.CAPABILITIES_FILE_LOCATION.key, url);

        XmlDataStore dataStore = dsf.createDataStore(params);
        assertTrue(dataStore instanceof WS_DataStore);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.