com.esri.client.local
Class LocalGeoprocessingService

java.lang.Object
  extended by com.esri.client.local.LocalService
      extended by com.esri.client.local.LocalGeoprocessingService

public class LocalGeoprocessingService
extends LocalService

Class representing a geoprocessing service on the LocalServer.


Field Summary
 
Fields inherited from class com.esri.client.local.LocalService
_serviceType, CREATE_SERVICE_FILE_PATH, CREATE_SERVICE_NAME, CREATE_SERVICE_TYPE
 
Constructor Summary
LocalGeoprocessingService()
          Default constructor; constructs a LocalGeoprocessingService without any reference to local data.
LocalGeoprocessingService(String path)
          Constructs from a path to data; typically this is the path to a GPK.
 
Method Summary
 String getDescription()
          Get a description for the service.
 int getMaximumRecords()
          Gets the maximum number of records.
 String getPath()
          Gets the path.
 GPServiceType getServiceType()
          Gets the service type.
 String getUrlGeoprocessingService()
          Gets the URL to the geoprocessing service.
 void setMaximumRecords(int maxRecords)
          Sets the maximum records that can be returned by the geoprocessing service.
 void setPath(String path)
          Sets the path; this is typically a path to a GPK on disk.
 void setServiceType(GPServiceType gpServiceType)
          Sets the service type to use when starting the geoprocessing service.
 LocalServiceStatus start()
          Starts the service on the LocalServer and blocks the application till the service has stopped.
 void startAsync()
          Starts the service on the LocalServer and allows the application to remain responsive while the service is starting.
 
Methods inherited from class com.esri.client.local.LocalService
addLocalServiceStartCompleteListener, addLocalServiceStopCompleteListener, completeStart, deleteService, failStart, failStart, fireLocalServiceStartCompleteEvent, getEndpoints, getError, getStatus, getUrl, removeLocalServiceStartCompleteListener, removeLocalServiceStopCompleteListener, sendRequest, setError, setStatus, startAsyncInner, startInner, stop, stopAsync
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LocalGeoprocessingService

public LocalGeoprocessingService()
Default constructor; constructs a LocalGeoprocessingService without any reference to local data. Call the setPath() method before starting this service.


LocalGeoprocessingService

public LocalGeoprocessingService(String path)
Constructs from a path to data; typically this is the path to a GPK.

Parameters:
path - Path to data.
Method Detail

getUrlGeoprocessingService

public String getUrlGeoprocessingService()
Gets the URL to the geoprocessing service.

Returns:
the URL of the geoprocessing service

getPath

public String getPath()
Gets the path.

Returns:
The path.

setPath

public void setPath(String path)
Sets the path; this is typically a path to a GPK on disk.

Parameters:
path - Path to set.

startAsync

public void startAsync()
Description copied from class: LocalService
Starts the service on the LocalServer and allows the application to remain responsive while the service is starting. Use the addLocalServiceStartCompleteListener(LocalServiceStartCompleteListener) method to listen for the start complete event. Alternatively, use the getStatus() and getError() methods the LocalServiceStatus is STARTED before using the service.

Specified by:
startAsync in class LocalService

start

public LocalServiceStatus start()
Description copied from class: LocalService
Starts the service on the LocalServer and blocks the application till the service has stopped.

Specified by:
start in class LocalService
Returns:
the local service status

getDescription

public String getDescription()
Description copied from class: LocalService
Get a description for the service.

Overrides:
getDescription in class LocalService
Returns:
A description of the service.

setServiceType

public void setServiceType(GPServiceType gpServiceType)
Sets the service type to use when starting the geoprocessing service. This can be a synchronous Execute operation on the server, or an asynchronous SubmitJob operation which can optionally return results via a map service.

Parameters:
gpServiceType - the service type

getServiceType

public GPServiceType getServiceType()
Gets the service type.

Returns:
the service type

setMaximumRecords

public void setMaximumRecords(int maxRecords)
Sets the maximum records that can be returned by the geoprocessing service. The default value is 1000. This value must be set before the service is started for it to have an effect.

Parameters:
maxRecords - the maximum records

getMaximumRecords

public int getMaximumRecords()
Gets the maximum number of records.

Returns:
the maximum number of records


Copyright © 2012. All Rights Reserved.