A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://couchbase.github.io/couchbase-lite-core/C/html/group___slots.html below:

LiteCore: Value Slots

An FLSlot is a temporary reference to an element of a mutable Array/Dict; its only purpose is to let you store a value into it, using the FLSlot_... functions. More...

NODISCARD FLEECE_PUBLIC FLSlot  FLMutableArray_Set (FLMutableArray, uint32_t index)   Returns an FLSlot that refers to the given index of the given array.
  NODISCARD FLEECE_PUBLIC FLSlot  FLMutableArray_Append (FLMutableArray)   Appends a null value to the array and returns an FLSlot that refers to that position.
  NODISCARD FLEECE_PUBLIC FLSlot  FLMutableDict_Set (FLMutableDict, FLString key)   Returns an FLSlot that refers to the given key/value pair of the given dictionary.
  FLEECE_PUBLIC void  FLSlot_SetNull (FLSlot)   Stores a JSON null into a slot.
  FLEECE_PUBLIC void  FLSlot_SetBool (FLSlot, bool)   Stores a boolean into a slot.
  FLEECE_PUBLIC void  FLSlot_SetInt (FLSlot, int64_t)   Stores an integer into a slot.
  FLEECE_PUBLIC void  FLSlot_SetUInt (FLSlot, uint64_t)   Stores an unsigned int into a slot.
  FLEECE_PUBLIC void  FLSlot_SetFloat (FLSlot, float)   Stores a float into a slot.
  FLEECE_PUBLIC void  FLSlot_SetDouble (FLSlot, double)   Stores a double into a slot.
  FLEECE_PUBLIC void  FLSlot_SetString (FLSlot, FLString)   Stores a UTF-8 string into a slot.
  FLEECE_PUBLIC void  FLSlot_SetData (FLSlot, FLSlice)   Stores a data blob into a slot.
  FLEECE_PUBLIC void  FLSlot_SetValue (FLSlot, FLValue)   Stores an FLValue into a slot.
  static void  FLSlot_SetArray (FLSlot slot, FLArray array)   static void  FLSlot_SetDict (FLSlot slot, FLDict dict)  

An FLSlot is a temporary reference to an element of a mutable Array/Dict; its only purpose is to let you store a value into it, using the FLSlot_... functions.

Since there are three ways to store a value into a collection (array set, array append, dict set) and nine types of values that can be stored, that makes 27 setter functions. For efficiency, these are declared as inlines that call one of three functions to acquire a slot, and one of nine functions to store a value into it.

It's usually more convenient to use the typed functions like FLMutableArray_SetInt, but you might drop down to the lower level ones if you're creating an adapter between Fleece and a different data model, such as Apple's Foundation classes.

◆ FLMutableArray_Append()

Appends a null value to the array and returns an FLSlot that refers to that position.

You store a value to it by calling one of the nine FLSlot_Set... functions.

Warning
You should immediately store a value into the FLSlot. Do not keep it around; any changes to the array invalidate it.
◆ FLMutableArray_Set()

Returns an FLSlot that refers to the given index of the given array.

You store a value to it by calling one of the nine FLSlot_Set... functions.

Warning
You should immediately store a value into the FLSlot. Do not keep it around; any changes to the array invalidate it.
◆ FLMutableDict_Set()

Returns an FLSlot that refers to the given key/value pair of the given dictionary.

You store a value to it by calling one of the nine FLSlot_Set... functions.

Warning
You should immediately store a value into the FLSlot. Do not keep it around; any changes to the dictionary invalidate it.
◆ FLSlot_SetArray() ◆ FLSlot_SetBool()

Stores a boolean into a slot.

◆ FLSlot_SetData()

Stores a data blob into a slot.

◆ FLSlot_SetDict() ◆ FLSlot_SetDouble()

Stores a double into a slot.

◆ FLSlot_SetFloat()

Stores a float into a slot.

◆ FLSlot_SetInt()

Stores an integer into a slot.

◆ FLSlot_SetNull()

Stores a JSON null into a slot.

◆ FLSlot_SetString()

Stores a UTF-8 string into a slot.

◆ FLSlot_SetUInt()

Stores an unsigned int into a slot.

◆ FLSlot_SetValue()

Stores an FLValue into a slot.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4