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__types.html below:

LiteCore: Basic Fleece Data Types

typedef const struct _FLValue *  FLValue   A reference to a value of any type.
  typedef const struct _FLArray *  FLArray   A reference to an array value.
  typedef const struct _FLDict *  FLDict   A reference to a dictionary (map) value.
  typedef struct _FLSlot *  FLSlot   A reference to a mutable array/dict item.
  typedef struct _FLArray *  FLMutableArray   A reference to a mutable array.
  typedef struct _FLDict *  FLMutableDict   A reference to a mutable dictionary.
  typedef struct _FLEncoder *  FLEncoder   A reference to an encoder.
  typedef struct _FLDoc *  FLDoc   A reference to a document.
  typedef struct _FLSharedKeys *  FLSharedKeys   A reference to a shared-keys mapping.
  enum   FLError {
  kFLNoError = 0 , kFLMemoryError , kFLOutOfRange , kFLInvalidData ,
  kFLEncodeError , kFLJSONError , kFLUnknownValue , kFLInternalError ,
  kFLNotFound , kFLSharedKeysStateError , kFLPOSIXError , kFLUnsupported
}   Error codes returned from some API calls. More...
  enum   FLTrust { kFLUntrusted , kFLTrusted }   Specifies whether not input data is trusted to be 100% valid Fleece. More...
 

Fleece does not have a native type for dates or times; like JSON, they are represented as strings in ISO-8601 format, which look like "2008-08-07T05:18:51.589Z".

They can also be represented more compactly as numbers, interpreted as milliseconds since the Unix epoch (midnight at January 1 1970, UTC.)

typedef int64_t  FLTimestamp   A point in time, expressed as milliseconds since the Unix epoch (1-1-1970 midnight UTC.)
  FLEECE_PUBLIC FLTimestamp  FLTimestamp_Now (void)   Returns an FLTimestamp corresponding to the current time.
  FLEECE_PUBLIC FLStringResult  FLTimestamp_ToString (FLTimestamp timestamp, bool asUTC)   Formats a timestamp as a date-time string in ISO-8601 format.
  FLEECE_PUBLIC FLTimestamp  FLTimestamp_FromString (FLString str)   Parses an ISO-8601 date-time string to a timestamp.
  #define  FLTimestampNone   INT64_MIN   A value representing a missing timestamp; returned when a date cannot be parsed.
  ◆ FLTimestampNone #define FLTimestampNone   INT64_MIN

A value representing a missing timestamp; returned when a date cannot be parsed.

◆ FLArray typedef const struct _FLArray* FLArray

A reference to an array value.

◆ FLDict typedef const struct _FLDict* FLDict

A reference to a dictionary (map) value.

◆ FLDoc typedef struct _FLDoc* FLDoc

A reference to a document.

◆ FLEncoder

A reference to an encoder.

◆ FLMutableArray

A reference to a mutable array.

◆ FLMutableDict

A reference to a mutable dictionary.

◆ FLSharedKeys

A reference to a shared-keys mapping.

◆ FLSlot typedef struct _FLSlot* FLSlot

A reference to a mutable array/dict item.

◆ FLTimestamp

A point in time, expressed as milliseconds since the Unix epoch (1-1-1970 midnight UTC.)

◆ FLValue typedef const struct _FLValue* FLValue

A reference to a value of any type.

◆ FLError

Error codes returned from some API calls.

Enumerator kFLNoError  kFLMemoryError  kFLOutOfRange  kFLInvalidData  kFLEncodeError  kFLJSONError  kFLUnknownValue  kFLInternalError  kFLNotFound  kFLSharedKeysStateError  kFLPOSIXError  kFLUnsupported  ◆ FLTrust

Specifies whether not input data is trusted to be 100% valid Fleece.

Enumerator kFLUntrusted 

Input data is not trusted to be valid, and will be fully validated by the API call.

kFLTrusted 

Input data is trusted to be valid.

The API will perform only minimal validation when reading it. This is faster than kFLUntrusted, but should only be used if the data was generated by a trusted encoder and has not been altered or corrupted. For example, this can be used to parse Fleece data previously stored by your code in local storage. If invalid data is read by this call, subsequent calls to Value accessor functions can crash or return bogus results (including data from arbitrary memory locations.)

◆ FLTimestamp_FromString()

Parses an ISO-8601 date-time string to a timestamp.

On failure returns FLTimestampNone.

Note
See also FLValue_AsTimestamp, which takes an FLValue and interprets numeric representations as well as strings.
◆ FLTimestamp_Now()

Returns an FLTimestamp corresponding to the current time.

◆ FLTimestamp_ToString()

Formats a timestamp as a date-time string in ISO-8601 format.

Note
See also FLEncoder_WriteDateString, which writes a timestamp to an FLEncoder.
Parameters
timestamp A time, given as milliseconds since the Unix epoch (1/1/1970 00:00 UTC.) asUTC If true, the timestamp will be given in universal time; if false, in the local timezone.
Returns
A heap-allocated string, which you are responsible for releasing.

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