nl::Weave::Plataforma:PersistedStorage

Resumen

Typedefs

Key typedef

Funciones

Read(Key aKey, uint32_t & aValue)
Lee el valor entero de una clave del almacenamiento persistente.
Read(const char *aKey, uint32_t & aValue)
Write(Key aKey, uint32_t aValue)
Escribe el valor entero de una clave en el almacenamiento persistente.
Write(const char *aKey, uint32_t aValue)

Typedefs

Clave

WEAVE_CONFIG_PERSISTED_STORAGE_KEY_TYPE Key

Funciones

Lectura

WEAVE_ERROR Read(
  Key aKey,
  uint32_t & aValue
)

Lee el valor entero de una clave del almacenamiento persistente.

La plataforma es responsable de validar aKey.

Detalles
Parámetros
[in] aKey
Una clave para un valor almacenado de forma persistente
[in,out] aValue
Una referencia a un valor de número entero.
Qué muestra
WEAVE_ERROR_INVALID_ARGUMENT si aKey es NULL WEAVE_ERROR_INVALID_STRING_LENGTH si aKey supera WEAVE_CONFIG_PERSISTED_STORAGE_MAX_KEY_LENGTH WEAVE_ERROR_PERSISTED_STORAGE_VALUE_NOT_FOUND si aKey no existe WEAVE_NO_ERROR de lo contrario

Lectura

WEAVE_ERROR Read(
  const char *aKey,
  uint32_t & aValue
)

Escritura

WEAVE_ERROR Write(
  Key aKey,
  uint32_t aValue
)

Escribe el valor entero de una clave en el almacenamiento persistente.

La plataforma es responsable de validar aKey. Si aKey no existe, se creará y se asignará un aValue. De lo contrario, cualquier valor existente de aKey se reemplazará por aValue.

Detalles
Parámetros
[in] aKey
Una clave para un valor almacenado de forma persistente
[in] aValue
Es el valor.
Qué muestra
WEAVE_ERROR_INVALID_ARGUMENT si aKey es NULL WEAVE_ERROR_INVALID_STRING_LENGTH si aKey supera WEAVE_CONFIG_PERSISTED_STORAGE_MAX_KEY_LENGTH WEAVE_NO_ERROR

Escritura

WEAVE_ERROR Write(
  const char *aKey,
  uint32_t aValue
)