map<U> method

NEResult<U> map<U>(
  1. U mapper()
)

Implementation

NEResult<U> map<U>(U Function() mapper) => isSuccess()
    ? NEResult<U>(
        code: code,
        msg: msg,
        data: mapper(),
      )
    : NEResult<U>(code: code, msg: msg, requestId: requestId, cost: cost);