Function pact_ffi::models::message::pactffi_message_set_contents
source · #[no_mangle]
pub extern "C" fn pactffi_message_set_contents(
message: *mut Message,
contents: *const c_char,
content_type: *const c_char
)
Expand description
Sets the contents of the message.
§Safety
The message contents and content type must either be NULL pointers, or point to valid UTF-8 encoded NULL-terminated strings. Otherwise behaviour is undefined.
§Error Handling
If the contents is a NULL pointer, it will set the message contents as null. If the content type is a null pointer, or can’t be parsed, it will set the content type as unknown.