The copy
method returns a copy of the array. Modifying the copy does not modify the original array.
copy()
(LuaJsonArray). A copy of the array.
local myJsonArray = LuaJsonArray:new(4,"a string",true) local anotherJsonArray = myJsonArray:copy() print (anotherJsonArray:string()) -- [4, "a string", true]
|