Help us shape the future of Go! Take the 2026 Go Developer Survey

deviceaccess

package
v0.159.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 31, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

Package deviceaccess provides the Chrome DevTools Protocol commands, types, and events for the DeviceAccess domain.

Generated by the pdlgen command.

Index

Constants

View Source
const (
	CommandEnable       = "DeviceAccess.enable"
	CommandDisable      = "DeviceAccess.disable"
	CommandSelectPrompt = "DeviceAccess.selectPrompt"
	CommandCancelPrompt = "DeviceAccess.cancelPrompt"
)

Command names.

Variables

CancelPrompt cancel a prompt in response to a DeviceAccess.deviceRequestPrompted event.

See: https://chromedevtools.github.io/devtools-protocol/tot/DeviceAccess#method-cancelPrompt

View Source
var DeviceRequestPrompted = cdp.Event[EventDeviceRequestPrompted]{Method: "DeviceAccess.deviceRequestPrompted"}

DeviceRequestPrompted a device request opened a user prompt to select a device. Respond with the selectPrompt or cancelPrompt command.

See: https://chromedevtools.github.io/devtools-protocol/tot/DeviceAccess#event-deviceRequestPrompted

View Source
var Disable = cdp.Command[cdp.Empty, cdp.Empty]{Method: CommandDisable}

Disable disable events in this domain.

See: https://chromedevtools.github.io/devtools-protocol/tot/DeviceAccess#method-disable

Enable enable events in this domain.

See: https://chromedevtools.github.io/devtools-protocol/tot/DeviceAccess#method-enable

SelectPrompt select a device in response to a DeviceAccess.deviceRequestPrompted event.

See: https://chromedevtools.github.io/devtools-protocol/tot/DeviceAccess#method-selectPrompt

Functions

This section is empty.

Types

type CancelPromptParams

type CancelPromptParams struct {
	ID RequestID `json:"id"`
}

CancelPromptParams are the parameters of the command DeviceAccess.cancelPrompt.

type DeviceID

type DeviceID string

DeviceID a device id.

See: https://chromedevtools.github.io/devtools-protocol/tot/DeviceAccess#type-DeviceId

func (DeviceID) String

func (t DeviceID) String() string

String returns the DeviceID as string value.

type EventDeviceRequestPrompted

type EventDeviceRequestPrompted struct {
	ID      RequestID       `json:"id"`
	Devices []*PromptDevice `json:"devices"`
}

EventDeviceRequestPrompted a device request opened a user prompt to select a device. Respond with the selectPrompt or cancelPrompt command.

See: https://chromedevtools.github.io/devtools-protocol/tot/DeviceAccess#event-deviceRequestPrompted

type PromptDevice

type PromptDevice struct {
	ID   DeviceID `json:"id"`
	Name string   `json:"name"` // Display name as it appears in a device request user prompt.
}

PromptDevice device information displayed in a user prompt to select a device.

See: https://chromedevtools.github.io/devtools-protocol/tot/DeviceAccess#type-PromptDevice

type RequestID

type RequestID string

RequestID device request id.

See: https://chromedevtools.github.io/devtools-protocol/tot/DeviceAccess#type-RequestId

func (RequestID) String

func (t RequestID) String() string

String returns the RequestID as string value.

type SelectPromptParams

type SelectPromptParams struct {
	ID       RequestID `json:"id"`
	DeviceID DeviceID  `json:"deviceId"`
}

SelectPromptParams are the parameters of the command DeviceAccess.selectPrompt.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL