我要评分
获取效率
正确性
完整性
易理解

Serialize

API Definition

int Serialize(uint8_t *&dataPtr, size_t &dataLength) const;

Function

Stores the searcher content into the uint8 array with a length of dataLength bytes and a start address of dataPtr.

Parameters

Parameter

Data Type

Description

Value Range

dataPtr

uint8_t *&

Start address of the array that stores the content of the searcher.

The value can only be a null pointer.

dataLength

size_t &

Length of the array that stores the content of the searcher.

The value can only be 0.

Return Value

Data Type

Description

int

If the parameter value exceeds the value range, -1 is returned. If this API is called after BuildSearcher or Load/Deserialize/LoadGraph is called, -1 is returned. In other cases, 0 is returned.