MCPcopy Create free account
hub / github.com/angular/dev-infra / [kDispatch]

Method [kDispatch]

github-actions/browserstack/set-browserstack-env.js:8036–8051  ·  view source on GitHub ↗
(opts, handler)

Source from the content-addressed store, hash-verified

8034 return this[kQueue].length - this[kRunningIdx];
8035 }
8036 get [kConnected]() {
8037 return !!this[kHTTPContext] && !this[kConnecting] && !this[kHTTPContext].destroyed;
8038 }
8039 get [kBusy]() {
8040 var _a;
8041 return Boolean(
8042 ((_a = this[kHTTPContext]) == null ? void 0 : _a.busy(null)) || this[kSize] >= (getPipelining(this) || 1) || this[kPending] > 0
8043 );
8044 }
8045 /* istanbul ignore: only used for test */
8046 [kConnect](cb) {
8047 connect(this);
8048 this.once("connect", cb);
8049 }
8050 [kDispatch](opts, handler) {
8051 const origin = opts.origin || this[kUrl].origin;
8052 const request = new Request(origin, opts, handler);
8053 this[kQueue].push(request);
8054 if (this[kResuming]) {

Callers

nothing calls this directly

Calls 10

resumeFunction · 0.70
__spreadValuesFunction · 0.70
__privateGetFunction · 0.70
__privateMethodFunction · 0.70
pushMethod · 0.45
dispatchMethod · 0.45
getMethod · 0.45
onMethod · 0.45
setMethod · 0.45
onErrorMethod · 0.45

Tested by

no test coverage detected