
All checks were successful
Build / Build (push) Successful in 40s
This commit adds documentation for the `ramdb_db_fnc_fetch` function. The documentation explains the function's purpose, which is to handle data chunks received from the database extension when data is too large to be returned in a single callback. The documentation includes a title, icon, and excerpt for better readability and understanding.
221 lines
10 KiB
XML
221 lines
10 KiB
XML
<?xml version='1.0' encoding='UTF-8' standalone='no'?>
|
|
<section xmlns="http://docbook.org/ns/docbook" version="5.0" xmlns:xlink="http://www.w3.org/1999/xlink" xml:id="_dir_49e56c817e5e54854c35e136979f97ca" xml:lang="en-US">
|
|
<title>docs Directory Reference</title>
|
|
<indexterm><primary>docs Directory Reference</primary></indexterm>
|
|
<simplesect>
|
|
<title>Directories </title>
|
|
<itemizedlist>
|
|
<listitem><para>directory <link linkend="_dir_2d423acf5473bc48906ca316d2995d8f">basic</link></para>
|
|
</listitem>
|
|
<listitem><para>directory <link linkend="_dir_771164b9325b04f1442f7a3ffa8ecb89">core</link></para>
|
|
</listitem>
|
|
<listitem><para>directory <link linkend="_dir_68588e5a097ce704ed28814d68b1b590">hash</link></para>
|
|
</listitem>
|
|
<listitem><para>directory <link linkend="_dir_abd30d11711bae4cb17b258a1e3909ca">list</link></para>
|
|
</listitem>
|
|
</itemizedlist>
|
|
</simplesect>
|
|
<section>
|
|
<title>Detailed Description</title>
|
|
|
|
<para>This documentation provides details on all functions available in <computeroutput>ArmaRAMDb</computeroutput>. These functions allow you to interact with the in-memory database system for Arma 3.</para>
|
|
<section xml:id="_README.md_1autotoc_md424">
|
|
<title>Function Categories</title>
|
|
<para>The functions are categorized by their purpose:</para>
|
|
<section xml:id="_README.md_1autotoc_md425">
|
|
<title>Core Functions</title>
|
|
<para><itemizedlist>
|
|
<listitem>
|
|
<para><link linkend="_md_docs_2core_2init">init</link> - Initialize the database system</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2core_2handler">handler</link> - Handle callbacks from the extension</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2core_2process_queue">processQueue</link> - Process queued database operations</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2core_2scheduler">scheduler</link> - Schedule database operations</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2core_2add_task">addTask</link> - Add a task to the scheduler</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2core_2print_addon_name">printAddonName</link> - Print the addon name</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2core_2test">test</link> - Test the database connection</para>
|
|
</listitem></itemizedlist>
|
|
</para>
|
|
</section>
|
|
<section xml:id="_README.md_1autotoc_md426">
|
|
<title>Basic Data Operations</title>
|
|
<para><itemizedlist>
|
|
<listitem>
|
|
<para><link linkend="_md_docs_2basic_2get">get</link> - Get a value from the database</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2basic_2set">set</link> - Set a value in the database</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2basic_2delete">delete</link> - Delete a value from the database</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2basic_2save">save</link> - Save the database to disk</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2basic_2load">load</link> - Load the database from disk</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2basic_2fetch">fetch</link> - Fetch a value from the database</para>
|
|
</listitem></itemizedlist>
|
|
</para>
|
|
</section>
|
|
<section xml:id="_README.md_1autotoc_md427">
|
|
<title>Hash Operations</title>
|
|
<para><itemizedlist>
|
|
<listitem>
|
|
<para><link linkend="_md_docs_2hash_2hash_delete">hashDelete</link> - Delete a hash</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2hash_2hash_delete_id">hashDeleteId</link> - Delete a hash for a specific ID</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2hash_2hash_get">hashGet</link> - Get a field from a hash</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2hash_2hash_get_all">hashGetAll</link> - Get all fields from a hash</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2hash_2hash_get_all_id">hashGetAllId</link> - Get all fields from a hash for a specific ID</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2hash_2hash_get_id">hashGetId</link> - Get a field from a hash for a specific ID</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2hash_2hash_remove">hashRemove</link> - Remove a field from a hash</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2hash_2hash_remove_id">hashRemoveId</link> - Remove a field from a hash for a specific ID</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2hash_2hash_set">hashSet</link> - Set a field in a hash</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2hash_2hash_set_bulk">hashSetBulk</link> - Set multiple fields in a hash in one operation</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2hash_2hash_set_id">hashSetId</link> - Set a field in a hash for a specific ID</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2hash_2hash_set_id_bulk">hashSetIdBulk</link> - Set multiple fields in a hash for a specific ID in one operation</para>
|
|
</listitem></itemizedlist>
|
|
</para>
|
|
</section>
|
|
<section xml:id="_README.md_1autotoc_md428">
|
|
<title>List Operations</title>
|
|
<para><itemizedlist>
|
|
<listitem>
|
|
<para><link linkend="_md_docs_2list_2list_add">listAdd</link> - Add an item to a list</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2list_2list_delete">listDelete</link> - Delete a list</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2list_2list_get">listGet</link> - Get items from a list</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2list_2list_load">listLoad</link> - Load a list from the database</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2list_2list_remove">listRemove</link> - Remove an item from a list</para>
|
|
</listitem><listitem>
|
|
<para><link linkend="_md_docs_2list_2list_set">listSet</link> - Set an item in a list</para>
|
|
</listitem></itemizedlist>
|
|
</para>
|
|
</section>
|
|
</section>
|
|
<section xml:id="_README.md_1autotoc_md429">
|
|
<title>Usage Examples</title><section xml:id="_README.md_1autotoc_md430">
|
|
<title>Basic Usage</title>
|
|
<para><literallayout><computeroutput>// Initialize the database
|
|
[] call ramdb_db_fnc_init;
|
|
|
|
// Set a value
|
|
["myKey", [myValue]] call ramdb_db_fnc_set;
|
|
|
|
// Get a value
|
|
["myKey", "myFunction"] call ramdb_db_fnc_get;
|
|
|
|
// Delete a key
|
|
["myKey"] call ramdb_db_fnc_delete;
|
|
</computeroutput></literallayout></para>
|
|
</section>
|
|
<section xml:id="_README.md_1autotoc_md431">
|
|
<title>Hash Operations</title>
|
|
<para><literallayout><computeroutput>// Set a hash field (context mode)
|
|
["myField", [myValue]] call ramdb_db_fnc_hashSet;
|
|
|
|
// Get a hash field (context mode)
|
|
["myField", "myFunction"] call ramdb_db_fnc_hashGet;
|
|
|
|
// Get all hash fields (context mode)
|
|
["myFunction"] call ramdb_db_fnc_hashGetAll;
|
|
|
|
// Set multiple hash fields (context mode)
|
|
[[
|
|
    "loadout", [getUnitLoadout player],
|
|
    "position", [getPosASL player],
|
|
    "direction", [getDir player],
|
|
    "stance", [stance player]
|
|
]] call ramdb_db_fnc_hashSetBulk;
|
|
|
|
// Remove a hash field (context mode)
|
|
["myField"] call ramdb_db_fnc_hashRemove;
|
|
|
|
// Delete a hash table (context mode)
|
|
[] call ramdb_db_fnc_hashDelete;
|
|
</computeroutput></literallayout> <literallayout><computeroutput>// Set a hash field for specific ID
|
|
["myHash", "myField", [myValue]] call ramdb_db_fnc_hashSetId;
|
|
|
|
// Get a hash field for specific ID
|
|
["myHash", "myField", "myFunction"] call ramdb_db_fnc_hashGetId;
|
|
|
|
// Get all hash fields for specific ID
|
|
["myHash"] call ramdb_db_fnc_hashGetAllId;
|
|
|
|
// Set multiple hash fields for specific ID
|
|
[[
|
|
    getPlayerUID player,
|
|
    "loadout", [getUnitLoadout player],
|
|
    "position", [getPosASL player],
|
|
    "direction", [getDir player],
|
|
    "stance", [stance player]
|
|
]] call ramdb_db_fnc_hashSetIdBulk;
|
|
|
|
// Remove a hash field for specific ID
|
|
["myHash", "myField"] call ramdb_db_fnc_hashRemoveId;
|
|
|
|
// Delete a hash table for specific ID
|
|
["myHash"] call ramdb_db_fnc_hashDeleteId;
|
|
</computeroutput></literallayout></para>
|
|
</section>
|
|
<section xml:id="_README.md_1autotoc_md432">
|
|
<title>List Operations</title>
|
|
<para><literallayout><computeroutput>// Add an item to a list
|
|
["myList", ["myItem"]] call ramdb_db_fnc_listAdd;
|
|
|
|
// Set an item from a list
|
|
["myList", 0, [myNewValue]] call ramdb_db_fnc_listSet;
|
|
|
|
// Get an item from a list
|
|
["myList", 0, "myFunction"] call ramdb_db_fnc_listGet;
|
|
|
|
// Get items from a list
|
|
["myList", "myFunction"] call ramdb_db_fnc_listLoad;
|
|
|
|
// Remove an item from a list
|
|
["myList", 0] call ramdb_db_fnc_listRemove;
|
|
|
|
// Delete a list
|
|
["myList"] call ramdb_db_fnc_listDelete;
|
|
</computeroutput></literallayout></para>
|
|
</section>
|
|
</section>
|
|
<section xml:id="_README.md_1autotoc_md433">
|
|
<title>Function Documentation Structure</title>
|
|
<para>Each function documentation includes:<itemizedlist>
|
|
<listitem>
|
|
<para>Function name and purpose</para>
|
|
</listitem><listitem>
|
|
<para>Parameters</para>
|
|
</listitem><listitem>
|
|
<para>Return value</para>
|
|
</listitem><listitem>
|
|
<para>Examples</para>
|
|
</listitem><listitem>
|
|
<para>Notes and warnings</para>
|
|
</listitem></itemizedlist>
|
|
</para>
|
|
</section>
|
|
<section xml:id="_README.md_1autotoc_md434">
|
|
<title>License</title>
|
|
<para>This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License. To view a copy of this license, visit <link xlink:href="https://creativecommons.org/licenses/by-nc-sa/4.0/">https://creativecommons.org/licenses/by-nc-sa/4.0/</link> or send a letter to Creative Commons, <?linebreak?>PO Box 1866, Mountain View, CA 94042 </para>
|
|
</section>
|
|
</section>
|
|
</section>
|