[{"data":1,"prerenderedAt":345},["ShallowReactive",2],{"content-query-qYifh3BG97":3},{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"title":8,"description":7,"icon":9,"body":10,"_type":339,"_id":340,"_source":341,"_file":342,"_stem":343,"_extension":344},"/dragonfly/lists/listadd","lists",false,"","ArmaDragonflyClient - List Add","mdi:file-text-outline",{"type":11,"children":12,"toc":324},"root",[13,22,29,35,41,54,60,153,159,164,170,177,186,192,201,207,216,222,281,287],{"type":14,"tag":15,"props":16,"children":18},"element","h1",{"id":17},"list-add",[19],{"type":20,"value":21},"text","List Add",{"type":14,"tag":23,"props":24,"children":26},"h2",{"id":25},"description",[27],{"type":20,"value":28},"Description",{"type":14,"tag":30,"props":31,"children":32},"p",{},[33],{"type":20,"value":34},"Adds an element to a list stored in the database under the specified key. This function appends values to an existing list or creates a new list if it doesn't exist. It's particularly useful for logging, event tracking, or maintaining collections of data that grow over time.",{"type":14,"tag":23,"props":36,"children":38},{"id":37},"syntax",[39],{"type":20,"value":40},"Syntax",{"type":14,"tag":42,"props":43,"children":48},"pre",{"className":44,"code":46,"language":47,"meta":7},[45],"language-sqf","[_key, _data] call dragonfly_db_fnc_listAdd\n","sqf",[49],{"type":14,"tag":50,"props":51,"children":52},"code",{"__ignoreMap":7},[53],{"type":20,"value":46},{"type":14,"tag":23,"props":55,"children":57},{"id":56},"parameters",[58],{"type":20,"value":59},"Parameters",{"type":14,"tag":61,"props":62,"children":63},"table",{},[64,92],{"type":14,"tag":65,"props":66,"children":67},"thead",{},[68],{"type":14,"tag":69,"props":70,"children":71},"tr",{},[72,78,83,87],{"type":14,"tag":73,"props":74,"children":75},"th",{},[76],{"type":20,"value":77},"Parameter",{"type":14,"tag":73,"props":79,"children":80},{},[81],{"type":20,"value":82},"Type",{"type":14,"tag":73,"props":84,"children":85},{},[86],{"type":20,"value":28},{"type":14,"tag":73,"props":88,"children":89},{},[90],{"type":20,"value":91},"Default",{"type":14,"tag":93,"props":94,"children":95},"tbody",{},[96,124],{"type":14,"tag":69,"props":97,"children":98},{},[99,109,114,119],{"type":14,"tag":100,"props":101,"children":102},"td",{},[103],{"type":14,"tag":50,"props":104,"children":106},{"className":105},[],[107],{"type":20,"value":108},"_key",{"type":14,"tag":100,"props":110,"children":111},{},[112],{"type":20,"value":113},"String",{"type":14,"tag":100,"props":115,"children":116},{},[117],{"type":20,"value":118},"Name of the list to add the element to",{"type":14,"tag":100,"props":120,"children":121},{},[122],{"type":20,"value":123},"\"\"",{"type":14,"tag":69,"props":125,"children":126},{},[127,136,141,146],{"type":14,"tag":100,"props":128,"children":129},{},[130],{"type":14,"tag":50,"props":131,"children":133},{"className":132},[],[134],{"type":20,"value":135},"_data",{"type":14,"tag":100,"props":137,"children":138},{},[139],{"type":20,"value":140},"Array, String, Number, or Boolean",{"type":14,"tag":100,"props":142,"children":143},{},[144],{"type":20,"value":145},"The value to insert into the list",{"type":14,"tag":100,"props":147,"children":148},{},[149],{"type":14,"tag":150,"props":151,"children":152},"span",{},[],{"type":14,"tag":23,"props":154,"children":156},{"id":155},"return-value",[157],{"type":20,"value":158},"Return Value",{"type":14,"tag":30,"props":160,"children":161},{},[162],{"type":20,"value":163},"None. The operation runs synchronously to add the element to the list.",{"type":14,"tag":23,"props":165,"children":167},{"id":166},"examples",[168],{"type":20,"value":169},"Examples",{"type":14,"tag":171,"props":172,"children":174},"h3",{"id":173},"add-an-event-log-entry",[175],{"type":20,"value":176},"Add an event log entry:",{"type":14,"tag":42,"props":178,"children":181},{"className":179,"code":180,"language":47,"meta":7},[45],"[\"events\", [\"Server state saved to DB \" + systemTimeUTC]] call dragonfly_db_fnc_listAdd;\n",[182],{"type":14,"tag":50,"props":183,"children":184},{"__ignoreMap":7},[185],{"type":20,"value":180},{"type":14,"tag":171,"props":187,"children":189},{"id":188},"add-a-player-message",[190],{"type":20,"value":191},"Add a player message:",{"type":14,"tag":42,"props":193,"children":196},{"className":194,"code":195,"language":47,"meta":7},[45],"[\"messages\", [name player + \": \" + _messageText]] call dragonfly_db_fnc_listAdd;\n",[197],{"type":14,"tag":50,"props":198,"children":199},{"__ignoreMap":7},[200],{"type":20,"value":195},{"type":14,"tag":171,"props":202,"children":204},{"id":203},"add-data-from-a-client",[205],{"type":20,"value":206},"Add data from a client:",{"type":14,"tag":42,"props":208,"children":211},{"className":209,"code":210,"language":47,"meta":7},[45],"[\"playerActions\", [getPlayerUID player, name player, \"logged in\"]] remoteExecCall [\"dragonfly_db_fnc_listAdd\", 2, false];\n",[212],{"type":14,"tag":50,"props":213,"children":214},{"__ignoreMap":7},[215],{"type":20,"value":210},{"type":14,"tag":23,"props":217,"children":219},{"id":218},"notes",[220],{"type":20,"value":221},"Notes",{"type":14,"tag":223,"props":224,"children":225},"ul",{},[226,232,237,256,261,266,271,276],{"type":14,"tag":227,"props":228,"children":229},"li",{},[230],{"type":20,"value":231},"Elements are added to the end of the list in the order they are inserted",{"type":14,"tag":227,"props":233,"children":234},{},[235],{"type":20,"value":236},"If the list doesn't exist, it will be created automatically",{"type":14,"tag":227,"props":238,"children":239},{},[240,242,247,249,254],{"type":20,"value":241},"Both the ",{"type":14,"tag":50,"props":243,"children":245},{"className":244},[],[246],{"type":20,"value":108},{"type":20,"value":248}," and ",{"type":14,"tag":50,"props":250,"children":252},{"className":251},[],[253],{"type":20,"value":135},{"type":20,"value":255}," parameters are required and validated",{"type":14,"tag":227,"props":257,"children":258},{},[259],{"type":20,"value":260},"Lists can store various data types (arrays, strings, numbers, or booleans)",{"type":14,"tag":227,"props":262,"children":263},{},[264],{"type":20,"value":265},"Useful for maintaining a history of events, logs, or sequential data",{"type":14,"tag":227,"props":267,"children":268},{},[269],{"type":20,"value":270},"The operation is executed immediately and synchronously",{"type":14,"tag":227,"props":272,"children":273},{},[274],{"type":20,"value":275},"New elements are always added to the end of the list",{"type":14,"tag":227,"props":277,"children":278},{},[279],{"type":20,"value":280},"All operations are logged for debugging purposes",{"type":14,"tag":23,"props":282,"children":284},{"id":283},"links",[285],{"type":20,"value":286},"Links",{"type":14,"tag":30,"props":288,"children":289},{},[290,295,297,303,304,310,311,317,318],{"type":14,"tag":291,"props":292,"children":293},"a",{"href":4},[294],{"type":20,"value":21},{"type":20,"value":296}," |\n",{"type":14,"tag":291,"props":298,"children":300},{"href":299},"/dragonfly/lists/listget",[301],{"type":20,"value":302},"List Get",{"type":20,"value":296},{"type":14,"tag":291,"props":305,"children":307},{"href":306},"/dragonfly/lists/listload",[308],{"type":20,"value":309},"List Load",{"type":20,"value":296},{"type":14,"tag":291,"props":312,"children":314},{"href":313},"/dragonfly/lists/listremove",[315],{"type":20,"value":316},"List Remove",{"type":20,"value":296},{"type":14,"tag":291,"props":319,"children":321},{"href":320},"/dragonfly/lists/listset",[322],{"type":20,"value":323},"List Set",{"title":7,"searchDepth":325,"depth":325,"links":326},2,[327,328,329,330,331,337,338],{"id":25,"depth":325,"text":28},{"id":37,"depth":325,"text":40},{"id":56,"depth":325,"text":59},{"id":155,"depth":325,"text":158},{"id":166,"depth":325,"text":169,"children":332},[333,335,336],{"id":173,"depth":334,"text":176},3,{"id":188,"depth":334,"text":191},{"id":203,"depth":334,"text":206},{"id":218,"depth":325,"text":221},{"id":283,"depth":325,"text":286},"markdown","content:dragonfly:lists:listAdd.md","content","dragonfly/lists/listAdd.md","dragonfly/lists/listAdd","md",1742777962588]