2.1 KiB
2.1 KiB
title, icon, excerpt
title | icon | excerpt |
---|---|---|
ArmaRAMDb - List Delete | mdi:file-text-outline | Delete an entire list stored at a key from RAMDb. |
ramdb_db_fnc_listDelete
Description
Completely removes a list and all its elements stored at a specified key from the RAMDb database. This function provides a way to delete entire collections of data at once, rather than removing individual elements. It is useful for cleaning up obsolete data, resetting collections, or removing temporary lists that are no longer needed.
Syntax
[_key] call ramdb_db_fnc_listDelete
Parameters
Parameter | Type | Description | Default |
---|---|---|---|
_key | String | The key identifying the list to be deleted | "" |
Return Value
None. The operation runs synchronously to delete the list immediately.
Examples
Delete an event log:
["eventLog"] call ramdb_db_fnc_listDelete;
Remove temporary mission data:
["tempMissionData"] call ramdb_db_fnc_listDelete;
Delete a list in multiplayer:
["sharedTempData"] remoteExecCall ["ramdb_db_fnc_listDelete", 2, false];
Notes
- This function deletes the entire list and all its elements associated with the specified key.
- Unlike
listRemove
, which removes a single element by index, this function removes the complete list structure. - The
_key
parameter must be a non-empty string, otherwise the function will exit without performing any action. - Once a list is deleted, it cannot be recovered unless you have previously saved or backed up the data.
- If you need to selectively remove elements while preserving the list structure, use
ramdb_db_fnc_listRemove
instead. - The deletion operation is permanent and cannot be undone.
- All list operations are logged for debugging purposes.
Related Functions
- ramdb_db_fnc_listAdd
- ramdb_db_fnc_listGet
- ramdb_db_fnc_listLoad
- ramdb_db_fnc_listRemove
- ramdb_db_fnc_listSet
Links
List Add | List Get | List Load | List Remove | List Set | List Delete