OpenLayers. WPSProcess

Representation of a WPS process.  Usually instances of OpenLayers.WPSProcess are created by calling ‘getProcess’ on an OpenLayers.WPSClient instance.

Currently OpenLayers.WPSProcess supports processes that have geometries or features as output, using WKT or GeoJSON as output format.  It also supports chaining of processes by using the output method to create a handle that is used as process input instead of a static value.

Summary
OpenLayers. WPSProcess Representation of a WPS process.
Properties
localWPS {String} Service endpoint for locally chained WPS processes.
Constructor
OpenLayers. WPSProcess
Functions
configure Configure the process, but do not execute it.
execute Configures and executes the process
output Chain an output of a configured process (see configure) as input to another process.
OpenLayers. WPSProcess. ChainLink Type for chaining processes.
Constructor
OpenLayers. WPSProcess. ChainLink

Properties

localWPS

{String} Service endpoint for locally chained WPS processes.  Default is ‘http://geoserver/wps’.

Constructor

OpenLayers. WPSProcess

Parameters

options {Object} Object whose properties will be set on the instance.

Avaliable options

client {OpenLayers.WPSClient} Mandatory.  Client that manages this process.
server {String} Mandatory.  Local client identifier of this process’s server.
identifier {String} Mandatory.  Process identifier known to the server.

Functions

configure

configure: function( options )

Configure the process, but do not execute it.  Use this for processes that are chained as input of a different process by means of the output method.

Parameters

options {Object}

Returns

{OpenLayers.WPSProcess} this process.

Available options

inputs {Object} The inputs for the process, keyed by input identifier.  For spatial data inputs, the value of an input is usually an OpenLayers.Geometry, an OpenLayers.Feature.Vector or an array of geometries or features.
callback {Function} Callback to call when the configuration is complete.  Optional.
scope {Object} Optional scope for the callback.

execute

execute: function( options )

Configures and executes the process

Parameters

options {Object}

Available options

inputs {Object} The inputs for the process, keyed by input identifier.  For spatial data inputs, the value of an input is usually an OpenLayers.Geometry, an OpenLayers.Feature.Vector or an array of geometries or features.
output {String} The identifier of the output to request and parse.  Optional.  If not provided, the first output will be requested.
success {Function} Callback to call when the process is complete.  This function is called with an outputs object as argument, which will have a property with the identifier of the requested output (or ‘result’ if output was not configured).  For processes that generate spatial output, the value will be an array of OpenLayers.Feature.Vector instances.
scope {Object} Optional scope for the success callback.

output

output: function( identifier )

Chain an output of a configured process (see configure) as input to another process.

intersect = client.getProcess('opengeo', 'JTS:intersection');
intersect.configure({
    // ...
});
buffer = client.getProcess('opengeo', 'JTS:buffer');
buffer.execute({
    inputs: {
        geom: intersect.output('result'), // <-- here we're chaining
        distance: 1
    },
    // ...
});

Parameters

identifier {String} Identifier of the output that we’re chaining.  If not provided, the first output will be used.

OpenLayers. WPSProcess. ChainLink

Type for chaining processes.

Constructor

OpenLayers. WPSProcess. ChainLink

Parameters

options {Object} Properties to set on the instance.
configure: function( options )
Configure the process, but do not execute it.
execute: function( options )
Configures and executes the process
output: function( identifier )
Chain an output of a configured process (see configure) as input to another process.
High level API for interaction with Web Processing Services (WPS).
A Geometry is a description of a geographic object.
Vector features use the OpenLayers.Geometry classes as geometry description.
Close