otSrpClientService Struct Reference
This structure represents an SRP client service.
#include <
include/openthread/srp_client.h
>
Public Attributes |
|
const char * | mName |
The service labels (e.g., "_mt._udp", not the full domain name).
|
|
const char * | mInstanceName |
The service instance name label (not the full name).
|
|
const char *const * | mSubTypeLabels |
Array of sub-type labels (must end with
NULL
or can be
NULL
).
|
|
const otDnsTxtEntry * | mTxtEntries |
Array of TXT entries (
mNumTxtEntries
gives num of entries).
|
|
uint16_t | mPort |
The service port number.
|
|
uint16_t | mPriority |
The service priority.
|
|
uint16_t | mWeight |
The service weight.
|
|
uint8_t | mNumTxtEntries |
Number of entries in the
mTxtEntries
array.
|
|
otSrpClientItemState | mState |
Service state (managed by OT core).
|
|
uint32_t | mData |
Internal data (used by OT core).
|
|
struct otSrpClientService * | mNext |
Pointer to next entry in a linked-list (managed by OT core).
|
|
uint32_t | mLease |
Desired lease interval in sec - zero to use default.
|
|
uint32_t | mKeyLease |
Desired key lease interval in sec - zero to use default.
|
This structure represents an SRP client service.
The values in this structure, including the string buffers for the names and the TXT record entries, MUST persist and stay constant after an instance of this structure is passed to OpenThread from
otSrpClientAddService()
or
otSrpClientRemoveService()
.
The
mState
,
mData
,
mNext
fields are used/managed by OT core only. Their value is ignored when an instance of
otSrpClientService
is passed in
otSrpClientAddService()
or
otSrpClientRemoveService()
or other functions. The caller does not need to set these fields.
The
mLease
and
mKeyLease
fields specify the desired lease and key lease intervals for this service. Zero value indicates that the interval is unspecified and then the default lease or key lease intervals from
otSrpClientGetLeaseInterval()
and
otSrpClientGetKeyLeaseInterval()
are used for this service. If the key lease interval (whether set explicitly or determined from the default) is shorter than the lease interval for a service, SRP client will re-use the lease interval value for key lease interval as well. For example, if in service
mLease
is explicitly set to 2 days and
mKeyLease
is set to zero and default key lease is set to 1 day, then when registering this service, the requested key lease for this service is also set to 2 days.
The documentation for this struct was generated from the following file:
-
include/openthread/
srp_client.h