Function TRITONSERVER_MessageSerializeToJson

Function Documentation

TRITONSERVER_Error *TRITONSERVER_MessageSerializeToJson(TRITONSERVER_Message *message, const char **base, size_t *byte_size)

Get the base and size of the buffer containing the serialized message in JSON format.

The buffer is owned by the TRITONSERVER_Message object and should not be modified or freed by the caller. The lifetime of the buffer extends only as long as ‘message’ and must not be accessed once ‘message’ is deleted.

Return

a TRITONSERVER_Error indicating success or failure.

Parameters
  • message: The message object.

  • base: Returns the base of the serialized message.

  • byte_size: Returns the size, in bytes, of the serialized message.