Open topic with navigation

# LuaJsonObject Methods

A `LuaJsonObject` object represents a JSON object.

If you have a `LuaJsonObject` object called `object` you can call its methods using the '`:`' operator. For example:

    object:size()

Constructor | Description
--- | ---
LuaJsonObject:new | The constructor for a `LuaJsonObject` object (creates a new `LuaJsonObject`).

Method | Description
--- | ---
assign | Adds an attribute (a name/value pair) to the object.
assign | Adds a table of attributes (name/value pairs) to the object.
clear | Clears the object, so that it contains no attributes.
copy | Copies the object.
empty | Checks whether the object is empty.
erase | Removes a specified attribute (name/value pair) from the object.
exists | Checks whether a specified path exists in the object.
existsByPath | Checks whether a specified path exists in the object.
lookup | Returns the value at a specified path in the object.
lookupByPath | Returns the value at a specified path in the object.
pairs | Returns an iterator function that you can use to iterate over all of the attributes in the object.
size | Returns the number of attributes (name/value pairs) contained in the object.
string | Returns the object as a string.

© Copyright 2019 Micro Focus or one of its affiliates | Send documentation feedback Close Send documentation feedback To open the configured email client on this computer, open an email window. Otherwise, copy the information below to a web mail client, and send this email to swpdl.idoldocsfeedback@microfocus.com. We appreciate your feedback! Product: Topic Title: Help Topic: Feedback:

_FT_HTML5_bannerTitle.htm