withExternalBuffer
Factory method that constructs and initializes an IONetworkData object with an external data buffer.
Declaration
static IONetworkData * withExternalBuffer(
const char *name,
UInt32 bufferSize,
void *externalBuffer,
UInt32 accessTypes = (
kIONetworkDataAccessTypeRead | kIONetworkDataAccessTypeSerialize),
void *target = 0,
Action action = 0,
void *param = 0);Parameters
- name:
A name to assign to this object.
- bufferSize:
The size of the external data buffer.
- externalBuffer:
Pointer to the external data buffer.
- accessTypes:
The initial supported access types.
- target:
The notification target.
- action:
The notification action.
- param:
A parameter to pass to the notification action.
Return Value
Returns an IONetworkData object on success, or 0 otherwise.