mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 02:16:05 +01:00 
			
		
		
		
	updated API docs
This commit is contained in:
		| @@ -1,380 +0,0 @@ | ||||
| <!DOCTYPE html> | ||||
| <html lang="en"> | ||||
| <head> | ||||
|     <meta charset="utf-8"> | ||||
|     <title>JSDoc: Class: ApiToken</title> | ||||
|  | ||||
|     <script src="scripts/prettify/prettify.js"> </script> | ||||
|     <script src="scripts/prettify/lang-css.js"> </script> | ||||
|     <!--[if lt IE 9]> | ||||
|       <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script> | ||||
|     <![endif]--> | ||||
|     <link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css"> | ||||
|     <link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css"> | ||||
| </head> | ||||
|  | ||||
| <body> | ||||
|  | ||||
| <div id="main"> | ||||
|  | ||||
|     <h1 class="page-title">Class: ApiToken</h1> | ||||
|  | ||||
|      | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
| <section> | ||||
|  | ||||
| <header> | ||||
|      | ||||
|         <h2><span class="attribs"><span class="type-signature"></span></span>ApiToken<span class="signature">()</span><span class="type-signature"></span></h2> | ||||
|          | ||||
|             <div class="class-description">ApiToken is an entity representing token used to authenticate against Trilium API from client applications. Currently used only by Trilium Sender.</div> | ||||
|          | ||||
|      | ||||
| </header> | ||||
|  | ||||
| <article> | ||||
|     <div class="container-overview"> | ||||
|      | ||||
|          | ||||
|  | ||||
|      | ||||
|     <h2>Constructor</h2> | ||||
|      | ||||
|  | ||||
|      | ||||
|     <h4 class="name" id="ApiToken"><span class="type-signature"></span>new ApiToken<span class="signature">()</span><span class="type-signature"></span></h4> | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
| <dl class="details"> | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_api_token.js.html">becca/entities/api_token.js</a>, <a href="becca_entities_api_token.js.html#line9">line 9</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
| </dl> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|      | ||||
|     </div> | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|         <h3 class="subsection-title">Members</h3> | ||||
|  | ||||
|          | ||||
|              | ||||
| <h4 class="name" id="apiTokenId"><span class="type-signature"></span>apiTokenId<span class="type-signature"> :string</span></h4> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|     <h5>Type:</h5> | ||||
|     <ul> | ||||
|         <li> | ||||
|              | ||||
| <span class="param-type">string</span> | ||||
|  | ||||
|  | ||||
|         </li> | ||||
|     </ul> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
| <dl class="details"> | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_api_token.js.html">becca/entities/api_token.js</a>, <a href="becca_entities_api_token.js.html#line18">line 18</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
| </dl> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|          | ||||
|              | ||||
| <h4 class="name" id="token"><span class="type-signature"></span>token<span class="type-signature"> :string</span></h4> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|     <h5>Type:</h5> | ||||
|     <ul> | ||||
|         <li> | ||||
|              | ||||
| <span class="param-type">string</span> | ||||
|  | ||||
|  | ||||
|         </li> | ||||
|     </ul> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
| <dl class="details"> | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_api_token.js.html">becca/entities/api_token.js</a>, <a href="becca_entities_api_token.js.html#line20">line 20</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
| </dl> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|          | ||||
|              | ||||
| <h4 class="name" id="utcDateCreated"><span class="type-signature"></span>utcDateCreated<span class="type-signature"> :string</span></h4> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|     <h5>Type:</h5> | ||||
|     <ul> | ||||
|         <li> | ||||
|              | ||||
| <span class="param-type">string</span> | ||||
|  | ||||
|  | ||||
|         </li> | ||||
|     </ul> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
| <dl class="details"> | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_api_token.js.html">becca/entities/api_token.js</a>, <a href="becca_entities_api_token.js.html#line22">line 22</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
| </dl> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|          | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
| </article> | ||||
|  | ||||
| </section> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
| </div> | ||||
|  | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|  | ||||
| <footer> | ||||
|     Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 3.6.7</a> | ||||
| </footer> | ||||
|  | ||||
| <script> prettyPrint(); </script> | ||||
| <script src="scripts/linenumber.js"> </script> | ||||
| </body> | ||||
| </html> | ||||
| @@ -1022,7 +1022,7 @@ and relation (representing named relationship between source and target note)</d | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -663,7 +663,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line407">line 407</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line417">line 417</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -1783,7 +1783,7 @@ JSON MIME type. See also createNewNote() for more options. | ||||
|  | ||||
|  | ||||
| <div class="description"> | ||||
|     If there's a branch between note and parent note, remove it. Otherwise do nothing. | ||||
|     If there's a branch between note and parent note, remove it. Otherwise, do nothing. | ||||
| </div> | ||||
|  | ||||
|  | ||||
| @@ -1961,7 +1961,7 @@ JSON MIME type. See also createNewNote() for more options. | ||||
|  | ||||
|  | ||||
| <div class="description"> | ||||
|     If there's no branch between note and parent note, create one. Otherwise do nothing. | ||||
|     If there's no branch between note and parent note, create one. Otherwise, do nothing. | ||||
| </div> | ||||
|  | ||||
|  | ||||
| @@ -2059,7 +2059,7 @@ JSON MIME type. See also createNewNote() for more options. | ||||
|  | ||||
|              | ||||
|  | ||||
|             <td class="description last">if branch will be create between note and parent note, set this prefix</td> | ||||
|             <td class="description last">if branch will be created between note and parent note, set this prefix</td> | ||||
|         </tr> | ||||
|  | ||||
|      | ||||
| @@ -2251,7 +2251,7 @@ JSON MIME type. See also createNewNote() for more options. | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line395">line 395</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line405">line 405</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -2357,7 +2357,7 @@ JSON MIME type. See also createNewNote() for more options. | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line418">line 418</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line428">line 428</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -2815,6 +2815,8 @@ JSON MIME type. See also createNewNote() for more options. | ||||
|      | ||||
|  | ||||
|      | ||||
|         <dt class="important tag-deprecated">Deprecated:</dt><dd><ul class="dummy"><li>use getDayNote instead</li></ul></dd> | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
| @@ -2827,7 +2829,165 @@ JSON MIME type. See also createNewNote() for more options. | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line313">line 313</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line314">line 314</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
| </dl> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
| <h5>Returns:</h5> | ||||
|  | ||||
|          | ||||
|  | ||||
|  | ||||
| <dl> | ||||
|     <dt> | ||||
|         Type | ||||
|     </dt> | ||||
|     <dd> | ||||
|          | ||||
| <span class="param-type"><a href="Note.html">Note</a></span> | ||||
| | | ||||
|  | ||||
| <span class="param-type">null</span> | ||||
|  | ||||
|  | ||||
|     </dd> | ||||
| </dl> | ||||
|  | ||||
|      | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|          | ||||
|              | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|     <h4 class="name" id="getDayNote"><span class="type-signature"></span>getDayNote<span class="signature">(date)</span><span class="type-signature"> → {<a href="Note.html">Note</a>|null}</span></h4> | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|  | ||||
|  | ||||
| <div class="description"> | ||||
|     Returns day note for given date. If such note doesn't exist, it is created. | ||||
| </div> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|     <h5>Parameters:</h5> | ||||
|      | ||||
|  | ||||
| <table class="params"> | ||||
|     <thead> | ||||
|     <tr> | ||||
|          | ||||
|         <th>Name</th> | ||||
|          | ||||
|  | ||||
|         <th>Type</th> | ||||
|  | ||||
|          | ||||
|  | ||||
|          | ||||
|  | ||||
|         <th class="last">Description</th> | ||||
|     </tr> | ||||
|     </thead> | ||||
|  | ||||
|     <tbody> | ||||
|      | ||||
|  | ||||
|         <tr> | ||||
|              | ||||
|                 <td class="name"><code>date</code></td> | ||||
|              | ||||
|  | ||||
|             <td class="type"> | ||||
|              | ||||
|                  | ||||
| <span class="param-type">string</span> | ||||
|  | ||||
|  | ||||
|              | ||||
|             </td> | ||||
|  | ||||
|              | ||||
|  | ||||
|              | ||||
|  | ||||
|             <td class="description last">in YYYY-MM-DD format</td> | ||||
|         </tr> | ||||
|  | ||||
|      | ||||
|     </tbody> | ||||
| </table> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
| <dl class="details"> | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|  | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line323">line 323</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -3095,7 +3255,7 @@ if some action needs to happen on only one specific instance. | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line340">line 340</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line350">line 350</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -3866,7 +4026,7 @@ if some action needs to happen on only one specific instance. | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line321">line 321</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line331">line 331</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -4047,7 +4207,7 @@ if some action needs to happen on only one specific instance. | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line331">line 331</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line341">line 341</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -4205,7 +4365,7 @@ if some action needs to happen on only one specific instance. | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line349">line 349</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line359">line 359</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -4495,7 +4655,7 @@ if some action needs to happen on only one specific instance. | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line388">line 388</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line398">line 398</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -4603,7 +4763,7 @@ if some action needs to happen on only one specific instance. | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line413">line 413</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line423">line 423</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -5195,7 +5355,7 @@ This method looks similar to toggleNoteInParent() but differs because we're look | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line369">line 369</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line379">line 379</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -5328,7 +5488,7 @@ This method looks similar to toggleNoteInParent() but differs because we're look | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line355">line 355</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line365">line 365</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -5690,7 +5850,7 @@ exists, then we'll use that transaction. | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line379">line 379</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line389">line 389</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -5845,7 +6005,7 @@ exists, then we'll use that transaction. | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line402">line 402</a> | ||||
|         <a href="services_backend_script_api.js.html">services/backend_script_api.js</a>, <a href="services_backend_script_api.js.html#line412">line 412</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -5915,7 +6075,7 @@ exists, then we'll use that transaction. | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -754,7 +754,7 @@ parents.</div> | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -1517,7 +1517,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line398">line 398</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line402">line 402</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -1619,7 +1619,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1014">line 1014</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1018">line 1018</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -1721,7 +1721,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line936">line 936</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line940">line 940</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -1827,7 +1827,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line858">line 858</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line862">line 862</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -2001,7 +2001,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line516">line 516</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line520">line 520</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -2201,7 +2201,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line329">line 329</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line333">line 333</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -2379,7 +2379,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line527">line 527</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line531">line 531</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -2490,7 +2490,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line143">line 143</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line147">line 147</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -2592,7 +2592,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line163">line 163</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line167">line 167</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -2694,7 +2694,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line153">line 153</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line157">line 157</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -2796,7 +2796,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line177">line 177</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line181">line 181</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -2898,7 +2898,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line211">line 211</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line215">line 215</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -3006,7 +3006,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line653">line 653</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line657">line 657</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -3112,7 +3112,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line222">line 222</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line226">line 226</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -3263,7 +3263,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line458">line 458</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line462">line 462</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -3433,7 +3433,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line548">line 548</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line552">line 552</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -3588,7 +3588,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line482">line 482</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line486">line 486</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -3758,7 +3758,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line556">line 556</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line560">line 560</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -3864,7 +3864,7 @@ | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line622">line 622</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line626">line 626</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -4066,7 +4066,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line597">line 597</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line601">line 601</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -4244,7 +4244,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line538">line 538</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line542">line 542</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -4402,7 +4402,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line464">line 464</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line468">line 468</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -4572,7 +4572,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line564">line 564</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line568">line 568</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -4727,7 +4727,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line488">line 488</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line492">line 492</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -4897,7 +4897,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line572">line 572</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line576">line 576</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -5052,7 +5052,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line476">line 476</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line480">line 480</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -5222,7 +5222,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line588">line 588</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line592">line 592</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -5377,7 +5377,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line500">line 500</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line504">line 504</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -5486,7 +5486,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line135">line 135</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line139">line 139</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -5588,7 +5588,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line148">line 148</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line152">line 152</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -5739,7 +5739,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line470">line 470</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line474">line 474</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -5909,7 +5909,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line580">line 580</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line584">line 584</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -6064,7 +6064,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line494">line 494</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line498">line 498</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -6173,7 +6173,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line308">line 308</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line312">line 312</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -6282,7 +6282,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line801">line 801</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line805">line 805</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -6384,7 +6384,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line780">line 780</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line784">line 784</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -6486,7 +6486,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line749">line 749</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line753">line 753</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -6588,7 +6588,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line898">line 898</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line902">line 902</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -6695,7 +6695,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line882">line 882</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line886">line 886</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -6797,7 +6797,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line158">line 158</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line162">line 162</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -6948,7 +6948,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line434">line 434</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line438">line 438</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -7126,7 +7126,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line507">line 507</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line511">line 511</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -7281,7 +7281,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line440">line 440</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line444">line 444</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -7436,7 +7436,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line452">line 452</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line456">line 456</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -7591,7 +7591,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line446">line 446</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line450">line 450</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -7741,7 +7741,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line957">line 957</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line961">line 961</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -7847,7 +7847,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line297">line 297</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line301">line 301</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -7953,7 +7953,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line289">line 289</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line293">line 293</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -8059,7 +8059,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line284">line 284</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line288">line 288</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -8165,7 +8165,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line279">line 279</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line283">line 283</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -8271,7 +8271,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line303">line 303</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line307">line 307</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -8504,7 +8504,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1001">line 1001</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1005">line 1005</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -8684,7 +8684,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1092">line 1092</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1096">line 1096</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -8864,7 +8864,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1100">line 1100</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1104">line 1104</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -9075,7 +9075,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line970">line 970</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line974">line 974</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -9255,7 +9255,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1076">line 1076</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1080">line 1080</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -9415,7 +9415,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1084">line 1084</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1088">line 1088</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -9657,7 +9657,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1043">line 1043</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1047">line 1047</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -9868,7 +9868,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1059">line 1059</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1063">line 1063</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -10079,7 +10079,7 @@ This method can be significantly faster than the getAttribute() | ||||
|      | ||||
|     <dt class="tag-source">Source:</dt> | ||||
|     <dd class="tag-source"><ul class="dummy"><li> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1068">line 1068</a> | ||||
|         <a href="becca_entities_note.js.html">becca/entities/note.js</a>, <a href="becca_entities_note.js.html#line1072">line 1072</a> | ||||
|     </li></ul></dd> | ||||
|      | ||||
|  | ||||
| @@ -10127,7 +10127,7 @@ This method can be significantly faster than the getAttribute() | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -1292,7 +1292,7 @@ It's used for seamless note versioning.</div> | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -433,7 +433,7 @@ | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -365,7 +365,7 @@ | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -1,87 +0,0 @@ | ||||
| <!DOCTYPE html> | ||||
| <html lang="en"> | ||||
| <head> | ||||
|     <meta charset="utf-8"> | ||||
|     <title>JSDoc: Source: becca/entities/api_token.js</title> | ||||
|  | ||||
|     <script src="scripts/prettify/prettify.js"> </script> | ||||
|     <script src="scripts/prettify/lang-css.js"> </script> | ||||
|     <!--[if lt IE 9]> | ||||
|       <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script> | ||||
|     <![endif]--> | ||||
|     <link type="text/css" rel="stylesheet" href="styles/prettify-tomorrow.css"> | ||||
|     <link type="text/css" rel="stylesheet" href="styles/jsdoc-default.css"> | ||||
| </head> | ||||
|  | ||||
| <body> | ||||
|  | ||||
| <div id="main"> | ||||
|  | ||||
|     <h1 class="page-title">Source: becca/entities/api_token.js</h1> | ||||
|  | ||||
|      | ||||
|  | ||||
|  | ||||
|  | ||||
|      | ||||
|     <section> | ||||
|         <article> | ||||
|             <pre class="prettyprint source linenums"><code>"use strict"; | ||||
|  | ||||
| const dateUtils = require('../../services/date_utils.js'); | ||||
| const AbstractEntity = require("./abstract_entity.js"); | ||||
|  | ||||
| /** | ||||
|  * ApiToken is an entity representing token used to authenticate against Trilium API from client applications. Currently used only by Trilium Sender. | ||||
|  */ | ||||
| class ApiToken extends AbstractEntity { | ||||
|     static get entityName() { return "api_tokens"; } | ||||
|     static get primaryKeyName() { return "apiTokenId"; } | ||||
|     static get hashedProperties() { return ["apiTokenId", "token", "utcDateCreated"]; } | ||||
|  | ||||
|     constructor(row) { | ||||
|         super(); | ||||
|  | ||||
|         /** @type {string} */ | ||||
|         this.apiTokenId = row.apiTokenId; | ||||
|         /** @type {string} */ | ||||
|         this.token = row.token; | ||||
|         /** @type {string} */ | ||||
|         this.utcDateCreated = row.utcDateCreated || dateUtils.utcNowDateTime(); | ||||
|     } | ||||
|  | ||||
|     getPojo() { | ||||
|         return { | ||||
|             apiTokenId: this.apiTokenId, | ||||
|             token: this.token, | ||||
|             utcDateCreated: this.utcDateCreated | ||||
|         } | ||||
|     } | ||||
| } | ||||
|  | ||||
| module.exports = ApiToken; | ||||
| </code></pre> | ||||
|         </article> | ||||
|     </section> | ||||
|  | ||||
|  | ||||
|  | ||||
|  | ||||
| </div> | ||||
|  | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|  | ||||
| <footer> | ||||
|     Documentation generated by <a href="https://github.com/jsdoc/jsdoc">JSDoc 3.6.7</a> | ||||
| </footer> | ||||
|  | ||||
| <script> prettyPrint(); </script> | ||||
| <script src="scripts/linenumber.js"> </script> | ||||
| </body> | ||||
| </html> | ||||
| @@ -28,10 +28,10 @@ | ||||
|         <article> | ||||
|             <pre class="prettyprint source linenums"><code>"use strict"; | ||||
|  | ||||
| const Note = require('./note.js'); | ||||
| const AbstractEntity = require("./abstract_entity.js"); | ||||
| const sql = require("../../services/sql.js"); | ||||
| const dateUtils = require("../../services/date_utils.js"); | ||||
| const Note = require('./note'); | ||||
| const AbstractEntity = require("./abstract_entity"); | ||||
| const sql = require("../../services/sql"); | ||||
| const dateUtils = require("../../services/date_utils"); | ||||
| const promotedAttributeDefinitionParser = require("../../services/promoted_attribute_definition_parser"); | ||||
|  | ||||
| /** | ||||
| @@ -247,7 +247,7 @@ module.exports = Attribute; | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -28,10 +28,10 @@ | ||||
|         <article> | ||||
|             <pre class="prettyprint source linenums"><code>"use strict"; | ||||
|  | ||||
| const Note = require('./note.js'); | ||||
| const AbstractEntity = require("./abstract_entity.js"); | ||||
| const sql = require("../../services/sql.js"); | ||||
| const dateUtils = require("../../services/date_utils.js"); | ||||
| const Note = require('./note'); | ||||
| const AbstractEntity = require("./abstract_entity"); | ||||
| const sql = require("../../services/sql"); | ||||
| const dateUtils = require("../../services/date_utils"); | ||||
|  | ||||
| /** | ||||
|  * Branch represents a relationship between a child note and its parent note. Trilium allows a note to have multiple | ||||
| @@ -195,7 +195,7 @@ module.exports = Branch; | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -34,8 +34,8 @@ const sql = require('../../services/sql'); | ||||
| const utils = require('../../services/utils'); | ||||
| const dateUtils = require('../../services/date_utils'); | ||||
| const entityChangesService = require('../../services/entity_changes'); | ||||
| const AbstractEntity = require("./abstract_entity.js"); | ||||
| const NoteRevision = require("./note_revision.js"); | ||||
| const AbstractEntity = require("./abstract_entity"); | ||||
| const NoteRevision = require("./note_revision"); | ||||
|  | ||||
| const LABEL = 'label'; | ||||
| const RELATION = 'relation'; | ||||
| @@ -159,6 +159,10 @@ class Note extends AbstractEntity { | ||||
|             || protectedSessionService.isProtectedSessionAvailable() | ||||
|     } | ||||
|  | ||||
|     getTitleOrProtected() { | ||||
|         return this.isContentAvailable() ? this.title : '[protected]'; | ||||
|     } | ||||
|  | ||||
|     /** @returns {Branch[]} */ | ||||
|     getParentBranches() { | ||||
|         return this.parentBranches; | ||||
| @@ -1008,7 +1012,7 @@ class Note extends AbstractEntity { | ||||
|             } | ||||
|         } | ||||
|         else { | ||||
|             const Attribute = require("./attribute.js"); | ||||
|             const Attribute = require("./attribute"); | ||||
|  | ||||
|             new Attribute({ | ||||
|                 noteId: this.noteId, | ||||
| @@ -1040,7 +1044,7 @@ class Note extends AbstractEntity { | ||||
|      * @return {Attribute} | ||||
|      */ | ||||
|     addAttribute(type, name, value = "", isInheritable = false, position = 1000) { | ||||
|         const Attribute = require("./attribute.js"); | ||||
|         const Attribute = require("./attribute"); | ||||
|  | ||||
|         return new Attribute({ | ||||
|             noteId: this.noteId, | ||||
| @@ -1216,7 +1220,7 @@ module.exports = Note; | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -32,9 +32,9 @@ const protectedSessionService = require('../../services/protected_session'); | ||||
| const utils = require('../../services/utils'); | ||||
| const sql = require('../../services/sql'); | ||||
| const dateUtils = require('../../services/date_utils'); | ||||
| const becca = require('../becca.js'); | ||||
| const becca = require('../becca'); | ||||
| const entityChangesService = require('../../services/entity_changes'); | ||||
| const AbstractEntity = require("./abstract_entity.js"); | ||||
| const AbstractEntity = require("./abstract_entity"); | ||||
|  | ||||
| /** | ||||
|  * NoteRevision represents snapshot of note's title and content at some point in the past. | ||||
| @@ -232,7 +232,7 @@ module.exports = NoteRevision; | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -28,8 +28,8 @@ | ||||
|         <article> | ||||
|             <pre class="prettyprint source linenums"><code>"use strict"; | ||||
|  | ||||
| const dateUtils = require('../../services/date_utils.js'); | ||||
| const AbstractEntity = require("./abstract_entity.js"); | ||||
| const dateUtils = require('../../services/date_utils'); | ||||
| const AbstractEntity = require("./abstract_entity"); | ||||
|  | ||||
| /** | ||||
|  * Option represents name-value pair, either directly configurable by the user or some system property. | ||||
| @@ -83,7 +83,7 @@ module.exports = Option; | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -28,8 +28,8 @@ | ||||
|         <article> | ||||
|             <pre class="prettyprint source linenums"><code>"use strict"; | ||||
|  | ||||
| const dateUtils = require('../../services/date_utils.js'); | ||||
| const AbstractEntity = require("./abstract_entity.js"); | ||||
| const dateUtils = require('../../services/date_utils'); | ||||
| const AbstractEntity = require("./abstract_entity"); | ||||
|  | ||||
| /** | ||||
|  * RecentNote represents recently visited note. | ||||
| @@ -71,7 +71,7 @@ module.exports = RecentNote; | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -1085,7 +1085,7 @@ | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -52,7 +52,7 @@ | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -162,18 +162,18 @@ function BackendScriptApi(currentNote, apiParams) { | ||||
|     this.getNoteWithLabel = attributeService.getNoteWithLabel; | ||||
|  | ||||
|     /** | ||||
|      * If there's no branch between note and parent note, create one. Otherwise do nothing. | ||||
|      * If there's no branch between note and parent note, create one. Otherwise, do nothing. | ||||
|      * | ||||
|      * @method | ||||
|      * @param {string} noteId | ||||
|      * @param {string} parentNoteId | ||||
|      * @param {string} prefix - if branch will be create between note and parent note, set this prefix | ||||
|      * @param {string} prefix - if branch will be created between note and parent note, set this prefix | ||||
|      * @returns {void} | ||||
|      */ | ||||
|     this.ensureNoteIsPresentInParent = cloningService.ensureNoteIsPresentInParent; | ||||
|  | ||||
|     /** | ||||
|      * If there's a branch between note and parent note, remove it. Otherwise do nothing. | ||||
|      * If there's a branch between note and parent note, remove it. Otherwise, do nothing. | ||||
|      * | ||||
|      * @method | ||||
|      * @param {string} noteId | ||||
| @@ -337,8 +337,18 @@ function BackendScriptApi(currentNote, apiParams) { | ||||
|      * @method | ||||
|      * @param {string} date in YYYY-MM-DD format | ||||
|      * @returns {Note|null} | ||||
|      * @deprecated use getDayNote instead | ||||
|      */ | ||||
|     this.getDateNote = dateNoteService.getDateNote; | ||||
|     this.getDateNote = dateNoteService.getDayNote; | ||||
|  | ||||
|     /** | ||||
|      * Returns day note for given date. If such note doesn't exist, it is created. | ||||
|      * | ||||
|      * @method | ||||
|      * @param {string} date in YYYY-MM-DD format | ||||
|      * @returns {Note|null} | ||||
|      */ | ||||
|     this.getDayNote = dateNoteService.getDayNote; | ||||
|  | ||||
|     /** | ||||
|      * Returns today's day note. If such note doesn't exist, it is created. | ||||
| @@ -459,7 +469,7 @@ module.exports = BackendScriptApi; | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
| @@ -42,6 +42,8 @@ const cls = require('./cls'); | ||||
| const dbConnection = new Database(dataDir.DOCUMENT_PATH); | ||||
| dbConnection.pragma('journal_mode = WAL'); | ||||
|  | ||||
| const LOG_ALL_QUERIES = false; | ||||
|  | ||||
| [`exit`, `SIGINT`, `SIGUSR1`, `SIGUSR2`, `SIGTERM`].forEach(eventType => { | ||||
|     process.on(eventType, () => { | ||||
|         if (dbConnection) { | ||||
| @@ -163,6 +165,10 @@ function getRawRows(query, params = []) { | ||||
| } | ||||
|  | ||||
| function iterateRows(query, params = []) { | ||||
|     if (LOG_ALL_QUERIES) { | ||||
|         console.log(query); | ||||
|     } | ||||
|  | ||||
|     return stmt(query).iterate(params); | ||||
| } | ||||
|  | ||||
| @@ -185,11 +191,11 @@ function execute(query, params = []) { | ||||
|     return wrap(query, s => s.run(params)); | ||||
| } | ||||
|  | ||||
| function executeWithoutTransaction(query, params = []) { | ||||
|     dbConnection.run(query, params); | ||||
| } | ||||
|  | ||||
| function executeMany(query, params) { | ||||
|     if (LOG_ALL_QUERIES) { | ||||
|         console.log(query); | ||||
|     } | ||||
|  | ||||
|     while (params.length > 0) { | ||||
|         const curParams = params.slice(0, Math.min(params.length, PARAM_LIMIT)); | ||||
|         params = params.slice(curParams.length); | ||||
| @@ -210,6 +216,10 @@ function executeMany(query, params) { | ||||
| } | ||||
|  | ||||
| function executeScript(query) { | ||||
|     if (LOG_ALL_QUERIES) { | ||||
|         console.log(query); | ||||
|     } | ||||
|  | ||||
|     return dbConnection.exec(query); | ||||
| } | ||||
|  | ||||
| @@ -217,6 +227,10 @@ function wrap(query, func) { | ||||
|     const startTimestamp = Date.now(); | ||||
|     let result; | ||||
|  | ||||
|     if (LOG_ALL_QUERIES) { | ||||
|         console.log(query); | ||||
|     } | ||||
|  | ||||
|     try { | ||||
|         result = func(stmt(query)); | ||||
|     } | ||||
| @@ -359,7 +373,6 @@ module.exports = { | ||||
|      * @param {object[]} [params] - array of params if needed | ||||
|      */ | ||||
|     execute, | ||||
|     executeWithoutTransaction, | ||||
|     executeMany, | ||||
|     executeScript, | ||||
|     transactional, | ||||
| @@ -378,7 +391,7 @@ module.exports = { | ||||
| <nav> | ||||
|     <h2><a href="index.html">Home</a></h2><h3>Modules</h3><ul><li><a href="sql%250A%250ATODO_%2520some%2520methods%2520(like%2520getValue())%2520could%2520use%2520raw%2520rowsmodule_.html">sql | ||||
|  | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="ApiToken.html">ApiToken</a></li><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| TODO: some methods (like getValue()) could use raw rows</a></li></ul><h3>Classes</h3><ul><li><a href="Attribute.html">Attribute</a></li><li><a href="BackendScriptApi.html">BackendScriptApi</a></li><li><a href="Branch.html">Branch</a></li><li><a href="EtapiToken.html">EtapiToken</a></li><li><a href="Note.html">Note</a></li><li><a href="NoteRevision.html">NoteRevision</a></li><li><a href="Option.html">Option</a></li><li><a href="RecentNote.html">RecentNote</a></li></ul><h3><a href="global.html">Global</a></h3> | ||||
| </nav> | ||||
|  | ||||
| <br class="clear"> | ||||
|   | ||||
		Reference in New Issue
	
	Block a user