我怎样才能有效地(没有副本,只有包装器)将具有非零的Uint8Array
( ) 转换
为 a以便可以使用 Angular方法以二进制方式发送它?payload
byteOffset
ArrayBuffer
HttpClient.post
public post(requestUrl: string, payload: Uint8Array): Promise<Uint8Array> {
return this.httpClient.post(url, payload, { responseType: 'arraybuffer', headers: new HttpHeaders({ 'Content-Type': "application/octet-stream" }) })
}