MCPcopy Create free account
hub / github.com/angular/angular / _ZoneDelegate

Class _ZoneDelegate

packages/zone.js/lib/zone-impl.ts:1119–1383  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1117 };
1118
1119 class _ZoneDelegate implements ZoneDelegate {
1120 public get zone(): Zone {
1121 return this._zone;
1122 }
1123 private _zone: ZoneImpl;
1124
1125 private _taskCounts: {[key in TaskType]: number} = {
1126 'microTask': 0,
1127 'macroTask': 0,
1128 'eventTask': 0,
1129 };
1130
1131 private _forkDlgt: _ZoneDelegate | null;
1132 private _forkZS: ZoneSpec | null;
1133 private _forkCurrZone: Zone | null;
1134
1135 private _interceptDlgt: _ZoneDelegate | null;
1136 private _interceptZS: ZoneSpec | null;
1137 private _interceptCurrZone: Zone | null;
1138
1139 private _invokeDlgt: _ZoneDelegate | null;
1140 private _invokeZS: ZoneSpec | null;
1141 private _invokeCurrZone: ZoneImpl | null;
1142
1143 private _handleErrorDlgt: _ZoneDelegate | null;
1144 private _handleErrorZS: ZoneSpec | null;
1145 private _handleErrorCurrZone: ZoneImpl | null;
1146
1147 private _scheduleTaskDlgt: _ZoneDelegate | null;
1148 private _scheduleTaskZS: ZoneSpec | null;
1149 private _scheduleTaskCurrZone: ZoneImpl | null;
1150
1151 private _invokeTaskDlgt: _ZoneDelegate | null;
1152 private _invokeTaskZS: ZoneSpec | null;
1153 private _invokeTaskCurrZone: ZoneImpl | null;
1154
1155 private _cancelTaskDlgt: _ZoneDelegate | null;
1156 private _cancelTaskZS: ZoneSpec | null;
1157 private _cancelTaskCurrZone: ZoneImpl | null;
1158
1159 private _hasTaskDlgt: _ZoneDelegate | null;
1160 private _hasTaskDlgtOwner: _ZoneDelegate | null;
1161 private _hasTaskZS: ZoneSpec | null;
1162 private _hasTaskCurrZone: ZoneImpl | null;
1163
1164 constructor(zone: Zone, parentDelegate: _ZoneDelegate | null, zoneSpec: ZoneSpec | null) {
1165 this._zone = zone as ZoneImpl;
1166
1167 this._forkZS = zoneSpec && (zoneSpec && zoneSpec.onFork ? zoneSpec : parentDelegate!._forkZS);
1168 this._forkDlgt = zoneSpec && (zoneSpec.onFork ? parentDelegate : parentDelegate!._forkDlgt);
1169 this._forkCurrZone =
1170 zoneSpec && (zoneSpec.onFork ? this._zone : parentDelegate!._forkCurrZone);
1171
1172 this._interceptZS =
1173 zoneSpec && (zoneSpec.onIntercept ? zoneSpec : parentDelegate!._interceptZS);
1174 this._interceptDlgt =
1175 zoneSpec && (zoneSpec.onIntercept ? parentDelegate : parentDelegate!._interceptDlgt);
1176 this._interceptCurrZone =

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected