ot::Heap::Data::SetFrom() method
Sets the `Heap::Data` from the content of a given buffer.
Arguments
aBuffer
The buffer to copy bytes from.
aLength
The buffer length (number of bytes).
Return value
kErrorNone Successfully set the `Heap::Data`. kErrorNoBufs Failed to allocate buffer.