Table of Contents

Class WaitForOptions

Namespace
PuppeteerSharp
Assembly
PuppeteerSharp.dll

Timeout options.

public class WaitForOptions
Inheritance
WaitForOptions
Derived

Constructors

WaitForOptions()

Initializes a new instance of the WaitForOptions class.

public WaitForOptions()

WaitForOptions(int)

Initializes a new instance of the WaitForOptions class.

public WaitForOptions(int timeout)

Parameters

timeout int

Maximum time to wait for in milliseconds. Defaults to 30000 (30 seconds). Pass 0 to disable timeout.

Properties

CancellationToken

A CancellationToken to abort the wait operation.

public CancellationToken CancellationToken { get; set; }

Property Value

CancellationToken

Remarks

This is the .NET equivalent of the upstream AbortController/AbortSignal pattern. When the token is cancelled, the wait operation will throw a OperationCanceledException.

Timeout

Maximum time to wait for in milliseconds. Defaults to 30000 (30 seconds). Pass 0 to disable timeout. The default value can be changed by setting the DefaultTimeout property.

public int? Timeout { get; set; }

Property Value

int?