GenerateOfflineMapJob class final
A job that generates and downloads the offline map for a specific area of interest from a web map that is enabled for offline use.
This job is part of the on-demand offline workflow. Use this job to generate and download the offline map to your device so that you can work offline without a network connection.
To make a GenerateOfflineMapJob, use the OfflineMapTask as follows:
- Construct and load the OfflineMapTask with a web map that is enabled for offline use. For more information about enabling web maps for offline use see Take web maps offline.
- If necessary, check the web map's offline capabilities by using OfflineMapTask.getOfflineMapCapabilities.
- Create a Geometry to define the area of interest that you wish to take offline.
- Obtain the default GenerateOfflineMapParameters for the area of interest by calling OfflineMapTask.createDefaultGenerateOfflineMapParameters.
- Use the GenerateOfflineMapParameters to create a GenerateOfflineMapJob by calling OfflineMapTask.generateOfflineMap. You must specify a path to a folder where the map content will be stored on the device.
Start the GenerateOfflineMapJob and monitor progress. Upon completion, the job's GenerateOfflineMapResult provides the offline map along with the details of any errors incurred during the generate and download process.
See the Job class for full information on how to work with jobs.
- Inheritance
-
- Object
- Job<
GenerateOfflineMapResult> - GenerateOfflineMapJob
Properties
- downloadDirectoryUri → Uri
-
The download directory used by this job to write the mobile map package
result.
no setter
- error → ArcGISException?
-
Contains an error if the job fails, otherwise null.
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
-
messages
→ List<
JobMessage> -
The job's messages.
no setterinherited
-
onJobDone
→ Stream<
void> -
Sets the function that will be called when the job is done.
no setterinherited
- onlineMap → ArcGISMap?
-
The online map used by this job.
no setter
-
onMessageAdded
→ Stream<
JobMessage> -
Indicates that a new
JobMessage
was added to Job.messages.no setterinherited -
onProgressChanged
→ Stream<
int> -
Sets the function that will be called when the job's progress has changed.
no setterinherited
-
onStatusChanged
→ Stream<
JobStatus> -
Indicates that the Job.status property has changed.
no setterinherited
- parameterOverrides → GenerateOfflineMapParameterOverrides?
-
The parameter overrides used by this job. Can be null.
no setter
- parameters → GenerateOfflineMapParameters
-
The parameters used by this job.
no setter
- progress → int
-
The current progress of the job as a percentage complete.
no setterinherited
- result → GenerateOfflineMapResult?
-
The result of a succeeded generate offline map job.
no setteroverride
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- serverJobId → String
-
The server job Id of the job.
no setterinherited
- status → JobStatus
-
The status of the job.
no setterinherited
Methods
-
cancel(
) → Future< bool> -
Cancels this Job and waits for any asynchronous, server-side operations
to be canceled.
inherited
-
checkStatus(
) → Future< bool> -
Initiates a request to check the server status.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
pause(
) → bool -
Pauses the job.
inherited
-
run(
) → Future< GenerateOfflineMapResult> -
Starts the job and returns a Future that completes with either the result
of the job or an error if the job did not finish successfully.
inherited
-
start(
) → bool -
Starts the job if the job is not started or paused.
inherited
-
toJson(
) → Map< String, dynamic> -
Returns a JSON representation of this Object in the data type used by jsonDecode.
inherited
-
toJsonString(
) → String -
Returns a JSON representation of this Object as a String.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited