protected DataStore getDataStore(String geoJSON) throws FileNotFoundException, IOException {
try {
File geoJsonfile = new File(geoJSON);
checkParameter(geoJsonfile.exists(), "File does not exist '%s'", geoJsonfile);
InputStream in = new FileInputStream(geoJsonfile);
FeatureJSON fjson = new FeatureJSON();
@SuppressWarnings("rawtypes")
FeatureCollection fc = fjson.readFeatureCollection(in);
@SuppressWarnings("unchecked")
DataStore dataStore = new MemoryDataStore(fc);
return dataStore;
} catch (IOException ioe) {
throw new CommandFailedException("Error opening GeoJSON: " + ioe.getMessage(), ioe);