AgsJWS Map Viewer


PurposeThe ArcGIS Java WebServices (AgsJWS) Map Viewer Sample is a web mapping application built with the AgsJWS API.  Features of the sample includs basic map navigation including panning and zooming.  The application uses SOAP over HTTP to connect with a user supplied Map Service WSDL endpoint URL and can be used as a template for extending. 

How to use

See How to use ArcGIS samples for help on running the sample. If the sample has associated data, you will find that the sample's zip file includes a "data" folder alongside the language folders. However, you will need to update the sample to point to the location of the data once you have extracted all the files.

Steps to Run Sample
  1. Open a command prompt and navigate into the samples root directory, e.g. $AGSDEVKITJAVA/java/samples/adf/webservicesmapviewer
  2. Run the Ant build task, from a command prompt, type > ant build
  3. This will create a deployable war file in the samples root directory
  4. Deploy webservicesmapviewer.war to your Java Application server and run the application in your internet browser.
  5. Enter the URL of known ArcGIS Server Map Service URL, for example, a map resource URL from ArcGIS Online resource center.

Import Sample into Eclipse 3.4.x (Ganymede)
  1. Source code is included in the war file generated in above steps so you can easily import in Eclipse to review the source and/or edit the application
  2. In Eclipse, select File > Import from the Eclipse toolbar
  3. Select Web\WAR file from the Select dialog
  4. Browse to the webservicesmapviewer.war file generated in above steps and accept the Web Project and Target Runtime selections
  5. Click Finish (You do not need to import the Web Libraries)

Import Sample into NetBeans v6.5.1
  1. Source code is included in the sample file structure so you can easily import into NetBeans
  2. In NetBeans, select File > New Project from the NetBeans toolbar
  3. Select 'Java Web' from the Categories left hand pane and 'Web Application from the Existing Sources' from the Projects right hand pane.
  4. Browse to the 'WebContent' directory in the sample root directory, e.g. $AGSDEVKITJAVA/java/samples/adf/webservicesmapviewer/WebContent
  5. Ensure the 'Existing Sources and libraries' dialog is appropriately populated
  6. Choose 'Delete' from the Warning dialog to delete the pre-compiled class files


Download the files for Java
MapView.jsp Map Viewer




Development licensing Deployment licensing
Server Server