2024-03-25 13:03:57 +00:00
|
|
|
---
|
|
|
|
sidebar_label: Connection
|
|
|
|
---
|
|
|
|
|
|
|
|
# Connection class
|
|
|
|
|
|
|
|
#### Signature:
|
|
|
|
|
|
|
|
```typescript
|
|
|
|
export declare class Connection extends EventEmitter<CDPSessionEvents>
|
|
|
|
```
|
|
|
|
|
|
|
|
**Extends:** [EventEmitter](./puppeteer.eventemitter.md)<[CDPSessionEvents](./puppeteer.cdpsessionevents.md)>
|
|
|
|
|
|
|
|
## Constructors
|
|
|
|
|
|
|
|
<table><thead><tr><th>
|
|
|
|
|
|
|
|
Constructor
|
|
|
|
|
|
|
|
</th><th>
|
|
|
|
|
|
|
|
Modifiers
|
|
|
|
|
|
|
|
</th><th>
|
|
|
|
|
|
|
|
Description
|
|
|
|
|
|
|
|
</th></tr></thead>
|
|
|
|
<tbody><tr><td>
|
|
|
|
|
2024-04-11 16:51:07 +00:00
|
|
|
<span id="_constructor_">[(constructor)(url, transport, delay, timeout)](./puppeteer.connection._constructor_.md)</span>
|
2024-03-25 13:03:57 +00:00
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
Constructs a new instance of the `Connection` class
|
|
|
|
|
|
|
|
</td></tr>
|
|
|
|
</tbody></table>
|
|
|
|
|
|
|
|
## Properties
|
|
|
|
|
|
|
|
<table><thead><tr><th>
|
|
|
|
|
|
|
|
Property
|
|
|
|
|
|
|
|
</th><th>
|
|
|
|
|
|
|
|
Modifiers
|
|
|
|
|
|
|
|
</th><th>
|
|
|
|
|
|
|
|
Type
|
|
|
|
|
|
|
|
</th><th>
|
|
|
|
|
|
|
|
Description
|
|
|
|
|
|
|
|
</th></tr></thead>
|
|
|
|
<tbody><tr><td>
|
|
|
|
|
2024-04-11 16:51:07 +00:00
|
|
|
<span id="timeout">timeout</span>
|
2024-03-25 13:03:57 +00:00
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
`readonly`
|
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
number
|
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td></tr>
|
|
|
|
</tbody></table>
|
|
|
|
|
|
|
|
## Methods
|
|
|
|
|
|
|
|
<table><thead><tr><th>
|
|
|
|
|
|
|
|
Method
|
|
|
|
|
|
|
|
</th><th>
|
|
|
|
|
|
|
|
Modifiers
|
|
|
|
|
|
|
|
</th><th>
|
|
|
|
|
|
|
|
Description
|
|
|
|
|
|
|
|
</th></tr></thead>
|
|
|
|
<tbody><tr><td>
|
|
|
|
|
2024-04-11 16:51:07 +00:00
|
|
|
<span id="createsession">[createSession(targetInfo)](./puppeteer.connection.createsession.md)</span>
|
2024-03-25 13:03:57 +00:00
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td></tr>
|
|
|
|
<tr><td>
|
|
|
|
|
2024-04-11 16:51:07 +00:00
|
|
|
<span id="dispose">[dispose()](./puppeteer.connection.dispose.md)</span>
|
2024-03-25 13:03:57 +00:00
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td></tr>
|
|
|
|
<tr><td>
|
|
|
|
|
2024-04-11 16:51:07 +00:00
|
|
|
<span id="fromsession">[fromSession(session)](./puppeteer.connection.fromsession.md)</span>
|
2024-03-25 13:03:57 +00:00
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
`static`
|
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td></tr>
|
|
|
|
<tr><td>
|
|
|
|
|
2024-04-11 16:51:07 +00:00
|
|
|
<span id="send">[send(method, params, options)](./puppeteer.connection.send.md)</span>
|
2024-03-25 13:03:57 +00:00
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td></tr>
|
|
|
|
<tr><td>
|
|
|
|
|
2024-04-11 16:51:07 +00:00
|
|
|
<span id="session">[session(sessionId)](./puppeteer.connection.session.md)</span>
|
2024-03-25 13:03:57 +00:00
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td></tr>
|
|
|
|
<tr><td>
|
|
|
|
|
2024-04-11 16:51:07 +00:00
|
|
|
<span id="url">[url()](./puppeteer.connection.url.md)</span>
|
2024-03-25 13:03:57 +00:00
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td><td>
|
|
|
|
|
|
|
|
</td></tr>
|
|
|
|
</tbody></table>
|