HSLayers.MapPortal (class)

HSLayers.MapPoprtal

class HSLayers.MapPortal(config, projections)

MapPortal is complete Portal application, based on Ext.ViewPort and MapViewer

param object config:
 configuration
param object config.mapPanelConfig:
 configuration of the {@link HSLayers.MapPanel}
param object config.mapOptions:
 configuration options for <a>OpenLayers.Map</a>
param String[] projections:
 list of supported projections

Example usage:

var mapPortal = new HSLayers.MapPortal(
     mapOptions: { // configuration of the OpenLayers.Map object
               units:"m",
               maxExtent: new OpenLayers.Bounds(-3480301.25,4028802,5009377,12515546),
               projection:"epsg:900913",
               scales:[50000000,20000000,10000000,5000000,2000000,1000000,500000,200000,100000,50000,20000,10000]
           },
           projections: ["epsg:900913","epsg:4326"]
       });
mapPortal.map.addLayers(new OpenLayers.Layer.WMS("Name","url",...));
mapPortal.map.zoomToMaxExtent();

Properties

HSLayers.MapPortal.baseLayer
Type :OpenLayers.Layer.Image (static)

HSLayers.MapPortal

OpenLayers.Layer.Image, which is used as default base layer

HSLayers.MapPortal.citiesGrid
Type :<a href=”http://www.extjs.com/deploy/dev/docs/?class=Ext.grid.GridPanel“>Ext.grid.GridPanel</a> (static)

HSLayers.MapPortal

Cities grid with search results

HSLayers.MapPortal.CLASS_NAME
Type :String (static)

HSLayers.MapPortal

class name

HSLayers.MapPortal.controls
Type :[{String}] (static)

HSLayers.MapPortal

list of controls, to be added to the map (see mapControls)

Default Value:
[“Panel”,”PanZoomBar”, “ScaleSwitcher”, “ScaleLine”, “MousePosition”, “Attribution”, “Permalink”, “Print”]
HSLayers.MapPortal.initBus
Type :HSLayers.InitBus (static)

HSLayers.MapPortal

initBus

HSLayers.MapPortal.map
Type :<a href=”http://dev.openlayers.org/releases/OpenLayers-2.8/doc/apidocs/files/OpenLayers/Map-js.html“>OpenLayers.Map</a> (static)

HSLayers.MapPortal

use the {setMap} method for setting this attribute

HSLayers.MapPortal.mapControls

HSLayers.MapPortal

reference to various OpenLayers.Control.* instances in the map, which are available in every mapportal

HSLayers.MapPortal.mapToolBar
Type :OpenLayers.Control.Panel (static)

HSLayers.MapPortal

toolbar in the map, for various OpenLayers.Controls

HSLayers.MapPortal.markerLayer
Type :OpenLayers.Layer.Vector (static)

HSLayers.MapPortal

marker layer - for temporary drawings, like measuring and so on

HSLayers.MapPortal.origProjection
Type :<a href=”http://dev.openlayers.org/releases/OpenLayers-2.8/doc/apidocs/files/OpenLayers/Projection-js.html“>OpenLayers.Projection</a> (static)

HSLayers.MapPortal

original projection of the map

HSLayers.MapPortal.queryHandlerClass

HSLayers.MapPortal

HSLayers.MapPortal.readStateControl
Type :HSLayers.Control.ReadState (static)

HSLayers.MapPortal

readState control

HSLayers.MapPortal.saveStateControl
Type :HSLayers.Control.SaveState (static)

HSLayers.MapPortal

saveState control

HSLayers.MapPortal.selectFeatureControl
Type :<a href=”http://dev.openlayers.org/releases/OpenLayers-2.8/doc/apidocs/files/OpenLayers/Control/SelectFeature-js.html“>OpenLayers.Control.SelectFeature</a> (static)

HSLayers.MapPortal

select vector feature

HSLayers.MapPortal.userGraphicsLayer
Type :OpenLayers.Layer.Vector (static)

HSLayers.MapPortal

vector layer - for temporary drawings, like measuring and so on and UserGraphics control

HSLayers.MapPortal.vectorLayer
Type :OpenLayers.Layer.Vector (static)

HSLayers.MapPortal

vector layer - for temporary drawings, like measuring and so on

Methods

marker

marker

HSLayers.MapPortal.searchGeoNames(field)

Search in GeoNames

:param <a href=”http://www.extjs.com/deploy/dev/docs/?class=Ext.form.Field“>Ext.form.Field</a> field:

HSLayers.MapPortal.geoNamesSearched(req)

Parse the geonames

Arguments:
  • req (HTTPRequest) –
HSLayers.MapPortal.microFormatsSearched(req)

Parse the html response

Arguments:
  • req (HTTPRequest) –
HSLayers.MapPortal.onMarkerGridMouseOver(e)
Select the record in the table, which coresponds to mouseovered

marker

param Event e:

:param <a href=”http://dev.openlayers.org/releases/OpenLayers-2.8/doc/apidocs/files/OpenLayers/Marker-js.html“>OpenLayers.Marker</a> e.object:

HSLayers.MapPortal.onMarkerMicroFormatMouseOver(e)
Select the record in the table, which coresponds to mouseovered

marker

param Event e:

:param <a href=”http://dev.openlayers.org/releases/OpenLayers-2.8/doc/apidocs/files/OpenLayers/Marker-js.html“>OpenLayers.Marker</a> e.object:

HSLayers.MapPortal.onRecordSelected(sm, idx, record)

Zoom to particular selected record in the map a nd high light

:param <a href=”http://www.extjs.com/deploy/dev/docs/?class=Ext.grid.RowSelectionModel“>Ext.grid.RowSelectionModel</a> sm:

Arguments:
  • idx (Integer) –

:param <a href=”http://www.extjs.com/deploy/dev/docs/?class=Ext.data.Record“>Ext.data.Record</a> record:

HSLayers.MapPortal.addFeaturesToMap()

add list of features to map and zoom to them

Arguments:
  • {OpenLayers.Feature}

    features

    Optional

HSLayers.MapPortal.setMap(map)

Set {@link HSLayers.MapPortal.map} object

:param <a href=”http://dev.openlayers.org/releases/OpenLayers-2.8/doc/apidocs/files/OpenLayers/Map-js.html“>OpenLayers.Map</a> map:

Returns:None
HSLayers.MapPortal.mapInitialized()

call afterInit method

Main Menu


Table Of Contents

Previous topic

HSLayers.MapPanel (class)

Next topic

HSLayers.MapViewer (class)

This Page