New answers tagged

0

Your error has nothing to do with JSON, there is a problem with the PostGIS datastore jar on your path. The most likely cause of this issue is that you have combined jars from different GeoTools releases. Check your pom.xml file - the usual practice is to use a property geotools.version set to the version you plan to use: <properties> ...


0

To read various file formats for rendering GeoTools uses a DataStoreFinder mechanism that allows you to call it with a Map of keys & parameters and then it searches all the available DataStoreFactories to see which one can process those parameters. For your file based stores all you need to do is: HashMap<String, Object> params = ...


2

The geometry column of a ShapeFile must be called "the_geom", your's is called "location" so the ShapefileWriter ignores it. change SimpleFeatureType featureType = DataUtilities.createType( tipoShape, "location:" + tipoShape + ":srid=4326," + "number:Integer"); to SimpleFeatureType featureType = DataUtilities.createType( tipoShape, "the_geom:" + ...


0

Assuming you mean in JavaScript, I think I can help. This really breaks down into two problems: Accessing the Marker Instance First you need to get the marker somehow, either by selecting it through the DOM or accessing a reference (variable). This question addresses the first of those 2 options and the code explains it more below. Retrieving the ...


1

I've followed selection lab of geotools. Source here. It would be an answer for this question.


2

The invalid GeoJSON object error appears to be a product of your edited code, where the temp variable is actually a string, not a GeoJSON object. From your sample output in the comments, it appears that you are getting an array of GeoJson Polygon objects, which L.geoJson can interpret correctly, so your original code (before the edit) should successfully add ...


0

You would use a JMapPane - for the most part I would look at the code for JMapFrame and cherry pick the parts I needed in my application.


1

Try ICurve.QueryPoint with asRatio = true, and distanceAlongCurve = 0.5: Copies to outPoint the properties of a point on the curve at a specified distance from the beginning of the curve.


0

Here you have a working example with a "Reset Zoom" buttom. First you have to create a HTML kind of buttom: <div id = 'reset'><p>Reset Zoom</p></div> Second, you need to use JQuery in combination with the setView CartoDB.js function: $('#reset').click(function(){ map.setView([41.390205, 2.154007],12); });



Top 50 recent answers are included