Documentation ¶
Overview ¶
Package indexeddb is a database of records holding simple values and hierarchical objects.
Example (Open) ¶
package main import ( "github.com/Programmerino/webapi" "github.com/Programmerino/webapi/dom/domcore" "github.com/Programmerino/webapi/indexeddb" ) func main() { request := webapi.GetWindow().IndexedDB().Open("test", nil) request.AddEventSuccess(func(event *domcore.Event, target *indexeddb.IDBRequest) {}) request.AddEventUpgradeNeeded(func(event *domcore.Event, currentTarget *indexeddb.IDBOpenDBRequest) { db := indexeddb.IDBDatabaseFromJS(request.Result()) db.CreateObjectStore("names", &indexeddb.IDBObjectStoreParameters{ AutoIncrement: true, }) /* javascript version is: var db = event.target.result; var objStore = db.createObjectStore("names", { autoIncrement : true }); */ }) }
Output:
Index ¶
- type IDBCursor
- func (_this *IDBCursor) Advance(count uint)
- func (_this *IDBCursor) Continue(key interface{})
- func (_this *IDBCursor) ContinuePrimaryKey(key interface{}, primaryKey interface{})
- func (_this *IDBCursor) Delete() (_result *IDBRequest)
- func (_this *IDBCursor) Direction() IDBCursorDirection
- func (_this *IDBCursor) JSValue() js.Value
- func (_this *IDBCursor) Key() js.Value
- func (_this *IDBCursor) PrimaryKey() js.Value
- func (_this *IDBCursor) Source() *Union
- func (_this *IDBCursor) Update(value interface{}) (_result *IDBRequest)
- type IDBCursorDirection
- type IDBCursorWithValue
- type IDBDatabase
- func (_this *IDBDatabase) AddEventAbort(listener func(event *domcore.Event, currentTarget *IDBDatabase)) js.Func
- func (_this *IDBDatabase) AddEventClose(listener func(event *domcore.Event, currentTarget *IDBDatabase)) js.Func
- func (_this *IDBDatabase) AddEventError(listener func(event *domcore.Event, currentTarget *IDBDatabase)) js.Func
- func (_this *IDBDatabase) AddEventVersionChange(listener func(event *IDBVersionChangeEvent, currentTarget *IDBDatabase)) js.Func
- func (_this *IDBDatabase) Close()
- func (_this *IDBDatabase) CreateObjectStore(name string, options *IDBObjectStoreParameters) (_result *IDBObjectStore)
- func (_this *IDBDatabase) DeleteObjectStore(name string)
- func (_this *IDBDatabase) Name() string
- func (_this *IDBDatabase) ObjectStoreNames() *domcore.DOMStringList
- func (_this *IDBDatabase) OnAbort() domcore.EventHandlerFunc
- func (_this *IDBDatabase) OnClose() domcore.EventHandlerFunc
- func (_this *IDBDatabase) OnError() domcore.EventHandlerFunc
- func (_this *IDBDatabase) OnVersionChange() domcore.EventHandlerFunc
- func (_this *IDBDatabase) SetOnAbort(listener func(event *domcore.Event, currentTarget *IDBDatabase)) js.Func
- func (_this *IDBDatabase) SetOnClose(listener func(event *domcore.Event, currentTarget *IDBDatabase)) js.Func
- func (_this *IDBDatabase) SetOnError(listener func(event *domcore.Event, currentTarget *IDBDatabase)) js.Func
- func (_this *IDBDatabase) SetOnVersionChange(listener func(event *IDBVersionChangeEvent, currentTarget *IDBDatabase)) js.Func
- func (_this *IDBDatabase) Transaction(storeNames *Union, mode *IDBTransactionMode) (_result *IDBTransaction)
- func (_this *IDBDatabase) Version() int
- type IDBDatabaseInfo
- type IDBFactory
- func (_this *IDBFactory) Cmp(first interface{}, second interface{}) (_result int)
- func (_this *IDBFactory) Databases() (_result *PromiseSequenceIDBDatabaseInfo)
- func (_this *IDBFactory) DeleteDatabase(name string) (_result *IDBOpenDBRequest)
- func (_this *IDBFactory) JSValue() js.Value
- func (_this *IDBFactory) Open(name string, version *int) (_result *IDBOpenDBRequest)
- type IDBIndex
- func (_this *IDBIndex) Count(query interface{}) (_result *IDBRequest)
- func (_this *IDBIndex) Get(query interface{}) (_result *IDBRequest)
- func (_this *IDBIndex) GetAll(query interface{}, count *uint) (_result *IDBRequest)
- func (_this *IDBIndex) GetAllKeys(query interface{}, count *uint) (_result *IDBRequest)
- func (_this *IDBIndex) GetKey(query interface{}) (_result *IDBRequest)
- func (_this *IDBIndex) JSValue() js.Value
- func (_this *IDBIndex) KeyPath() js.Value
- func (_this *IDBIndex) MultiEntry() bool
- func (_this *IDBIndex) Name() string
- func (_this *IDBIndex) ObjectStore() *IDBObjectStore
- func (_this *IDBIndex) OpenCursor(query interface{}, direction *IDBCursorDirection) (_result *IDBRequest)
- func (_this *IDBIndex) OpenKeyCursor(query interface{}, direction *IDBCursorDirection) (_result *IDBRequest)
- func (_this *IDBIndex) SetName(value string)
- func (_this *IDBIndex) Unique() bool
- type IDBIndexParameters
- type IDBKeyRange
- func Bound(lower interface{}, upper interface{}, lowerOpen *bool, upperOpen *bool) (_result *IDBKeyRange)
- func IDBKeyRangeFromJS(value js.Wrapper) *IDBKeyRange
- func LowerBound(lower interface{}, open *bool) (_result *IDBKeyRange)
- func Only(value interface{}) (_result *IDBKeyRange)
- func UpperBound(upper interface{}, open *bool) (_result *IDBKeyRange)
- type IDBObjectStore
- func (_this *IDBObjectStore) Add(value interface{}, key interface{}) (_result *IDBRequest)
- func (_this *IDBObjectStore) AutoIncrement() bool
- func (_this *IDBObjectStore) Clear() (_result *IDBRequest)
- func (_this *IDBObjectStore) Count(query interface{}) (_result *IDBRequest)
- func (_this *IDBObjectStore) CreateIndex(name string, keyPath *Union, options *IDBIndexParameters) (_result *IDBIndex)
- func (_this *IDBObjectStore) Delete(query interface{}) (_result *IDBRequest)
- func (_this *IDBObjectStore) DeleteIndex(name string)
- func (_this *IDBObjectStore) Get(query interface{}) (_result *IDBRequest)
- func (_this *IDBObjectStore) GetAll(query interface{}, count *uint) (_result *IDBRequest)
- func (_this *IDBObjectStore) GetAllKeys(query interface{}, count *uint) (_result *IDBRequest)
- func (_this *IDBObjectStore) GetKey(query interface{}) (_result *IDBRequest)
- func (_this *IDBObjectStore) Index(name string) (_result *IDBIndex)
- func (_this *IDBObjectStore) IndexNames() *domcore.DOMStringList
- func (_this *IDBObjectStore) JSValue() js.Value
- func (_this *IDBObjectStore) KeyPath() js.Value
- func (_this *IDBObjectStore) Name() string
- func (_this *IDBObjectStore) OpenCursor(query interface{}, direction *IDBCursorDirection) (_result *IDBRequest)
- func (_this *IDBObjectStore) OpenKeyCursor(query interface{}, direction *IDBCursorDirection) (_result *IDBRequest)
- func (_this *IDBObjectStore) Put(value interface{}, key interface{}) (_result *IDBRequest)
- func (_this *IDBObjectStore) SetName(value string)
- func (_this *IDBObjectStore) Transaction() *IDBTransaction
- type IDBObjectStoreParameters
- type IDBOpenDBRequest
- func (_this *IDBOpenDBRequest) AddEventBlocked(listener func(event *domcore.Event, currentTarget *IDBOpenDBRequest)) js.Func
- func (_this *IDBOpenDBRequest) AddEventUpgradeNeeded(listener func(event *domcore.Event, currentTarget *IDBOpenDBRequest)) js.Func
- func (_this *IDBOpenDBRequest) OnBlocked() domcore.EventHandlerFunc
- func (_this *IDBOpenDBRequest) OnUpgradeNeeded() domcore.EventHandlerFunc
- func (_this *IDBOpenDBRequest) SetOnBlocked(listener func(event *domcore.Event, currentTarget *IDBOpenDBRequest)) js.Func
- func (_this *IDBOpenDBRequest) SetOnUpgradeNeeded(listener func(event *domcore.Event, currentTarget *IDBOpenDBRequest)) js.Func
- type IDBRequest
- func (_this *IDBRequest) AddEventError(listener func(event *domcore.Event, currentTarget *IDBRequest)) js.Func
- func (_this *IDBRequest) AddEventSuccess(listener func(event *domcore.Event, currentTarget *IDBRequest)) js.Func
- func (_this *IDBRequest) Error() *domcore.DOMException
- func (_this *IDBRequest) OnError() domcore.EventHandlerFunc
- func (_this *IDBRequest) OnSuccess() domcore.EventHandlerFunc
- func (_this *IDBRequest) ReadyState() IDBRequestReadyState
- func (_this *IDBRequest) Result() js.Value
- func (_this *IDBRequest) SetOnError(listener func(event *domcore.Event, currentTarget *IDBRequest)) js.Func
- func (_this *IDBRequest) SetOnSuccess(listener func(event *domcore.Event, currentTarget *IDBRequest)) js.Func
- func (_this *IDBRequest) Source() *Union
- func (_this *IDBRequest) Transaction() *IDBTransaction
- type IDBRequestReadyState
- type IDBTransaction
- func (_this *IDBTransaction) Abort()
- func (_this *IDBTransaction) AddEventAbort(listener func(event *domcore.Event, currentTarget *IDBTransaction)) js.Func
- func (_this *IDBTransaction) AddEventComplete(listener func(event *domcore.Event, currentTarget *IDBTransaction)) js.Func
- func (_this *IDBTransaction) AddEventError(listener func(event *domcore.Event, currentTarget *IDBTransaction)) js.Func
- func (_this *IDBTransaction) Commit()
- func (_this *IDBTransaction) Db() *IDBDatabase
- func (_this *IDBTransaction) Error() *domcore.DOMException
- func (_this *IDBTransaction) Mode() IDBTransactionMode
- func (_this *IDBTransaction) ObjectStore(name string) (_result *IDBObjectStore)
- func (_this *IDBTransaction) ObjectStoreNames() *domcore.DOMStringList
- func (_this *IDBTransaction) OnAbort() domcore.EventHandlerFunc
- func (_this *IDBTransaction) OnComplete() domcore.EventHandlerFunc
- func (_this *IDBTransaction) OnError() domcore.EventHandlerFunc
- func (_this *IDBTransaction) SetOnAbort(listener func(event *domcore.Event, currentTarget *IDBTransaction)) js.Func
- func (_this *IDBTransaction) SetOnComplete(listener func(event *domcore.Event, currentTarget *IDBTransaction)) js.Func
- func (_this *IDBTransaction) SetOnError(listener func(event *domcore.Event, currentTarget *IDBTransaction)) js.Func
- type IDBTransactionMode
- type IDBVersionChangeEvent
- type IDBVersionChangeEventInit
- type PromiseSequenceIDBDatabaseInfo
- func (_this *PromiseSequenceIDBDatabaseInfo) Catch(onRejected *PromiseSequenceIDBDatabaseInfoOnRejected) (_result *PromiseSequenceIDBDatabaseInfo)
- func (_this *PromiseSequenceIDBDatabaseInfo) Finally(onFinally *javascript.PromiseFinally) (_result *PromiseSequenceIDBDatabaseInfo)
- func (_this *PromiseSequenceIDBDatabaseInfo) JSValue() js.Value
- func (_this *PromiseSequenceIDBDatabaseInfo) Then(onFulfilled *PromiseSequenceIDBDatabaseInfoOnFulfilled, ...) (_result *PromiseSequenceIDBDatabaseInfo)
- type PromiseSequenceIDBDatabaseInfoOnFulfilled
- type PromiseSequenceIDBDatabaseInfoOnFulfilledFunc
- type PromiseSequenceIDBDatabaseInfoOnRejected
- type PromiseSequenceIDBDatabaseInfoOnRejectedFunc
- type Union
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type IDBCursor ¶
class: IDBCursor
func IDBCursorFromJS ¶
IDBCursorFromJS is casting a js.Wrapper into IDBCursor.
func (*IDBCursor) ContinuePrimaryKey ¶
func (_this *IDBCursor) ContinuePrimaryKey(key interface{}, primaryKey interface{})
func (*IDBCursor) Delete ¶
func (_this *IDBCursor) Delete() (_result *IDBRequest)
func (*IDBCursor) Direction ¶
func (_this *IDBCursor) Direction() IDBCursorDirection
Direction returning attribute 'direction' with type IDBCursorDirection (idl: IDBCursorDirection).
func (*IDBCursor) PrimaryKey ¶
PrimaryKey returning attribute 'primaryKey' with type Any (idl: any).
func (*IDBCursor) Update ¶
func (_this *IDBCursor) Update(value interface{}) (_result *IDBRequest)
type IDBCursorDirection ¶
type IDBCursorDirection int
enum: IDBCursorDirection
const ( NextIDBCursorDirection IDBCursorDirection = iota NextuniqueIDBCursorDirection PrevIDBCursorDirection PrevuniqueIDBCursorDirection )
func IDBCursorDirectionFromJS ¶
func IDBCursorDirectionFromJS(value js.Value) IDBCursorDirection
IDBCursorDirectionFromJS is converting a javascript value into a IDBCursorDirection enum value.
func (*IDBCursorDirection) JSValue ¶
func (this *IDBCursorDirection) JSValue() js.Value
JSValue is converting this enum into a javascript object
func (IDBCursorDirection) Value ¶
func (this IDBCursorDirection) Value() string
Value is converting this into javascript defined string value
type IDBCursorWithValue ¶
type IDBCursorWithValue struct {
IDBCursor
}
class: IDBCursorWithValue
func IDBCursorWithValueFromJS ¶
func IDBCursorWithValueFromJS(value js.Wrapper) *IDBCursorWithValue
IDBCursorWithValueFromJS is casting a js.Wrapper into IDBCursorWithValue.
func (*IDBCursorWithValue) Value ¶
func (_this *IDBCursorWithValue) Value() js.Value
Value returning attribute 'value' with type Any (idl: any).
type IDBDatabase ¶
type IDBDatabase struct {
domcore.EventTarget
}
class: IDBDatabase
func IDBDatabaseFromJS ¶
func IDBDatabaseFromJS(value js.Wrapper) *IDBDatabase
IDBDatabaseFromJS is casting a js.Wrapper into IDBDatabase.
func (*IDBDatabase) AddEventAbort ¶
func (_this *IDBDatabase) AddEventAbort(listener func(event *domcore.Event, currentTarget *IDBDatabase)) js.Func
AddAbort is adding doing AddEventListener for 'Abort' on target. This method is returning allocated javascript function that need to be released.
func (*IDBDatabase) AddEventClose ¶
func (_this *IDBDatabase) AddEventClose(listener func(event *domcore.Event, currentTarget *IDBDatabase)) js.Func
AddClose is adding doing AddEventListener for 'Close' on target. This method is returning allocated javascript function that need to be released.
func (*IDBDatabase) AddEventError ¶
func (_this *IDBDatabase) AddEventError(listener func(event *domcore.Event, currentTarget *IDBDatabase)) js.Func
AddError is adding doing AddEventListener for 'Error' on target. This method is returning allocated javascript function that need to be released.
func (*IDBDatabase) AddEventVersionChange ¶
func (_this *IDBDatabase) AddEventVersionChange(listener func(event *IDBVersionChangeEvent, currentTarget *IDBDatabase)) js.Func
AddVersionChange is adding doing AddEventListener for 'VersionChange' on target. This method is returning allocated javascript function that need to be released.
func (*IDBDatabase) Close ¶
func (_this *IDBDatabase) Close()
func (*IDBDatabase) CreateObjectStore ¶
func (_this *IDBDatabase) CreateObjectStore(name string, options *IDBObjectStoreParameters) (_result *IDBObjectStore)
func (*IDBDatabase) DeleteObjectStore ¶
func (_this *IDBDatabase) DeleteObjectStore(name string)
func (*IDBDatabase) Name ¶
func (_this *IDBDatabase) Name() string
Name returning attribute 'name' with type string (idl: DOMString).
func (*IDBDatabase) ObjectStoreNames ¶
func (_this *IDBDatabase) ObjectStoreNames() *domcore.DOMStringList
ObjectStoreNames returning attribute 'objectStoreNames' with type domcore.DOMStringList (idl: DOMStringList).
func (*IDBDatabase) OnAbort ¶
func (_this *IDBDatabase) OnAbort() domcore.EventHandlerFunc
OnAbort returning attribute 'onabort' with type domcore.EventHandler (idl: EventHandlerNonNull).
func (*IDBDatabase) OnClose ¶
func (_this *IDBDatabase) OnClose() domcore.EventHandlerFunc
OnClose returning attribute 'onclose' with type domcore.EventHandler (idl: EventHandlerNonNull).
func (*IDBDatabase) OnError ¶
func (_this *IDBDatabase) OnError() domcore.EventHandlerFunc
OnError returning attribute 'onerror' with type domcore.EventHandler (idl: EventHandlerNonNull).
func (*IDBDatabase) OnVersionChange ¶
func (_this *IDBDatabase) OnVersionChange() domcore.EventHandlerFunc
OnVersionChange returning attribute 'onversionchange' with type domcore.EventHandler (idl: EventHandlerNonNull).
func (*IDBDatabase) SetOnAbort ¶
func (_this *IDBDatabase) SetOnAbort(listener func(event *domcore.Event, currentTarget *IDBDatabase)) js.Func
SetOnAbort is assigning a function to 'onabort'. This This method is returning allocated javascript function that need to be released.
func (*IDBDatabase) SetOnClose ¶
func (_this *IDBDatabase) SetOnClose(listener func(event *domcore.Event, currentTarget *IDBDatabase)) js.Func
SetOnClose is assigning a function to 'onclose'. This This method is returning allocated javascript function that need to be released.
func (*IDBDatabase) SetOnError ¶
func (_this *IDBDatabase) SetOnError(listener func(event *domcore.Event, currentTarget *IDBDatabase)) js.Func
SetOnError is assigning a function to 'onerror'. This This method is returning allocated javascript function that need to be released.
func (*IDBDatabase) SetOnVersionChange ¶
func (_this *IDBDatabase) SetOnVersionChange(listener func(event *IDBVersionChangeEvent, currentTarget *IDBDatabase)) js.Func
SetOnVersionChange is assigning a function to 'onversionchange'. This This method is returning allocated javascript function that need to be released.
func (*IDBDatabase) Transaction ¶
func (_this *IDBDatabase) Transaction(storeNames *Union, mode *IDBTransactionMode) (_result *IDBTransaction)
func (*IDBDatabase) Version ¶
func (_this *IDBDatabase) Version() int
Version returning attribute 'version' with type int (idl: unsigned long long).
type IDBDatabaseInfo ¶
dictionary: IDBDatabaseInfo
func IDBDatabaseInfoFromJS ¶
func IDBDatabaseInfoFromJS(value js.Wrapper) *IDBDatabaseInfo
IDBDatabaseInfoFromJS is allocating a new IDBDatabaseInfo object and copy all values from input javascript object
func (*IDBDatabaseInfo) JSValue ¶
func (_this *IDBDatabaseInfo) JSValue() js.Value
JSValue is allocating a new javasript object and copy all values
type IDBFactory ¶
class: IDBFactory
func IDBFactoryFromJS ¶
func IDBFactoryFromJS(value js.Wrapper) *IDBFactory
IDBFactoryFromJS is casting a js.Wrapper into IDBFactory.
func (*IDBFactory) Cmp ¶
func (_this *IDBFactory) Cmp(first interface{}, second interface{}) (_result int)
func (*IDBFactory) Databases ¶
func (_this *IDBFactory) Databases() (_result *PromiseSequenceIDBDatabaseInfo)
func (*IDBFactory) DeleteDatabase ¶
func (_this *IDBFactory) DeleteDatabase(name string) (_result *IDBOpenDBRequest)
func (*IDBFactory) JSValue ¶
func (_this *IDBFactory) JSValue() js.Value
func (*IDBFactory) Open ¶
func (_this *IDBFactory) Open(name string, version *int) (_result *IDBOpenDBRequest)
type IDBIndex ¶
class: IDBIndex
func IDBIndexFromJS ¶
IDBIndexFromJS is casting a js.Wrapper into IDBIndex.
func (*IDBIndex) Count ¶
func (_this *IDBIndex) Count(query interface{}) (_result *IDBRequest)
func (*IDBIndex) Get ¶
func (_this *IDBIndex) Get(query interface{}) (_result *IDBRequest)
func (*IDBIndex) GetAll ¶
func (_this *IDBIndex) GetAll(query interface{}, count *uint) (_result *IDBRequest)
func (*IDBIndex) GetAllKeys ¶
func (_this *IDBIndex) GetAllKeys(query interface{}, count *uint) (_result *IDBRequest)
func (*IDBIndex) GetKey ¶
func (_this *IDBIndex) GetKey(query interface{}) (_result *IDBRequest)
func (*IDBIndex) MultiEntry ¶
MultiEntry returning attribute 'multiEntry' with type bool (idl: boolean).
func (*IDBIndex) ObjectStore ¶
func (_this *IDBIndex) ObjectStore() *IDBObjectStore
ObjectStore returning attribute 'objectStore' with type IDBObjectStore (idl: IDBObjectStore).
func (*IDBIndex) OpenCursor ¶
func (_this *IDBIndex) OpenCursor(query interface{}, direction *IDBCursorDirection) (_result *IDBRequest)
func (*IDBIndex) OpenKeyCursor ¶
func (_this *IDBIndex) OpenKeyCursor(query interface{}, direction *IDBCursorDirection) (_result *IDBRequest)
type IDBIndexParameters ¶
dictionary: IDBIndexParameters
func IDBIndexParametersFromJS ¶
func IDBIndexParametersFromJS(value js.Wrapper) *IDBIndexParameters
IDBIndexParametersFromJS is allocating a new IDBIndexParameters object and copy all values from input javascript object
func (*IDBIndexParameters) JSValue ¶
func (_this *IDBIndexParameters) JSValue() js.Value
JSValue is allocating a new javasript object and copy all values
type IDBKeyRange ¶
class: IDBKeyRange
func Bound ¶
func Bound(lower interface{}, upper interface{}, lowerOpen *bool, upperOpen *bool) (_result *IDBKeyRange)
func IDBKeyRangeFromJS ¶
func IDBKeyRangeFromJS(value js.Wrapper) *IDBKeyRange
IDBKeyRangeFromJS is casting a js.Wrapper into IDBKeyRange.
func LowerBound ¶
func LowerBound(lower interface{}, open *bool) (_result *IDBKeyRange)
func Only ¶
func Only(value interface{}) (_result *IDBKeyRange)
func UpperBound ¶
func UpperBound(upper interface{}, open *bool) (_result *IDBKeyRange)
func (*IDBKeyRange) Includes ¶
func (_this *IDBKeyRange) Includes(key interface{}) (_result bool)
func (*IDBKeyRange) JSValue ¶
func (_this *IDBKeyRange) JSValue() js.Value
func (*IDBKeyRange) Lower ¶
func (_this *IDBKeyRange) Lower() js.Value
Lower returning attribute 'lower' with type Any (idl: any).
func (*IDBKeyRange) LowerOpen ¶
func (_this *IDBKeyRange) LowerOpen() bool
LowerOpen returning attribute 'lowerOpen' with type bool (idl: boolean).
func (*IDBKeyRange) Upper ¶
func (_this *IDBKeyRange) Upper() js.Value
Upper returning attribute 'upper' with type Any (idl: any).
func (*IDBKeyRange) UpperOpen ¶
func (_this *IDBKeyRange) UpperOpen() bool
UpperOpen returning attribute 'upperOpen' with type bool (idl: boolean).
type IDBObjectStore ¶
type IDBObjectStore struct { // Value_JS holds a reference to a javascript value Value_JS js.Value }
class: IDBObjectStore
func IDBObjectStoreFromJS ¶
func IDBObjectStoreFromJS(value js.Wrapper) *IDBObjectStore
IDBObjectStoreFromJS is casting a js.Wrapper into IDBObjectStore.
func (*IDBObjectStore) Add ¶
func (_this *IDBObjectStore) Add(value interface{}, key interface{}) (_result *IDBRequest)
func (*IDBObjectStore) AutoIncrement ¶
func (_this *IDBObjectStore) AutoIncrement() bool
AutoIncrement returning attribute 'autoIncrement' with type bool (idl: boolean).
func (*IDBObjectStore) Clear ¶
func (_this *IDBObjectStore) Clear() (_result *IDBRequest)
func (*IDBObjectStore) Count ¶
func (_this *IDBObjectStore) Count(query interface{}) (_result *IDBRequest)
func (*IDBObjectStore) CreateIndex ¶
func (_this *IDBObjectStore) CreateIndex(name string, keyPath *Union, options *IDBIndexParameters) (_result *IDBIndex)
func (*IDBObjectStore) Delete ¶
func (_this *IDBObjectStore) Delete(query interface{}) (_result *IDBRequest)
func (*IDBObjectStore) DeleteIndex ¶
func (_this *IDBObjectStore) DeleteIndex(name string)
func (*IDBObjectStore) Get ¶
func (_this *IDBObjectStore) Get(query interface{}) (_result *IDBRequest)
func (*IDBObjectStore) GetAll ¶
func (_this *IDBObjectStore) GetAll(query interface{}, count *uint) (_result *IDBRequest)
func (*IDBObjectStore) GetAllKeys ¶
func (_this *IDBObjectStore) GetAllKeys(query interface{}, count *uint) (_result *IDBRequest)
func (*IDBObjectStore) GetKey ¶
func (_this *IDBObjectStore) GetKey(query interface{}) (_result *IDBRequest)
func (*IDBObjectStore) Index ¶
func (_this *IDBObjectStore) Index(name string) (_result *IDBIndex)
func (*IDBObjectStore) IndexNames ¶
func (_this *IDBObjectStore) IndexNames() *domcore.DOMStringList
IndexNames returning attribute 'indexNames' with type domcore.DOMStringList (idl: DOMStringList).
func (*IDBObjectStore) JSValue ¶
func (_this *IDBObjectStore) JSValue() js.Value
func (*IDBObjectStore) KeyPath ¶
func (_this *IDBObjectStore) KeyPath() js.Value
KeyPath returning attribute 'keyPath' with type Any (idl: any).
func (*IDBObjectStore) Name ¶
func (_this *IDBObjectStore) Name() string
Name returning attribute 'name' with type string (idl: DOMString).
func (*IDBObjectStore) OpenCursor ¶
func (_this *IDBObjectStore) OpenCursor(query interface{}, direction *IDBCursorDirection) (_result *IDBRequest)
func (*IDBObjectStore) OpenKeyCursor ¶
func (_this *IDBObjectStore) OpenKeyCursor(query interface{}, direction *IDBCursorDirection) (_result *IDBRequest)
func (*IDBObjectStore) Put ¶
func (_this *IDBObjectStore) Put(value interface{}, key interface{}) (_result *IDBRequest)
func (*IDBObjectStore) SetName ¶
func (_this *IDBObjectStore) SetName(value string)
SetName setting attribute 'name' with type string (idl: DOMString).
func (*IDBObjectStore) Transaction ¶
func (_this *IDBObjectStore) Transaction() *IDBTransaction
Transaction returning attribute 'transaction' with type IDBTransaction (idl: IDBTransaction).
type IDBObjectStoreParameters ¶
dictionary: IDBObjectStoreParameters
func IDBObjectStoreParametersFromJS ¶
func IDBObjectStoreParametersFromJS(value js.Wrapper) *IDBObjectStoreParameters
IDBObjectStoreParametersFromJS is allocating a new IDBObjectStoreParameters object and copy all values from input javascript object
func (*IDBObjectStoreParameters) JSValue ¶
func (_this *IDBObjectStoreParameters) JSValue() js.Value
JSValue is allocating a new javasript object and copy all values
type IDBOpenDBRequest ¶
type IDBOpenDBRequest struct {
IDBRequest
}
class: IDBOpenDBRequest
func IDBOpenDBRequestFromJS ¶
func IDBOpenDBRequestFromJS(value js.Wrapper) *IDBOpenDBRequest
IDBOpenDBRequestFromJS is casting a js.Wrapper into IDBOpenDBRequest.
func (*IDBOpenDBRequest) AddEventBlocked ¶
func (_this *IDBOpenDBRequest) AddEventBlocked(listener func(event *domcore.Event, currentTarget *IDBOpenDBRequest)) js.Func
AddBlocked is adding doing AddEventListener for 'Blocked' on target. This method is returning allocated javascript function that need to be released.
func (*IDBOpenDBRequest) AddEventUpgradeNeeded ¶
func (_this *IDBOpenDBRequest) AddEventUpgradeNeeded(listener func(event *domcore.Event, currentTarget *IDBOpenDBRequest)) js.Func
AddUpgradeNeeded is adding doing AddEventListener for 'UpgradeNeeded' on target. This method is returning allocated javascript function that need to be released.
func (*IDBOpenDBRequest) OnBlocked ¶
func (_this *IDBOpenDBRequest) OnBlocked() domcore.EventHandlerFunc
OnBlocked returning attribute 'onblocked' with type domcore.EventHandler (idl: EventHandlerNonNull).
func (*IDBOpenDBRequest) OnUpgradeNeeded ¶
func (_this *IDBOpenDBRequest) OnUpgradeNeeded() domcore.EventHandlerFunc
OnUpgradeNeeded returning attribute 'onupgradeneeded' with type domcore.EventHandler (idl: EventHandlerNonNull).
func (*IDBOpenDBRequest) SetOnBlocked ¶
func (_this *IDBOpenDBRequest) SetOnBlocked(listener func(event *domcore.Event, currentTarget *IDBOpenDBRequest)) js.Func
SetOnBlocked is assigning a function to 'onblocked'. This This method is returning allocated javascript function that need to be released.
func (*IDBOpenDBRequest) SetOnUpgradeNeeded ¶
func (_this *IDBOpenDBRequest) SetOnUpgradeNeeded(listener func(event *domcore.Event, currentTarget *IDBOpenDBRequest)) js.Func
SetOnUpgradeNeeded is assigning a function to 'onupgradeneeded'. This This method is returning allocated javascript function that need to be released.
type IDBRequest ¶
type IDBRequest struct {
domcore.EventTarget
}
class: IDBRequest
func IDBRequestFromJS ¶
func IDBRequestFromJS(value js.Wrapper) *IDBRequest
IDBRequestFromJS is casting a js.Wrapper into IDBRequest.
func (*IDBRequest) AddEventError ¶
func (_this *IDBRequest) AddEventError(listener func(event *domcore.Event, currentTarget *IDBRequest)) js.Func
AddError is adding doing AddEventListener for 'Error' on target. This method is returning allocated javascript function that need to be released.
func (*IDBRequest) AddEventSuccess ¶
func (_this *IDBRequest) AddEventSuccess(listener func(event *domcore.Event, currentTarget *IDBRequest)) js.Func
AddSuccess is adding doing AddEventListener for 'Success' on target. This method is returning allocated javascript function that need to be released.
func (*IDBRequest) Error ¶
func (_this *IDBRequest) Error() *domcore.DOMException
Error returning attribute 'error' with type domcore.DOMException (idl: DOMException).
func (*IDBRequest) OnError ¶
func (_this *IDBRequest) OnError() domcore.EventHandlerFunc
OnError returning attribute 'onerror' with type domcore.EventHandler (idl: EventHandlerNonNull).
func (*IDBRequest) OnSuccess ¶
func (_this *IDBRequest) OnSuccess() domcore.EventHandlerFunc
OnSuccess returning attribute 'onsuccess' with type domcore.EventHandler (idl: EventHandlerNonNull).
func (*IDBRequest) ReadyState ¶
func (_this *IDBRequest) ReadyState() IDBRequestReadyState
ReadyState returning attribute 'readyState' with type IDBRequestReadyState (idl: IDBRequestReadyState).
func (*IDBRequest) Result ¶
func (_this *IDBRequest) Result() js.Value
Result returning attribute 'result' with type Any (idl: any).
func (*IDBRequest) SetOnError ¶
func (_this *IDBRequest) SetOnError(listener func(event *domcore.Event, currentTarget *IDBRequest)) js.Func
SetOnError is assigning a function to 'onerror'. This This method is returning allocated javascript function that need to be released.
func (*IDBRequest) SetOnSuccess ¶
func (_this *IDBRequest) SetOnSuccess(listener func(event *domcore.Event, currentTarget *IDBRequest)) js.Func
SetOnSuccess is assigning a function to 'onsuccess'. This This method is returning allocated javascript function that need to be released.
func (*IDBRequest) Source ¶
func (_this *IDBRequest) Source() *Union
Source returning attribute 'source' with type Union (idl: Union).
func (*IDBRequest) Transaction ¶
func (_this *IDBRequest) Transaction() *IDBTransaction
Transaction returning attribute 'transaction' with type IDBTransaction (idl: IDBTransaction).
type IDBRequestReadyState ¶
type IDBRequestReadyState int
enum: IDBRequestReadyState
const ( PendingIDBRequestReadyState IDBRequestReadyState = iota DoneIDBRequestReadyState )
func IDBRequestReadyStateFromJS ¶
func IDBRequestReadyStateFromJS(value js.Value) IDBRequestReadyState
IDBRequestReadyStateFromJS is converting a javascript value into a IDBRequestReadyState enum value.
func (*IDBRequestReadyState) JSValue ¶
func (this *IDBRequestReadyState) JSValue() js.Value
JSValue is converting this enum into a javascript object
func (IDBRequestReadyState) Value ¶
func (this IDBRequestReadyState) Value() string
Value is converting this into javascript defined string value
type IDBTransaction ¶
type IDBTransaction struct {
domcore.EventTarget
}
class: IDBTransaction
func IDBTransactionFromJS ¶
func IDBTransactionFromJS(value js.Wrapper) *IDBTransaction
IDBTransactionFromJS is casting a js.Wrapper into IDBTransaction.
func (*IDBTransaction) Abort ¶
func (_this *IDBTransaction) Abort()
func (*IDBTransaction) AddEventAbort ¶
func (_this *IDBTransaction) AddEventAbort(listener func(event *domcore.Event, currentTarget *IDBTransaction)) js.Func
AddAbort is adding doing AddEventListener for 'Abort' on target. This method is returning allocated javascript function that need to be released.
func (*IDBTransaction) AddEventComplete ¶
func (_this *IDBTransaction) AddEventComplete(listener func(event *domcore.Event, currentTarget *IDBTransaction)) js.Func
AddComplete is adding doing AddEventListener for 'Complete' on target. This method is returning allocated javascript function that need to be released.
func (*IDBTransaction) AddEventError ¶
func (_this *IDBTransaction) AddEventError(listener func(event *domcore.Event, currentTarget *IDBTransaction)) js.Func
AddError is adding doing AddEventListener for 'Error' on target. This method is returning allocated javascript function that need to be released.
func (*IDBTransaction) Commit ¶
func (_this *IDBTransaction) Commit()
func (*IDBTransaction) Db ¶
func (_this *IDBTransaction) Db() *IDBDatabase
Db returning attribute 'db' with type IDBDatabase (idl: IDBDatabase).
func (*IDBTransaction) Error ¶
func (_this *IDBTransaction) Error() *domcore.DOMException
Error returning attribute 'error' with type domcore.DOMException (idl: DOMException).
func (*IDBTransaction) Mode ¶
func (_this *IDBTransaction) Mode() IDBTransactionMode
Mode returning attribute 'mode' with type IDBTransactionMode (idl: IDBTransactionMode).
func (*IDBTransaction) ObjectStore ¶
func (_this *IDBTransaction) ObjectStore(name string) (_result *IDBObjectStore)
func (*IDBTransaction) ObjectStoreNames ¶
func (_this *IDBTransaction) ObjectStoreNames() *domcore.DOMStringList
ObjectStoreNames returning attribute 'objectStoreNames' with type domcore.DOMStringList (idl: DOMStringList).
func (*IDBTransaction) OnAbort ¶
func (_this *IDBTransaction) OnAbort() domcore.EventHandlerFunc
OnAbort returning attribute 'onabort' with type domcore.EventHandler (idl: EventHandlerNonNull).
func (*IDBTransaction) OnComplete ¶
func (_this *IDBTransaction) OnComplete() domcore.EventHandlerFunc
OnComplete returning attribute 'oncomplete' with type domcore.EventHandler (idl: EventHandlerNonNull).
func (*IDBTransaction) OnError ¶
func (_this *IDBTransaction) OnError() domcore.EventHandlerFunc
OnError returning attribute 'onerror' with type domcore.EventHandler (idl: EventHandlerNonNull).
func (*IDBTransaction) SetOnAbort ¶
func (_this *IDBTransaction) SetOnAbort(listener func(event *domcore.Event, currentTarget *IDBTransaction)) js.Func
SetOnAbort is assigning a function to 'onabort'. This This method is returning allocated javascript function that need to be released.
func (*IDBTransaction) SetOnComplete ¶
func (_this *IDBTransaction) SetOnComplete(listener func(event *domcore.Event, currentTarget *IDBTransaction)) js.Func
SetOnComplete is assigning a function to 'oncomplete'. This This method is returning allocated javascript function that need to be released.
func (*IDBTransaction) SetOnError ¶
func (_this *IDBTransaction) SetOnError(listener func(event *domcore.Event, currentTarget *IDBTransaction)) js.Func
SetOnError is assigning a function to 'onerror'. This This method is returning allocated javascript function that need to be released.
type IDBTransactionMode ¶
type IDBTransactionMode int
enum: IDBTransactionMode
const ( ReadonlyIDBTransactionMode IDBTransactionMode = iota ReadwriteIDBTransactionMode VersionchangeIDBTransactionMode )
func IDBTransactionModeFromJS ¶
func IDBTransactionModeFromJS(value js.Value) IDBTransactionMode
IDBTransactionModeFromJS is converting a javascript value into a IDBTransactionMode enum value.
func (*IDBTransactionMode) JSValue ¶
func (this *IDBTransactionMode) JSValue() js.Value
JSValue is converting this enum into a javascript object
func (IDBTransactionMode) Value ¶
func (this IDBTransactionMode) Value() string
Value is converting this into javascript defined string value
type IDBVersionChangeEvent ¶
class: IDBVersionChangeEvent
func IDBVersionChangeEventFromJS ¶
func IDBVersionChangeEventFromJS(value js.Wrapper) *IDBVersionChangeEvent
IDBVersionChangeEventFromJS is casting a js.Wrapper into IDBVersionChangeEvent.
func NewIDBVersionChangeEvent ¶
func NewIDBVersionChangeEvent(_type string, eventInitDict *IDBVersionChangeEventInit) (_result *IDBVersionChangeEvent)
func (*IDBVersionChangeEvent) NewVersion ¶
func (_this *IDBVersionChangeEvent) NewVersion() *int
NewVersion returning attribute 'newVersion' with type int (idl: unsigned long long).
func (*IDBVersionChangeEvent) OldVersion ¶
func (_this *IDBVersionChangeEvent) OldVersion() int
OldVersion returning attribute 'oldVersion' with type int (idl: unsigned long long).
type IDBVersionChangeEventInit ¶
type IDBVersionChangeEventInit struct { Bubbles bool Cancelable bool Composed bool OldVersion int NewVersion *int }
dictionary: IDBVersionChangeEventInit
func IDBVersionChangeEventInitFromJS ¶
func IDBVersionChangeEventInitFromJS(value js.Wrapper) *IDBVersionChangeEventInit
IDBVersionChangeEventInitFromJS is allocating a new IDBVersionChangeEventInit object and copy all values from input javascript object
func (*IDBVersionChangeEventInit) JSValue ¶
func (_this *IDBVersionChangeEventInit) JSValue() js.Value
JSValue is allocating a new javasript object and copy all values
type PromiseSequenceIDBDatabaseInfo ¶
type PromiseSequenceIDBDatabaseInfo struct { // Value_JS holds a reference to a javascript value Value_JS js.Value }
class: Promise
func PromiseSequenceIDBDatabaseInfoFromJS ¶
func PromiseSequenceIDBDatabaseInfoFromJS(value js.Wrapper) *PromiseSequenceIDBDatabaseInfo
PromiseSequenceIDBDatabaseInfoFromJS is casting a js.Wrapper into PromiseSequenceIDBDatabaseInfo.
func (*PromiseSequenceIDBDatabaseInfo) Catch ¶
func (_this *PromiseSequenceIDBDatabaseInfo) Catch(onRejected *PromiseSequenceIDBDatabaseInfoOnRejected) (_result *PromiseSequenceIDBDatabaseInfo)
func (*PromiseSequenceIDBDatabaseInfo) Finally ¶
func (_this *PromiseSequenceIDBDatabaseInfo) Finally(onFinally *javascript.PromiseFinally) (_result *PromiseSequenceIDBDatabaseInfo)
func (*PromiseSequenceIDBDatabaseInfo) JSValue ¶
func (_this *PromiseSequenceIDBDatabaseInfo) JSValue() js.Value
func (*PromiseSequenceIDBDatabaseInfo) Then ¶
func (_this *PromiseSequenceIDBDatabaseInfo) Then(onFulfilled *PromiseSequenceIDBDatabaseInfoOnFulfilled, onRejected *PromiseSequenceIDBDatabaseInfoOnRejected) (_result *PromiseSequenceIDBDatabaseInfo)
type PromiseSequenceIDBDatabaseInfoOnFulfilled ¶
PromiseSequenceIDBDatabaseInfoOnFulfilled is a javascript function type.
Call Release() when done to release resouces allocated to this type.
func PromiseSequenceIDBDatabaseInfoOnFulfilledToJS ¶
func PromiseSequenceIDBDatabaseInfoOnFulfilledToJS(callback PromiseSequenceIDBDatabaseInfoOnFulfilledFunc) *PromiseSequenceIDBDatabaseInfoOnFulfilled
type PromiseSequenceIDBDatabaseInfoOnFulfilledFunc ¶
type PromiseSequenceIDBDatabaseInfoOnFulfilledFunc func(value []*IDBDatabaseInfo)
callback: PromiseTemplateOnFulfilled
func PromiseSequenceIDBDatabaseInfoOnFulfilledFromJS ¶
func PromiseSequenceIDBDatabaseInfoOnFulfilledFromJS(_value js.Value) PromiseSequenceIDBDatabaseInfoOnFulfilledFunc
type PromiseSequenceIDBDatabaseInfoOnRejected ¶
PromiseSequenceIDBDatabaseInfoOnRejected is a javascript function type.
Call Release() when done to release resouces allocated to this type.
func PromiseSequenceIDBDatabaseInfoOnRejectedToJS ¶
func PromiseSequenceIDBDatabaseInfoOnRejectedToJS(callback PromiseSequenceIDBDatabaseInfoOnRejectedFunc) *PromiseSequenceIDBDatabaseInfoOnRejected
type PromiseSequenceIDBDatabaseInfoOnRejectedFunc ¶
callback: PromiseTemplateOnRejected
func PromiseSequenceIDBDatabaseInfoOnRejectedFromJS ¶
func PromiseSequenceIDBDatabaseInfoOnRejectedFromJS(_value js.Value) PromiseSequenceIDBDatabaseInfoOnRejectedFunc