类:https.Agent


¥Class: https.Agent

HTTPS 的 Agent 对象,类似于 http.Agent。有关详细信息,请参阅 https.request()

¥An Agent object for HTTPS similar to http.Agent. See https.request() for more information.

http.Agent 类似,可以重写 createConnection(options[, callback]) 方法来自定义 TLS 连接的建立方式。

¥Like http.Agent, the createConnection(options[, callback]) method can be overridden to customize how TLS connections are established.

有关重写此方法的详细信息,包括使用回调函数异步创建套接字,请参阅 agent.createConnection()

¥See agent.createConnection() for details on overriding this method, including asynchronous socket creation with a callback.