|
|
cpf:failure(
|
|
$docid as xs:string,
|
|
$transition as element(*, p:transition)?,
|
|
$exception as node()?,
|
|
$override-state as xs:anyURI?
|
| ) as empty() |
|
 |
Summary:
Concludes the state action in failure, advancing the state as defined by the
state transition. The state action must call this method to indicate
failure, passing the external variables $cpf:document-uri,
$cpf:transition, and $cpf:exception as parameters.
If the document does not exist, do nothing.
Side effects: Advances the document state to the transition's
on-failure state, if any, and marks the document as processed in the
current state.
|
Parameters:
$docid
:
The URI of the document.
|
$transition
:
The pipeline transition being executed.
|
$exception
:
The exception leading to the processing failure, if any.
|
$override-state
:
The next state of the document, overriding the transition state.
|
|
Example:
import module namespace cpf = "http://marklogic.com/cpf"
at "/MarkLogic/cpf/cpf.xqy"
define variable $cpf:document-uri as xs:string external
define variable $cpf:transition as node() external
define variable $cpf:exception as node() external
cpf:failure( $cpf:document-uri, $cpf:transition, $cpf:exception, () )
|
|
|
|
cpf:success(
|
|
$docid as xs:string,
|
|
$transition as element(*, p:transition)?,
|
|
$override-state as xs:anyURI?
|
| ) as empty() |
|
 |
Summary:
Concludes the action successfully, advancing the state as defined by the
transition. The action must call this method to indicate
completion of successful processing, passing the external variables
$cpf:document-uri and $cpf:transition as
parameters. If the document does not exist, do nothing.
Side effects: Advances the document state to the transition's on-success
state, if any, and marks the document as processed in the current state.
|
Parameters:
$docid
:
The URI of the document.
|
$transition
:
The pipeline transition being executed.
|
$override-state
:
The next state of the document, overriding the transition state.
|
|
Example:
import module namespace cpf = "http://marklogic.com/cpf"
at "/MarkLogic/cpf/cpf.xqy"
define variable $cpf:document-uri as xs:string external
define variable $cpf:transition as node() external
cpf:success( $cpf:document-uri, $cpf:transition, () )
|
|
|