Builder

class Builder(val url: String)

A builder for CreateTargetRequest, which allows setting the optional parameters of the TargetDomain.createTarget command via a lambda.

Constructors

Link copied to clipboard
constructor(url: String)

Properties

Link copied to clipboard

Whether to create the target in background or foreground (false by default, not supported by headless shell).

Link copied to clipboard

The browser context to create the page in.

Link copied to clipboard

Whether BeginFrames for this target will be controlled via DevTools (headless shell only, not supported on MacOS yet, false by default).

Link copied to clipboard

If specified, the option is used to determine if the new target should be focused or not. By default, the focus behavior depends on the value of the background field. For example, background=false and focus=false will result in the target tab being opened but the browser window remain unchanged (if it was in the background, it will remain in the background) and background=false with focus=undefined will result in the window being focused. Using background: true and focus: true is not supported and will result in an error.

Link copied to clipboard

Whether to create the target of type "tab".

Link copied to clipboard
var height: Int?

Frame height in DIP (requires newWindow to be true or headless shell).

Link copied to clipboard

Whether to create a hidden target. The hidden target is observable via protocol, but not present in the tab UI strip. Cannot be created with forTab: true, newWindow: true or background: false. The life-time of the tab is limited to the life-time of the session.

Link copied to clipboard
var left: Int?

Frame left origin in DIP (requires newWindow to be true or headless shell).

Link copied to clipboard

Whether to create a new Window or Tab (false by default, not supported by headless shell).

Link copied to clipboard
var top: Int?

Frame top origin in DIP (requires newWindow to be true or headless shell).

Link copied to clipboard
val url: String

The initial URL the page will be navigated to. An empty string indicates about:blank.

Link copied to clipboard
var width: Int?

Frame width in DIP (requires newWindow to be true or headless shell).

Link copied to clipboard

Frame window state (requires newWindow to be true or headless shell). Default is normal.

Functions

Link copied to clipboard