Writing your own map service

Geocode plug-in allows you to write your own map services and plug them into the plug-in. The plug-in provides some java interfaces. Any class implementing them can be used with the plug-in to provide the functionalities. Below is a set of interfaces which can be implemented to provide custom map services.

com.escenic.geocode.service.api.GeocodeService

The interface declares the methods required by the plug-in to allow a user to search for geo tags based on adress. Once a concrete implementation of the interface is ready, it can be configured in the article type definition.

com.escenic.geocode.service.api.ReverseGeocodeService

The interface declares the methods required by the plug-in to allow a user to do a reverse geo search. This allows a user to search for nearby geo tagged places with a given location which consists of latitude and longitude.

com.escenic.geocode.studio.mapviewer.api.AbstractMapViewer

The abstract class defines the methods necessary to display a custom map in Geocode plug-in.

Example configuration
<field type="basic" name="com.escenic.geocode" mime-type="text/plain">
<geocode:geocode-editor enabled="true">
  <geocode:service-provider>test.MyGeocodeService</geocode:service-provider>
  <geocode:map-provider>test.MyCustomMap</geocode:map-provider>
  <geocode:my-api>
    <geocode:my-key>tester007</geocode:my-key>
    <geocode:my-password>band</geocode:my-password>
  </geocode:my-api>
</geocode:geocode-editor>
</field>

Please see the javadoc to get an overview on the interfaces and classes.