Table of Contents

Class KeyDownAction

Namespace
WebDriverBiDi.Input
Assembly
WebDriverBiDi.dll

An action to send a key down on a keyboard device.

public class KeyDownAction : IKeySourceAction
Inheritance
KeyDownAction
Implements
Inherited Members

Constructors

KeyDownAction(string)

Initializes a new instance of the KeyDownAction class.

public KeyDownAction(string value)

Parameters

value string

The text of keys to send for key down.

Remarks

The specification requires the value to be a string containing a single grapheme cluster. Unlike values whose specification constraints the remote end enforces, a null or empty string is rejected here: it cannot describe a key under any revision of the specification, and accepting it would only defer a certain failure to the remote end.

Exceptions

ArgumentException

Thrown if the value is null or empty.

Properties

Type

Gets the type of the action.

[JsonPropertyName("type")]
public string Type { get; }

Property Value

string

Value

Gets or sets the value of the key down action.

[JsonPropertyName("value")]
public string Value { get; set; }

Property Value

string

Exceptions

ArgumentException

Thrown when attempting to set this property to null or the empty string.