LiteCore
Couchbase Lite cross-platform core implementation
Loading...
Searching...
No Matches
FLSliceResult Struct Reference

A heap-allocated block of memory returned from an API call. More...

#include </Users/jzhao/work/Git/couchbase-lite-core/vendor/fleece/API/fleece/FLSlice.h>

Data Fields

const void *FL_NULLABLE buf
 
size_t size
 

Detailed Description

A heap-allocated block of memory returned from an API call.

The caller takes ownership, and must call FLSliceResult_Release when done with it.

Warning
The contents of the block must not be modified, since others may be using it.
Note
This is equivalent to the C++ class alloc_slice. In C++ the easiest way to deal with a FLSliceResult return value is to construct an alloc_slice from it, which will adopt the reference, and release it in its destructor. For example: alloc_slice foo( CopyFoo() );

Field Documentation

◆ buf

const void* FL_NULLABLE FLSliceResult::buf

◆ size

size_t FLSliceResult::size

The documentation for this struct was generated from the following file: