Home
Download
Wiki
Demo
Open Source Native XML Database
About Us
Who we are
Acknowledgements
Documentation
Quick Start
Main Documentation
eXist Developer's Blog
Extension Modules
Feature Sheet
Function Library
XQuery Wikibook
Examples
All Examples
Bibliographic Demo
XML Acronyms
XQuery IDE (eXide)
XQuery Sandbox
Community
Mailing Lists
IRC Chat
Social Media
Development
Bug Tracker
ChangeLog
Javadoc
Source code
Submit Patches
Administration
Admin
Webstart Client
A RESTful browser for eXist Function Modules
Modules
>
counter
counter
http://exist-db.org/xquery/counter
A module for persistent counters.
create
counter:create($counter-name as item()) xs:long?
Create a unique counter named $counter-name.
$counter-name
Name of the counter.
Returns the value of the newly created counter.
create
counter:create($counter-name as item(), $init-value as xs:long) xs:long?
Create a unique counter named $counter-name and initialize it with value $init-value.
$counter-name
Name of the counter.
$init-value
The initial value of the counter.
Returns the value of the newly created counter.
destroy
counter:destroy($counter-name as item()) xs:boolean?
Destroy the counter named $counter-name.
$counter-name
Name of the counter.
Returns boolean value true() if removal as successful, otherwise return value false().
next-value
counter:next-value($counter-name as item()) xs:long?
Increment the counter $counter-name and return its new value.
$counter-name
Name of the counter.
Returns the new value of the specified counter, or -1 if the counter does not exist.
Return to list of all modules