How to use
See How to use ArcGIS samples for help on running the sample.
How to use this sample?
- Deploy the lib/JavaFindNearbyFeaturesRESTSOE.soe file to Server. For instructions on how to deploy an SOE to ArcGIS 10.1 Server, please see the "Developing Extensions" -> "Server Object Extensions" -> "Deploying and Un-deploying SOEs" topic in the ArcGIS Java Developer Help.
- Enable the SOE on map service of your choice. For instructions on how to enable SOE on a map service, please see the "Developing Extensions" -> "Server Object Extensions" -> "Enabling and Disabling SOEs" topic in the ArcGIS Java Developer Help. Please ensure that the map service has at least 1 feature layer.
- After the map service has started with SOE enabled on it, open up Services Directory web app and access the http://<server name>:6080/arcgis/rest/services page
- Click on the map service you enabled your SOE on.
- Scroll down and click on the JavaFindNearbyFeaturesRESTSOE listed in "Supported Extensions" section. If you don't find your REST SOE listed here, please log in as admin into the Services Directory web app and clear the REST cache. Repeat steps 3,4, and 5.
- The JavaFindNearbyFeaturesRESTSOE web page displays root resource details such as name and description, along with the "Child Resources" and "Supported Operations" sections.
- Click the "featureLayers" sub-resource. All feature layers in associated map service will be displayed. Record id of one of the layers for use in the operation below.
- Navigate back to the SOE web page and click on the "findNearbyFeatures" operation.
- Provide the following information to this operation: the layer id you recorded earlier in step 7, the location in JSON format, such as {"x": <x-value>, "y": <y-value>, "spatialReference": {"wkid": <sp ref id of map>}}, and distance in feet, such as 500. Click the "findNearbyFeatures(GET)" or "findNearbyFeatures(POST)" button. All features within 500 feet of your location will be returned.
If you installed the samples feature, you will find the files associated with this sample in <Your Developer Kit install location>\DeveloperKit10.4\Java\Samples\ArcObjects.
soe/JavaFindNearbyFeaturesSOE.java | The FindNearbyFeatures Java Server Object Extension class. |
lib/JavaFindNearbyFeaturesRESTSOE.soe | The .soe file that contains this Server Object Extension |
Development licensing | Deployment licensing |
---|---|
Server | Server |