(delay, type)
| 6055 | this.headersMaxSize = client[kMaxHeadersSize]; |
| 6056 | this.shouldKeepAlive = false; |
| 6057 | this.paused = false; |
| 6058 | this.resume = this.resume.bind(this); |
| 6059 | this.bytesRead = 0; |
| 6060 | this.keepAlive = ""; |
| 6061 | this.contentLength = ""; |
| 6062 | this.connection = ""; |
| 6063 | this.maxResponseSize = client[kMaxResponseSize]; |
| 6064 | } |
| 6065 | setTimeout(delay, type) { |
| 6066 | if (delay !== this.timeoutValue || type & USE_FAST_TIMER ^ this.timeoutType & USE_FAST_TIMER) { |
| 6067 | if (this.timeout) { |
| 6068 | timers.clearTimeout(this.timeout); |
| 6069 | this.timeout = null; |
| 6070 | } |
| 6071 | if (delay) { |
| 6072 | if (type & USE_FAST_TIMER) { |
| 6073 | this.timeout = timers.setFastTimeout(onParserTimeout, delay, new WeakRef(this)); |
| 6074 | } else { |
| 6075 | this.timeout = setTimeout(onParserTimeout, delay, new WeakRef(this)); |
| 6076 | this.timeout.unref(); |
| 6077 | } |
| 6078 | } |
| 6079 | this.timeoutValue = delay; |
| 6080 | } else if (this.timeout) { |
| 6081 | if (this.timeout.refresh) { |
no test coverage detected