Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| deegree 2.4 (2010/11/11 10:47 build-27-official)
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.deegree.ogcwebservices.wfs.operation.transaction
Class Transaction

    java.lang.Object
      org.deegree.ogcwebservices.AbstractOGCWebServiceRequest
          org.deegree.ogcwebservices.wfs.operation.AbstractWFSRequest
              org.deegree.ogcwebservices.wfs.operation.transaction.Transaction

All Implemented Interfaces:
  Serializable, OGCWebServiceRequest

    public class Transaction

extends AbstractWFSRequest

Represents a `Transaction` request to a web feature service.

A `Transaction` consists of a sequence of `Insert`, `Update`, `Delete` and `Native` operations.

From the WFS Specification 1.1.0 OGC 04-094 (#12, Pg.63):

A `Transaction` request is used to describe data transformation operations that are to be applied to web accessible feature instances. When the transaction has been completed, a web feature service will generate an XML response document indicating the completion status of the transaction.

Version:
  $Revision: 23794 $, $Date: 2010-04-23 15:05:33 +0200 (Fr, 23. Apr 2010) $
Author:
  Markus Schneider , last edited by: $Author: aionita $
See Also:
  Serialized Form

Nested Class Summary
`static class` | `Transaction.RELEASE_ACTION` Controls how locked features are treated when a transaction request is completed.

Field Summary

Fields inherited from class org.deegree.ogcwebservices.wfs.operation.AbstractWFSRequest
`FORMAT_GML2, FORMAT_GML2_WFS100, FORMAT_GML3, FORMAT_XML`

Constructor Summary
`Transaction(String id, String version, Map<String,String> versionSpecificParameter, String lockID, List<TransactionOperation> operations, boolean releaseAllFeatures, TransactionDocument sourceDocument)` Creates a new `Transaction` instance.

Method Summary
`static Transaction` | `create(Map<String,String> model)` Creates a `Transaction` request from a key-value-pair encoding of the parameters contained in the given Map.
`static Transaction` | `create(String id, Element root)` Creates a `Transaction` instance from a document that contains the DOM representation of the request.
`static Transaction` | `create(String id, String request)` Creates a `Transaction` request from a key-value-pair encoding of the parameters contained in the passed variable 'request'.
`Set<QualifiedName>` | `getAffectedFeatureTypes()` Returns the names of the feature types that are affected by the transaction.
`String` | `getLockId()` Returns the lock identifier associated with this transaction.
`List<TransactionOperation>` | `getOperations()` Returns the `TransactionOperation`s that are contained in the transaction.
`Transaction.RELEASE_ACTION` | `getReleaseAction()` Returns the release action mode to be applied after the transaction finished successfully.
`TransactionDocument` | `getSourceDocument()` Returns the source document that was used to create this `Transaction` instance.
`void` | `guessMissingNamespaces(WFService wfs)` Adds missing namespaces in the names of requested feature types.
`String` | `toString()`

Methods inherited from class org.deegree.ogcwebservices.wfs.operation.AbstractWFSRequest
`checkServiceParameter, checkVersionParameter, extractBBOXFilter, extractFilters, extractNamespaceParameter, extractTypeNames, getHandle, getServiceName`

Methods inherited from class org.deegree.ogcwebservices.AbstractOGCWebServiceRequest
`getId, getParam, getParamAsInt, getParamValues, getRequestParameter, getRequiredParam, getVendorSpecificParameter, getVendorSpecificParameters, getVersion`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### Transaction

    public Transaction(String id,
                       String version,
                       Map<String,String> versionSpecificParameter,
                       String lockID,
                       List<TransactionOperation> operations,
                       boolean releaseAllFeatures,
                       TransactionDocument sourceDocument)

  Creates a new `Transaction` instance.

  Parameters:
    `version` - WFS version
    `id` - Transaction id
    `versionSpecificParameter` -
    `lockID` - Lock Id
    `operations` - List of operations to be carried out
    `releaseAllFeatures` -
    `sourceDocument` -

Method Detail

### getSourceDocument

    public TransactionDocument getSourceDocument()

  Returns the source document that was used to create this `Transaction` instance.

  Returns:
    the source document

### getOperations

    public List<TransactionOperation> getOperations()

  Returns the `TransactionOperation`s that are contained in the transaction.

  Returns:
    the contained operations

### getLockId

    public String getLockId()

  Returns the lock identifier associated with this transaction.

  Returns:
    the lock identifier associated with this transaction if it exists, null otherwise

### getReleaseAction

    public Transaction.RELEASE_ACTION getReleaseAction()

  Returns the release action mode to be applied after the transaction finished successfully.

  Returns:
    the release action mode to be applied after the transaction finished successfully
  See Also:
    `Transaction.RELEASE_ACTION`

### getAffectedFeatureTypes

    public Set<QualifiedName> getAffectedFeatureTypes()

  Returns the names of the feature types that are affected by the transaction.

  Returns:
    the names of the affected feature types

### create

    public static Transaction create(String id,
                                     String request)
                              throws InconsistentRequestException,
                                     InvalidParameterValueException,
                                     MissingParameterValueException

  Creates a `Transaction` request from a key-value-pair encoding of the parameters contained in the passed variable 'request'.

  Parameters:
    `id` - id of the request
    `request` - key-value-pair encoded GetFeature request
  Returns:
    new created Transaction instance
  Throws:
    `InconsistentRequestException`
    `InvalidParameterValueException`
    `MissingParameterValueException`

### create

    public static Transaction create(Map<String,String> model)
                              throws InconsistentRequestException,
                                     InvalidParameterValueException,
                                     MissingParameterValueException

  Creates a `Transaction` request from a key-value-pair encoding of the parameters contained in the given Map.

  Parameters:
    `model` - key-value-pair encoded Transaction request
  Returns:
    new Transaction instance
  Throws:
    `InconsistentRequestException`
    `InvalidParameterValueException`
    `MissingParameterValueException`

### create

    public static Transaction create(String id,
                                     Element root)
                              throws OGCWebServiceException

  Creates a `Transaction` instance from a document that contains the DOM representation of the request.

  Parameters:
    `id` -
    `root` - element that contains the DOM representation of the request
  Returns:
    transaction instance
  Throws:
    `OGCWebServiceException`

### toString

    public String toString()

  Overrides:
    `toString` in class `AbstractOGCWebServiceRequest`

### guessMissingNamespaces

    public void guessMissingNamespaces(WFService wfs)

  Adds missing namespaces in the names of requested feature types.

  If the `QualifiedName` of a requested type has a null namespace, the first qualified feature type name of the given `WFService` with the same local name is used instead.

  Note: The method changes this request (the feature type names) and should only be called by the `WFSHandler` class.

  Parameters:
    `wfs` - `WFService` instance that is used for the lookup of proper (qualified) feature type names

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| deegree 2.4 (2010/11/11 10:47 build-27-official)
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org