Class: Selenium::WebDriver::BiDi::Protocol::Storage Private

Inherits:
Domain
  • Object
show all
Defined in:
lib/selenium/webdriver/bidi/protocol/storage.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Defined Under Namespace

Classes: PartitionDescriptor

Constant Summary collapse

PartitionKey =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Serialization::Record.define(
  user_context: {wire_key: 'userContext', required: false, primitive: 'string'},
  source_origin: {wire_key: 'sourceOrigin', required: false, primitive: 'string'},
  extensible: true
)
CookieFilter =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Serialization::Record.define(
  name: {wire_key: 'name', required: false, primitive: 'string'},
  value: {wire_key: 'value', required: false, ref: 'Network::BytesValue'},
  domain: {wire_key: 'domain', required: false, primitive: 'string'},
  path: {wire_key: 'path', required: false, primitive: 'string'},
  size: {wire_key: 'size', required: false, primitive: 'integer'},
  http_only: {wire_key: 'httpOnly', required: false, primitive: 'boolean'},
  secure: {wire_key: 'secure', required: false, primitive: 'boolean'},
  same_site: {wire_key: 'sameSite', required: false, enum: 'Network::SAME_SITE'},
  expiry: {wire_key: 'expiry', required: false, primitive: 'integer'},
  extensible: true
)
BrowsingContextPartitionDescriptor =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Serialization::Record.define(
  type: {fixed: 'context'},
  context: {wire_key: 'context', primitive: 'string'}
)
StorageKeyPartitionDescriptor =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Serialization::Record.define(
  type: {fixed: 'storageKey'},
  user_context: {wire_key: 'userContext', required: false, primitive: 'string'},
  source_origin: {wire_key: 'sourceOrigin', required: false, primitive: 'string'},
  extensible: true
)
GetCookiesParameters =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Serialization::Record.define(
  filter: {wire_key: 'filter', required: false, ref: 'Storage::CookieFilter'},
  partition: {wire_key: 'partition', required: false, ref: 'Storage::PartitionDescriptor'}
)
GetCookiesResult =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Serialization::Record.define(
  cookies: {wire_key: 'cookies', ref: 'Network::Cookie', list: true},
  partition_key: {wire_key: 'partitionKey', ref: 'Storage::PartitionKey'}
)
PartialCookie =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Serialization::Record.define(
  name: {wire_key: 'name', primitive: 'string'},
  value: {wire_key: 'value', ref: 'Network::BytesValue'},
  domain: {wire_key: 'domain', primitive: 'string'},
  path: {wire_key: 'path', required: false, primitive: 'string'},
  http_only: {wire_key: 'httpOnly', required: false, primitive: 'boolean'},
  secure: {wire_key: 'secure', required: false, primitive: 'boolean'},
  same_site: {wire_key: 'sameSite', required: false, enum: 'Network::SAME_SITE'},
  expiry: {wire_key: 'expiry', required: false, primitive: 'integer'},
  extensible: true
)
SetCookieParameters =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Serialization::Record.define(
  cookie: {wire_key: 'cookie', ref: 'Storage::PartialCookie'},
  partition: {wire_key: 'partition', required: false, ref: 'Storage::PartitionDescriptor'}
)
SetCookieResult =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Serialization::Record.define(
  partition_key: {wire_key: 'partitionKey', ref: 'Storage::PartitionKey'}
)
DeleteCookiesParameters =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Serialization::Record.define(
  filter: {wire_key: 'filter', required: false, ref: 'Storage::CookieFilter'},
  partition: {wire_key: 'partition', required: false, ref: 'Storage::PartitionDescriptor'}
)
DeleteCookiesResult =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

Serialization::Record.define(
  partition_key: {wire_key: 'partitionKey', ref: 'Storage::PartitionKey'}
)

Instance Method Summary collapse

Methods inherited from Domain

#initialize

Constructor Details

This class inherits a constructor from Selenium::WebDriver::BiDi::Protocol::Domain

Instance Method Details

#browsing_context_partition_descriptorObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



151
# File 'lib/selenium/webdriver/bidi/protocol/storage.rb', line 151

def browsing_context_partition_descriptor(**) = BrowsingContextPartitionDescriptor.new(**)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



150
# File 'lib/selenium/webdriver/bidi/protocol/storage.rb', line 150

def cookie_filter(**) = CookieFilter.new(**)

#delete_cookies(filter: Serialization::UNSET, partition: Serialization::UNSET) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



159
160
161
162
# File 'lib/selenium/webdriver/bidi/protocol/storage.rb', line 159

def delete_cookies(filter: Serialization::UNSET, partition: Serialization::UNSET)
  params = DeleteCookiesParameters.new(filter: filter, partition: partition)
  execute(cmd: 'storage.deleteCookies', params: params, result: Storage::DeleteCookiesResult)
end

#get_cookies(filter: Serialization::UNSET, partition: Serialization::UNSET) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



167
168
169
170
# File 'lib/selenium/webdriver/bidi/protocol/storage.rb', line 167

def get_cookies(filter: Serialization::UNSET, partition: Serialization::UNSET)
  params = GetCookiesParameters.new(filter: filter, partition: partition)
  execute(cmd: 'storage.getCookies', params: params, result: Storage::GetCookiesResult)
end

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



154
# File 'lib/selenium/webdriver/bidi/protocol/storage.rb', line 154

def partial_cookie(**) = PartialCookie.new(**)

#partition_descriptorObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



153
# File 'lib/selenium/webdriver/bidi/protocol/storage.rb', line 153

def partition_descriptor = PartitionDescriptor

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



175
176
177
178
# File 'lib/selenium/webdriver/bidi/protocol/storage.rb', line 175

def set_cookie(cookie:, partition: Serialization::UNSET)
  params = SetCookieParameters.new(cookie: cookie, partition: partition)
  execute(cmd: 'storage.setCookie', params: params, result: Storage::SetCookieResult)
end

#storage_key_partition_descriptorObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



152
# File 'lib/selenium/webdriver/bidi/protocol/storage.rb', line 152

def storage_key_partition_descriptor(**) = StorageKeyPartitionDescriptor.new(**)