/** * See also {@link MapUnits}. * * @return String - the units used by the projection */ public String getUnits(){ return MapImpl.getUnits(getJSObject()); }
/** * This function should be called by any external code which dynamically * changes the size of the map div. It can also be called when experiencing * the problem of the single small tile in the upper left corner (doesn't * work in all situations thought) */ public void updateSize() { MapImpl.updateSize(getJSObject()); }
/** * zoom in with one step. */ public void zoomIn() { MapImpl.zoomIn(getJSObject()); }
/** * Set the min and max zoomlevel of the map. This blocks zooming further out * or in than the given levels. * * @param minZoomLevel The minlevel to zoom * @param maxZoomLevel The maxlevel to zoom */ public void setMinMaxZoomLevel(int minZoomLevel, int maxZoomLevel) { MapImpl.setMinMaxZoomLevel(getJSObject(), minZoomLevel, maxZoomLevel); }
/** * Returns current zoom level of map object. * @return current zoom level */ public int getZoom(){ return MapImpl.getZoom(getJSObject()); }
/** * This function should be called by any external code which dynamically changes the size of the map div. * It can also be called when experiencing the problem of the single small tile in the upper left corner (doesn't work in all situations thought) */ public void updateSize() { MapImpl.updateSize(getJSObject()); };
/** * returns the DOM node of the viewport. * * @return */ public Element getViewport() { return MapImpl.getViewport(getJSObject()); }
/** * Returns current zoom level of map object. * * @return current zoom level */ public int getZoom() { return MapImpl.getZoom(getJSObject()); }
/** * See also {@link MapUnits}. * * @return String - the units used by the projection */ public String getUnits() { return MapImpl.getUnits(getJSObject()); }
/** * Use this method to merge ... with the map * or * use setMapDomElementId to create a new map in that dom element. * * * @param map - the map to merge map elements with that are created * on the basis of the WMC document */ public void setMap(Map map){ getJSObject().setProperty("map", map.getJSObject()); };
/** * @return LonLat - the coordinates of the center */ public LonLat getCenter(){ return new LonLat(MapImpl.getCenter(getJSObject())); }
/** * Use this method to merge ... with the map or use setMapDomElementId to * create a new map in that dom element. * * * @param map - the map to merge map elements with that are created on the * basis of the WMC document */ public void setMap(Map map) { getJSObject().setProperty("map", map.getJSObject()); }
/** * @return LonLat - the coordinates of the center */ public LonLat getCenter() { return new LonLat(MapImpl.getCenter(getJSObject())); }
/** * * @param layer * @ param setNewBaseLayer - {Boolean} default is true */ public void removeLayer(Layer layer, boolean setNewBaseLayer) { MapImpl.removeLayer(getJSObject(), layer.getJSObject(), setNewBaseLayer); }
/** * Method: setLayerZIndex * * Parameters: layer - {<OpenLayers.Layer>} zIdx - {int} */ public void setLayerZIndex(Layer layer, int zIdx) { MapImpl.setLayerZIndex(getJSObject(), layer.getJSObject(), zIdx); }
/** * Method: getLonLatFromLayerPx * * Parameters: * * @param px - {<OpenLayers.Pixel>} * * @return {<OpenLayers.LonLat>} */ public LonLat getLonLatFromLayerPx(Pixel px) { return new LonLat(MapImpl.getLonLatFromLayerPx(getJSObject(), px.getJSObject())); }
public void addLayers(Layer[] layers) { JSObject[] jsObjects = new JSObject[layers.length]; for (int i = 0; i < layers.length; i++) { jsObjects[i] = layers[i].getJSObject(); } JObjectArray array = new JObjectArray(jsObjects); MapImpl.addLayers(getJSObject(), array.getJSObject()); }
public void addLayers(Layer[] layers) { JSObject[] jsObjects = new JSObject[layers.length]; for (int i = 0; i < layers.length; i++) { jsObjects[i] = layers[i].getJSObject(); } JObjectArray array = new JObjectArray(jsObjects); MapImpl.addLayers(getJSObject(), array.getJSObject()); }
public Layer[] getLayers() { JSObject jsObjects = MapImpl.getLayers(getJSObject()); JObjectArray jObjectArray = JObjectArray.narrowToJObjectArray(jsObjects); Layer[] layers = new Layer[jObjectArray.length()]; for(int i = 0; i < jObjectArray.length(); i++) { layers[i] = Layer.narrowToLayer(jObjectArray.get(i)); } return layers; }
public Layer[] getLayers() { JSObject jsObjects = MapImpl.getLayers(getJSObject()); JObjectArray jObjectArray = JObjectArray.narrowToJObjectArray(jsObjects); Layer[] layers = new Layer[jObjectArray.length()]; for (int i = 0; i < jObjectArray.length(); i++) { layers[i] = Layer.narrowToLayer(jObjectArray.get(i)); } return layers; }