SharpMap as a WMS server

by Morten 10/13/2005 6:03:22 AM

Today I was trying to make a WMS implementation using SharpMap, and it turned out to be quite easy. I’ve implemented some helper classes in SharpMap, which I will include in the next release of SharpMap. Actually now you can create a WMS service using only a few lines of code. Here’s an example:

protected void Page_Load(object sender, EventArgs e)
{
    SharpMap.Map myMap = InitializeMap(); //Call method that sets up your map
    SharpMap.Web.Wms.WmsServer.ParseQueryString(Request.QueryString,Response,myMap);
}
And that’s it !!! (well at least besides the InitializeMap method where you set up layers etc…)

It even returns nice little XML exceptions according to the specification. I still need to do some work on the GetCapabilities request, but I think it’s more or less safe to say that SharpMap will work as an OpenGIS compliant WMS Server in the next release.

Tags:

SharpMap

Powered by BlogEngine.NET 1.6.1.0

RecentComments

Comment RSS

About the author

Morten Nielsen

Morten Nielsen
<--That's me
E-mail me Send mail

Twitter @SharpGIS 

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.

© Copyright 2009