Table of Contents

Interface ITethering

Namespace
Selenium.WebDriver.BiDi.Cdp.Tethering
Assembly
Selenium.WebDriver.BiDi.Cdp.dll

The Tethering domain defines methods and events for browser port binding.

[Experimental("BIDICDP001")]
public interface ITethering

Properties

Accepted

Informs that port was successfully bound and got a specified connection id.

IEventSource<AcceptedEventArgs> Accepted { get; }

Property Value

IEventSource<AcceptedEventArgs>

Remarks

Event args (AcceptedEventArgs):

  • Port - Port number that was successfully bound.
  • ConnectionId - Connection id to be used.

Methods

BindAsync(long, string?, CancellationToken)

Request browser port binding.

Task<BindResult> BindAsync(long port, string? session = null, CancellationToken cancellationToken = default)

Parameters

port long

Port number to bind.

session string

Optional CDP session override.

cancellationToken CancellationToken

A token to cancel the asynchronous operation.

Returns

Task<BindResult>

A task representing the asynchronous operation, containing a BindResult.

UnbindAsync(long, string?, CancellationToken)

Request browser port unbinding.

Task<UnbindResult> UnbindAsync(long port, string? session = null, CancellationToken cancellationToken = default)

Parameters

port long

Port number to unbind.

session string

Optional CDP session override.

cancellationToken CancellationToken

A token to cancel the asynchronous operation.

Returns

Task<UnbindResult>

A task representing the asynchronous operation, containing a UnbindResult.