Spectrum Spatial javascript toolkit for Leaflet
JavaScript HTML
Latest commit 2880e5d Oct 27, 2016 @SVoyt SVoyt committed on GitHub Merge pull request #5 from Estimap/dev



Leaflet plugin for Spectrum Spatial server.

What is it

This javascript API helps to you work with Spectrum Spatial server services in Leaflet maps. This API contains base rest-service wrappers, layers for Leaflet maps and controls. Spectrum4Leaflet sample

What is inside

Service wrappers

  • MapService - all rest operations of map service
  • TileService - all rest operations of tile service
  • FeatureService - all rest operations of feature service
  • NamedResourceService - all soap operations of feature service
  • GeometryService - all soap operations of geometry service
  • RoutingService - rest operations of enterprise routing module


  • MapServiceLayer - simple map layer object for Leaflet map
  • TileServiceLayer - tile layer object for Leaflet map


  • Layers - extended Leaflet Layers control, can change layer's zIndex, opacity and show legend
  • Legend - simple legend for MapServiceLayer
  • Feature - now has only one function - "search by point" in specified table of feature service
  • Resources - lists resources from named resource service


In your html add reference on leaflet (dev version) and on Spectrum4Leaflet plugin and write down something like:

var mapServiceUrl = 'http://localhost:8080/rest/Spatial/MappingService';
var mapName = '/Samples/NamedMaps/MapWithLayer';

var map = L.map('map').setView([0, 0], 1);