public DataStore createNewDataStore(Map<String, Serializable> params) throws IOException { if (!canProcess(params)) { throw new IOException("Invalid parameters for DirectoryDataStore"); } return createDataStore(params); }
public DataStore createDataStore(Map<String, Serializable> params) throws IOException { if (!canProcess(params)) { throw new IOException("Invalid parameters for DirectoryDataStore"); } URL url = (URL) URLP.lookUp(params); File f = DataUtilities.urlToFile(url); if (!f.isDirectory()) { throw new IOException("Invalid parameter " + URLP.key + " : is not a valid directory"); } URI namespace = (URI) NAMESPACE.lookUp(params); return new DirectoryDataStore(f, namespace); }