[doc] Added a wrapper function

asyncOperationWithResultOrError()