MCPcopy Create free account
hub / github.com/apache/cloudstack / sQpushBytes

Method sQpushBytes

systemvm/agent/noVNC/core/websock.js:202–215  ·  view source on GitHub ↗
(bytes)

Source from the content-addressed store, hash-verified

200 }
201
202 sQpushBytes(bytes) {
203 for (let offset = 0;offset < bytes.length;) {
204 this._sQensureSpace(1);
205
206 let chunkSize = this._sQbufferSize - this._sQlen;
207 if (chunkSize > bytes.length - offset) {
208 chunkSize = bytes.length - offset;
209 }
210
211 this._sQ.set(bytes.subarray(offset, offset + chunkSize), this._sQlen);
212 this._sQlen += chunkSize;
213 offset += chunkSize;
214 }
215 }
216
217 flush() {
218 if (this._sQlen > 0 && this.readyState === 'open') {

Callers 6

sQpushStringMethod · 0.95
_negotiateStdVNCAuthMethod · 0.80
_negotiateARDAuthMethod · 0.80
clientCutTextFunction · 0.80

Calls 2

_sQensureSpaceMethod · 0.95
setMethod · 0.65

Tested by

no test coverage detected