Class: Selenium::DevTools::V128::IndexedDB
- Inherits:
-
Object
- Object
- Selenium::DevTools::V128::IndexedDB
- Defined in:
- lib/selenium/devtools/v128/indexed_db.rb
Instance Method Summary collapse
- #clear_object_store(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:, object_store_name:) ⇒ Object
- #delete_database(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:) ⇒ Object
- #delete_object_store_entries(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:, object_store_name:, key_range:) ⇒ Object
- #disable ⇒ Object
- #enable ⇒ Object
- #get_metadata(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:, object_store_name:) ⇒ Object
-
#initialize(devtools) ⇒ IndexedDB
constructor
A new instance of IndexedDB.
- #on(event, &block) ⇒ Object
- #request_data(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:, object_store_name:, index_name:, skip_count:, page_size:, key_range: nil) ⇒ Object
- #request_database(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:) ⇒ Object
- #request_database_names(security_origin: nil, storage_key: nil, storage_bucket: nil) ⇒ Object
Constructor Details
#initialize(devtools) ⇒ IndexedDB
Returns a new instance of IndexedDB.
26 27 28 |
# File 'lib/selenium/devtools/v128/indexed_db.rb', line 26 def initialize(devtools) @devtools = devtools end |
Instance Method Details
#clear_object_store(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:, object_store_name:) ⇒ Object
35 36 37 38 39 40 41 42 |
# File 'lib/selenium/devtools/v128/indexed_db.rb', line 35 def clear_object_store(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:, object_store_name:) @devtools.send_cmd('IndexedDB.clearObjectStore', securityOrigin: security_origin, storageKey: storage_key, storageBucket: storage_bucket, databaseName: database_name, objectStoreName: object_store_name) end |
#delete_database(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:) ⇒ Object
44 45 46 47 48 49 50 |
# File 'lib/selenium/devtools/v128/indexed_db.rb', line 44 def delete_database(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:) @devtools.send_cmd('IndexedDB.deleteDatabase', securityOrigin: security_origin, storageKey: storage_key, storageBucket: storage_bucket, databaseName: database_name) end |
#delete_object_store_entries(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:, object_store_name:, key_range:) ⇒ Object
52 53 54 55 56 57 58 59 60 |
# File 'lib/selenium/devtools/v128/indexed_db.rb', line 52 def delete_object_store_entries(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:, object_store_name:, key_range:) @devtools.send_cmd('IndexedDB.deleteObjectStoreEntries', securityOrigin: security_origin, storageKey: storage_key, storageBucket: storage_bucket, databaseName: database_name, objectStoreName: object_store_name, keyRange: key_range) end |
#disable ⇒ Object
62 63 64 |
# File 'lib/selenium/devtools/v128/indexed_db.rb', line 62 def disable @devtools.send_cmd('IndexedDB.disable') end |
#enable ⇒ Object
66 67 68 |
# File 'lib/selenium/devtools/v128/indexed_db.rb', line 66 def enable @devtools.send_cmd('IndexedDB.enable') end |
#get_metadata(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:, object_store_name:) ⇒ Object
83 84 85 86 87 88 89 90 |
# File 'lib/selenium/devtools/v128/indexed_db.rb', line 83 def (security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:, object_store_name:) @devtools.send_cmd('IndexedDB.getMetadata', securityOrigin: security_origin, storageKey: storage_key, storageBucket: storage_bucket, databaseName: database_name, objectStoreName: object_store_name) end |
#on(event, &block) ⇒ Object
30 31 32 33 |
# File 'lib/selenium/devtools/v128/indexed_db.rb', line 30 def on(event, &block) event = EVENTS[event] if event.is_a?(Symbol) @devtools.callbacks["IndexedDB.#{event}"] << block end |
#request_data(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:, object_store_name:, index_name:, skip_count:, page_size:, key_range: nil) ⇒ Object
70 71 72 73 74 75 76 77 78 79 80 81 |
# File 'lib/selenium/devtools/v128/indexed_db.rb', line 70 def request_data(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:, object_store_name:, index_name:, skip_count:, page_size:, key_range: nil) @devtools.send_cmd('IndexedDB.requestData', securityOrigin: security_origin, storageKey: storage_key, storageBucket: storage_bucket, databaseName: database_name, objectStoreName: object_store_name, indexName: index_name, skipCount: skip_count, pageSize: page_size, keyRange: key_range) end |
#request_database(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:) ⇒ Object
92 93 94 95 96 97 98 |
# File 'lib/selenium/devtools/v128/indexed_db.rb', line 92 def request_database(security_origin: nil, storage_key: nil, storage_bucket: nil, database_name:) @devtools.send_cmd('IndexedDB.requestDatabase', securityOrigin: security_origin, storageKey: storage_key, storageBucket: storage_bucket, databaseName: database_name) end |
#request_database_names(security_origin: nil, storage_key: nil, storage_bucket: nil) ⇒ Object
100 101 102 103 104 105 |
# File 'lib/selenium/devtools/v128/indexed_db.rb', line 100 def request_database_names(security_origin: nil, storage_key: nil, storage_bucket: nil) @devtools.send_cmd('IndexedDB.requestDatabaseNames', securityOrigin: security_origin, storageKey: storage_key, storageBucket: storage_bucket) end |