openthread_sys

Type Alias otDnsServiceCallback

Source
pub type otDnsServiceCallback = Option<unsafe extern "C" fn(aError: otError, aResponse: *const otDnsServiceResponse, aContext: *mut c_void)>;
Expand description

Pointer is called when a DNS response is received for a service instance resolution query.

Within this callback the user can use otDnsServiceResponseGet{Item}() functions along with the @p aResponse pointer to get more info about the response.

The @p aResponse pointer can only be used within this callback and after returning from this function it will not stay valid, so the user MUST NOT retain the @p aResponse pointer for later use.

@param[in] aError The result of the DNS transaction. @param[in] aResponse A pointer to the response (it is always non-NULL). @param[in] aContext A pointer to application-specific context.

For the full list of possible values for @p aError, please see otDnsAddressCallback().

Aliased Type§

enum otDnsServiceCallback {
    None,
    Some(unsafe extern "C" fn(_: u32, _: *const otDnsServiceResponse, _: *mut c_void)),
}

Variants§

§1.0.0

None

No value.

§1.0.0

Some(unsafe extern "C" fn(_: u32, _: *const otDnsServiceResponse, _: *mut c_void))

Some value of type T.