Function tari_wallet_ffi::public_key_to_emoji_id[][src]

#[no_mangle]pub unsafe extern "C" fn public_key_to_emoji_id(
    pk: *mut TariPublicKey,
    error_out: *mut c_int
) -> *mut c_char

Creates a char array from a TariPublicKey in emoji format

Arguments

pk - The pointer to a TariPublicKey error_out - Pointer to an int which will be modified to an error code should one occur, may not be null. Functions as an out parameter.

Returns

*mut c_char - Returns a pointer to a char array. Note that it returns empty if emoji is null or if there was an error creating the emoji string from TariPublicKey

Safety

The string_destroy method must be called when finished with a string from rust to prevent a memory leak