Server Object Extension Samples


Summary This document briefly summarizes Java Server Object Extension samples.

The purpose of SOE samples is to demonstrate the ease in development and consumption of Server Object Extensions. You must install the ArcObjects Software Development Kit (SDK) in order to be able to use SOE samples.
 
A note on developing Server Object Extensions using Eclipse IDE:
 
The ArcObjects Java SDK includes a plug-in for Eclipse IDE that includes wizards for different types of extensions to ArcGIS such as SOE, geoprocessing tools, etc. These wizards help developers jump start their ArcGIS Java development, by gathering information from the developer and generating boiler plate code. This allows developers to focus on creating their extensions. The generate code also includes pointers to where developers must add their custom business logic. Using Eclipse IDE is, therefore, recommended, to aid your ArcGIS Java extensions development effort. For instructions on how to use these wizards, please visit the "Simple SOE Developer Walkthrough" document in ArcObjects SDK.
 
 
 
REST Server Object Extensions:
 
REST SOEs expose functionality in terms of resources that have identifiers and one or more representations. The SOE itself acts as the root resource that has a default representation in JSON format. Representations in several other formats such as html, AMF, etc are also supported.
 
ArcGIS REST resources can have custom operations, for ex: the getPageLayoutBySize() operation in PageLayout SOE that takes in width, height, and dpi from client application and returns an image representation of a map in user defined dimensions, in page layout style.
 
ArcGIS REST resources can also have sub-resources. A sub-resource belongs to the root resource but is similar to it in nature, in that it can have one or more representations, operations and sub-resources. For example, the PageLayout resource also has a sub-resource, called PageLayout1024x768. This sub-resource has only one representation, an image of fixed dimensions (1024x768). If users wish to access the map's page layout in different dimensions, they can invoke the getPageLayoutBySize() operation on the PageLayout root resource.
 
 
REST SOE Samples:
The following are REST SOE samples:
ServerObjectExtension.PageLayout_REST: Allows users to access the page layout view of the associated map service. This view can be used to print the map.
ServerObjectExtension.POIFinder_REST: Allows users to access Points of interest such as gas stations and restaurants. The POIs can be accessed through 2 operations on the root resource, or as sub-resources.
ServerObjectExtension.BusServices_SOAPREST: Allows users to view bus stations in their vicinity and find directions to selected bus station. The root resource has a findBusStationNearMe operation that finds bus stations within specified distance. Each bus station is a sub-resource and is part of a collection and users can find directions to the bus station from their current location by invoking the getDirections operation.
 
SOAP SOE Samples:
The following are SOAP SOE samples:
ServerObjectExtension.FindNearbyFeatures_SOAP: Finds features that are near user location. User can select which layer he wants to be used as data source. This sample exposes only one SOAP operation, called "findNearbyFeatures". This operation requires layer id, user's location and distance within which features need to be found.
 
ServerObjectExtension.BusServices_SOAPREST: Allows users to view bus stations in their vicinity and find directions to selected bus station. This SOAP SOE has 2 operations:
  1. findBusStationNearMe: This takes in user location and distance and returns all bus stations within the specified distance.
  2. getDirections: This takes in id of a bus station and user location and returns directions to bus station from user location.
DOM SOE Samples:
Following is 1 DCOM SOE Sample:
ServerObjectExtension.LengthCalculator_DCOM: Finds length of street features and returns sum of all lengths. Can be accessed by connecting to the Server through DCOM and making a method call on the SOE.






Development licensing Deployment licensing
Server Server