@@ -131,6 +131,7 @@ function wipeOutputTransform(/*headers, data*/) {
131131 * {@link https://www.promisejs.org/|Promises} object for chaining
132132 * actions with then() functions.
133133 * @name ResultProvider#result
134+ * @since 1.0
134135 * @function
135136 * @param {function } [success] - a callback invoked when the request succeeds
136137 * @param {function } [failure] - a callback invoked when the request fails
@@ -140,6 +141,7 @@ function wipeOutputTransform(/*headers, data*/) {
140141 * Returns a ReadableStream object in object mode for receiving results as
141142 * complete objects.
142143 * @name ResultProvider#stream
144+ * @since 1.0
143145 * @function
144146 * @returns {object } a {@link http://nodejs.org/api/stream.html#stream_class_stream_readable|ReadableStream}
145147 * object
@@ -150,6 +152,7 @@ function wipeOutputTransform(/*headers, data*/) {
150152 * from the server, or for another document operation. The descriptor may have
151153 * more or fewer properties depending on the operation.
152154 * @typedef {object } documents.DocumentDescriptor
155+ * @since 1.0
153156 * @property {string } uri - the identifier for the document in the database
154157 * @property {object|string|Buffer|ReadableStream } [content] - the content
155158 * of the document; when writing a ReadableStream for the content, first pause
@@ -172,12 +175,14 @@ function wipeOutputTransform(/*headers, data*/) {
172175 * content|collections|permissions|properties|quality|metadataValues|metadata where
173176 * metadata is an alias for all of the categories other than content.
174177 * @typedef {enum } documents.categories
178+ * @since 1.0
175179 */
176180
177181/**
178182 * A success callback for {@link ResultProvider} that receives the result from
179183 * the {@link documents#probe}.
180184 * @callback documents#probeResult
185+ * @since 1.0
181186 * @param {documents.DocumentDescriptor } document - a sparse document descriptor with an exists
182187 * property that identifies whether the document exists
183188 */
@@ -186,6 +191,7 @@ function wipeOutputTransform(/*headers, data*/) {
186191 * object with the following named parameters or, as a shortcut,
187192 * a uri string.
188193 * @method documents#probe
194+ * @since 1.0
189195 * @param {string } uri - the uri for the database document
190196 * @param {string|transactions.Transaction } [txid] - a string
191197 * transaction id or Transaction object identifying an open
@@ -251,13 +257,15 @@ function probeDocumentsImpl(contentOnly, args) {
251257 * A success callback for {@link ResultProvider} that receives the result from
252258 * the {@link documents#protect}.
253259 * @callback documents#protectResult
260+ * @since 2.0.1
254261 * @param {documents.DocumentDescriptor } document - a sparse document descriptor
255262 * for the protected document
256263 */
257264/**
258265 * Protects a temporal document from temporal operations for a
259266 * period of time.
260267 * @method documents#protect
268+ * @since 2.0.1
261269 * @param {string } uri - the uri for the temporal document to protect
262270 * @param {string } temporalCollection - the temporal collection for the document
263271 * @param {string } [duration] - a protection duration; either a duration or an
@@ -375,12 +383,14 @@ Documents.prototype.protect = function protectDocument() {
375383 * A success callback for {@link ResultProvider} that receives the result from
376384 * the {@link documents#wipe}.
377385 * @callback documents#wipeResult
386+ * @since 2.0.1
378387 * @param {documents.DocumentDescriptor } document - a sparse document descriptor
379388 * for the wipe command
380389 */
381390/**
382391 * Deletes all versions of a temporal document.
383392 * @method documents#wipe
393+ * @since 2.0.1
384394 * @param {string } uri - the uri for the temporal document to wipe
385395 * @param {string } temporalCollection - the name of the temporal collection
386396 * @returns {ResultProvider } an object whose result() function takes
@@ -500,6 +510,7 @@ function singleReadOutputTransform(headers, data) {
500510 * A success callback for {@link ResultProvider} that receives the result from
501511 * the {@link documents#read}.
502512 * @callback documents#resultList
513+ * @since 1.0
503514 * @param {documents.DocumentDescriptor[] } documents - an array of
504515 * {@link documents.DocumentDescriptor} objects with the requested
505516 * metadata and/or content for the documents
@@ -509,6 +520,7 @@ function singleReadOutputTransform(headers, data) {
509520 * the following named parameters or, as a shortcut, one or more
510521 * uri strings or an array of uri strings.
511522 * @method documents#read
523+ * @since 1.0
512524 * @param {string|string[] } uris - the uri string or an array of uri strings
513525 * for the database documents
514526 * @param {documents.categories|documents.categories[] } [categories] - the categories of information
@@ -681,6 +693,7 @@ function readDocumentsImpl(contentOnly, args) {
681693 * a stream; takes a {@link documents.DocumentDescriptor} object with the
682694 * following properties (but not a content property).
683695 * @method documents#createWriteStream
696+ * @since 1.0
684697 * @param {string } uri - the identifier for the document to write to the database
685698 * @param {string[] } [collections] - the collections to which the document should belong
686699 * @param {object[] } [permissions] - the permissions controlling which users can read or
@@ -826,6 +839,7 @@ function writeListOutputTransform(headers, data) {
826839 * the {@link documents#write} or the {@link documents#createWriteStream}
827840 * functions.
828841 * @callback documents#writeResult
842+ * @since 1.0
829843 * @param {object } response - a response with a documents property providing
830844 * a sparse array of array of {@link documents.DocumentDescriptor} objects
831845 * providing the uris of the written documents.
@@ -834,6 +848,7 @@ function writeListOutputTransform(headers, data) {
834848 * Writes one or more documents; takes a configuration object with
835849 * the following named parameters or, as a shortcut, a document descriptor.
836850 * @method documents#write
851+ * @since 1.0
837852 * @param {DocumentDescriptor|DocumentDescriptor[] } documents - one descriptor
838853 * or an array of document descriptors to write
839854 * @param {documents.categories|documents.categories[] } [categories] - the categories of information
@@ -1387,6 +1402,7 @@ function removeOutputTransform(headers/*, data*/) {
13871402 * A success callback for {@link ResultProvider} that receives the result from
13881403 * the {@link documents#remove}.
13891404 * @callback documents#removeResult
1405+ * @since 1.0
13901406 * @param {documents.DocumentDescriptor } document - a sparse document descriptor
13911407 * for the removed document
13921408 */
@@ -1395,6 +1411,7 @@ function removeOutputTransform(headers/*, data*/) {
13951411 * object with the following named parameters or, as a shortcut, one or more
13961412 * uri strings or an array of uri strings.
13971413 * @method documents#remove
1414+ * @since 1.0
13981415 * @param {string|string[] } uris - the uri string or an array of uri strings
13991416 * identifying the database documents
14001417 * @param {string|transactions.Transaction } [txid] - a string
@@ -1519,6 +1536,7 @@ function removeAllOutputTransform(/*headers, data*/) {
15191536 * have the rest-admin role to to delete all documents and the rest-writer
15201537 * role otherwise.
15211538 * @method documents#removeAll
1539+ * @since 1.0
15221540 * @param {string } [collection] - the collection whose documents should be
15231541 * deleted
15241542 * @param {string } [directory] - a directory whose documents should be
@@ -1607,6 +1625,7 @@ function listOutputTransform(headers, data) {
16071625/**
16081626 * Defines a query in the structure accepted by the REST API.
16091627 * @typedef {object } documents.CombinedQueryDefinition
1628+ * @since 1.0
16101629 * @property {object } search - a combined query, which can have properties
16111630 * for a structured query, a string query, and query options
16121631 * @property {documents.categories|documents.categories[] } [categories] - the categories
@@ -1632,6 +1651,7 @@ function listOutputTransform(headers, data) {
16321651 * Executes a query built by a {@link queryBuilder} to match one or more
16331652 * documents.
16341653 * @method documents#query
1654+ * @since 1.0
16351655 * @param {object } query - a query built by a {@link queryBuilder} or
16361656 * a {@link documents.CombinedQueryDefinition}
16371657 * @returns {ResultProvider } an object whose result() function takes
@@ -1791,6 +1811,7 @@ function patchOutputTransform(/*headers, data*/) {
17911811 * A success callback for {@link ResultProvider} that receives the result from
17921812 * the {@link documents#patch} function.
17931813 * @callback documents#patchResult
1814+ * @since 1.0
17941815 * @param {object } document - a sparse {@link documents.DocumentDescriptor} object
17951816 * providing the uri of the patched document.
17961817 */
@@ -1799,6 +1820,7 @@ function patchOutputTransform(/*headers, data*/) {
17991820 * the following named parameters or, as a shortcut, a uri string and
18001821 * one or more patch operations produced by a {@link patchBuilder}.
18011822 * @method documents#patch
1823+ * @since 1.0
18021824 * @param {string } uri - the uri
18031825 * @param {patchOperation|patchOperation[] } operations - delete, insert,
18041826 * or replace operations produced by a {@link patchBuilder} to apply
@@ -1968,6 +1990,7 @@ Documents.prototype.patch = function patchDocuments() {
19681990 * You may pass a configuration object with the following named parameters or,
19691991 * as a shortcut, the partial textual search, the query, and optionally bindings.
19701992 * @method documents#suggest
1993+ * @since 1.0
19711994 * @param {string } partial - the partial search string to complete
19721995 * @param {object } query - a query built by a {@link queryBuilder} or
19731996 * a {@link documents.CombinedQueryDefinition} that defines bindings in
0 commit comments