swu_update_to_string()

Create a string representation of an Update

Synopsis:

#include <swu/Update.h>
 
swu_result_t swu_update_to_string(
                            swu_update_t update, 
                            char *output, 
                            size_t len )

Arguments:

update
Handle of the Update.
output
Buffer to store the outputted string.
len
Length of the buffer.

Library:

libswu-core

Use the -l swu-core option with qcc to link against the SWU library. This library is usually included automatically.

Description:

Create a string representation of the Update specified in update. This function writes as much information from the Update as possible into a null-terminated string, which it stores in the buffer pointed to by output. The number of bytes written to the buffer is at most len. The data is written in fields, with each field on its own line and in the following format:

ID: UPDATE_ID 
Name: This Software Update 
Version: 00.00.01 

Returns:

One of the following swu_result_t values:

SWU_RESULT_SUCCESS
The operation succeeded.
SWU_RESULT_INVALID_ARGUMENT
One of the arguments is invalid.
SWU_RESULT_ERROR
Another error occurred.