(callback)
| 1637 | // set but the goaway will not be sent until after the connect event |
| 1638 | // is emitted. |
| 1639 | close(callback) { |
| 1640 | if (this.closed || this.destroyed) |
| 1641 | return; |
| 1642 | debugSessionObj(this, 'marking session closed'); |
| 1643 | this[kState].flags |= SESSION_FLAGS_CLOSED; |
| 1644 | if (typeof callback === 'function') |
| 1645 | this.once('close', callback); |
| 1646 | this.goaway(); |
| 1647 | const handle = this[kHandle]; |
| 1648 | if (handle) { |
| 1649 | handle.setGracefulClose(); |
| 1650 | } |
| 1651 | this[kMaybeDestroy](); |
| 1652 | } |
| 1653 | |
| 1654 | [EventEmitter.captureRejectionSymbol](err, event, ...args) { |
| 1655 | switch (event) { |
nothing calls this directly
no test coverage detected