MCPcopy Index your code
hub / github.com/nodejs/node / constructor

Method constructor

lib/internal/http2/core.js:3448–3465  ·  view source on GitHub ↗
(options, requestListener)

Source from the content-addressed store, hash-verified

3446
3447class Http2SecureServer extends TLSServer {
3448 constructor(options, requestListener) {
3449 options = initializeTLSOptions(options);
3450 super(options, connectionListener);
3451 this[kOptions] = options;
3452 this[kSessions] = new SafeSet();
3453 this.timeout = 0;
3454 this.on('newListener', setupCompat);
3455 if (options.allowHTTP1 === true) {
3456 storeHTTPOptions.call(this, { ...options, ...options.http1Options });
3457 this.shouldUpgradeCallback = function() {
3458 return this.listenerCount('upgrade') > 0;
3459 };
3460 this.on('listening', setupConnectionsTracking);
3461 }
3462 if (typeof requestListener === 'function')
3463 this.on('request', requestListener);
3464 this.on('tlsClientError', onErrorSecureServerSession);
3465 }
3466
3467 setTimeout(msecs, callback) {
3468 this.timeout = msecs;

Callers

nothing calls this directly

Calls 4

initializeTLSOptionsFunction · 0.85
listenerCountMethod · 0.80
onMethod · 0.45
callMethod · 0.45

Tested by

no test coverage detected