(inst: any, payload: any, callback)
| 165 | const classComponentUpdater = { |
| 166 | // $FlowFixMe[missing-local-annot] |
| 167 | enqueueSetState(inst: any, payload: any, callback) { |
| 168 | const fiber = getInstance(inst); |
| 169 | const lane = requestUpdateLane(fiber); |
| 170 | |
| 171 | const update = createUpdate(lane); |
| 172 | update.payload = payload; |
| 173 | if (callback !== undefined && callback !== null) { |
| 174 | if (__DEV__) { |
| 175 | warnOnInvalidCallback(callback); |
| 176 | } |
| 177 | update.callback = callback; |
| 178 | } |
| 179 | |
| 180 | const root = enqueueUpdate(fiber, update, lane); |
| 181 | if (root !== null) { |
| 182 | startUpdateTimerByLane(lane, 'this.setState()', fiber); |
| 183 | scheduleUpdateOnFiber(root, fiber, lane); |
| 184 | entangleTransitions(root, fiber, lane); |
| 185 | } |
| 186 | |
| 187 | if (enableSchedulingProfiler) { |
| 188 | markStateUpdateScheduled(fiber, lane); |
| 189 | } |
| 190 | }, |
| 191 | enqueueReplaceState(inst: any, payload: any, callback: null) { |
| 192 | const fiber = getInstance(inst); |
| 193 | const lane = requestUpdateLane(fiber); |
nothing calls this directly
no test coverage detected