indexeddb

package
v1.5.1 Latest Latest
Warning

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

Go to latest
Published: Sep 14, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	//ErrNotImplemented ErrNotImplemented error
	ErrNotImplemented = errors.New("Browser not implemented IDBFactory")
	//ErrNotAnIDBFactory ErrNotAnIDBFactory error
	ErrNotAnIDBFactory = errors.New("Object is not an IDBFactory")
	//ErrNotAnIDBRequest ErrNotAnIDBOpenRequest error
	ErrNotAnIDBRequest = errors.New("Object is not an IDBRequest")
	//ErrNotAnIDBOpenRequest ErrNotAnIDBOpenRequest error
	ErrNotAnIDBOpenDBRequest = errors.New("Object is not an IDBOpenrequest")
	//ErrNotAnIDBTransaction ErrNotAnIDBOpenRequest error
	ErrNotAnIDBTransaction = errors.New("Object is not an IDBTransaction")
	//ErrNotAnIDBDatabase ErrNotAnIDBOpenRequest error
	ErrNotAnIDBDatabase = errors.New("Object is not an IDBDatabase")
	//ErrBadStoreType ErrBadStoreType error
	ErrBadStoreType = errors.New("Store type must be stringof array or string")
	//ErrNotAnIDBObjectStore ErrNotAnIDBObjectStore error
	ErrNotAnIDBObjectStore = errors.New("Object is not an ObjectStore")
	//ErrNotAnIDBIndex ErrNotAnIDBIndex error
	ErrNotAnIDBIndex = errors.New("Object is not IDBIndex")
	//ErrNotAnIDBIndex ErrNotAnIDBIndex error
	ErrNotAnIDBKeyRange = errors.New("Object is not IDBKeyRange")
	//ErrNotAnIDBCursor ErrNotAnIDBCursor error
	ErrNotAnIDBCursor = errors.New("Object is not IDBCursor")
)

Functions

func GetIDBFactoryInterface

func GetIDBFactoryInterface() js.Value

GetInterface get the JS interface

func GetIDBIndexInterface

func GetIDBIndexInterface() js.Value

GetIDBIndexInterface get the JS interface

func GetIDBKeyRangeInterface

func GetIDBKeyRangeInterface() js.Value

GetIDBIndexInterface get the JS interface

func IDBCursorGetInterface

func IDBCursorGetInterface() js.Value

func IDBCursorWithValueGetInterface

func IDBCursorWithValueGetInterface() js.Value

func IDBDatabaseGetInterface

func IDBDatabaseGetInterface() js.Value

func IDBObjectStoreGetInterface

func IDBObjectStoreGetInterface() js.Value

func IDBOpenDBRequestGetInterface

func IDBOpenDBRequestGetInterface() js.Value

func IDBRequestGetInterface

func IDBRequestGetInterface() js.Value

func IDBTransactionGetInterface

func IDBTransactionGetInterface() js.Value

Types

type IDBCursor

type IDBCursor struct {
	eventtarget.EventTarget
}

IDBCursor struct

func IDBCursorNewFromJSObject

func IDBCursorNewFromJSObject(obj js.Value) (IDBCursor, error)

func (IDBCursor) Advance

func (i IDBCursor) Advance(count int) error

func (IDBCursor) Continue

func (i IDBCursor) Continue(option ...interface{}) error

func (IDBCursor) Delete

func (i IDBCursor) Delete() (IDBRequest, error)

func (IDBCursor) Direction

func (i IDBCursor) Direction() (string, error)

func (IDBCursor) IDBCursor_

func (i IDBCursor) IDBCursor_() IDBCursor

func (IDBCursor) Key

func (i IDBCursor) Key() (interface{}, error)

func (IDBCursor) PrimaryKey

func (i IDBCursor) PrimaryKey() (interface{}, error)

func (IDBCursor) Request

func (i IDBCursor) Request() (IDBRequest, error)

func (IDBCursor) Source

func (i IDBCursor) Source() (interface{}, error)

func (IDBCursor) Update

func (i IDBCursor) Update(value interface{}) (IDBRequest, error)

type IDBCursorFrom

type IDBCursorFrom interface {
	IDBCursor_() IDBCursor
}

type IDBCursorWithValue

type IDBCursorWithValue struct {
	IDBCursor
}

IDBCursorWithValue struct

func IDBCursorWithValueNewFromJSObject

func IDBCursorWithValueNewFromJSObject(obj js.Value) (IDBCursorWithValue, error)

func (IDBCursorWithValue) IDBCursorWithValue_

func (i IDBCursorWithValue) IDBCursorWithValue_() IDBCursorWithValue

type IDBCursorWithValueFrom

type IDBCursorWithValueFrom interface {
	IDBCursorWithValue_() IDBCursorWithValue
}

type IDBDatabase

type IDBDatabase struct {
	eventtarget.EventTarget
}

IDBDatabase struct

func IDBDatabaseNewFromJSObject

func IDBDatabaseNewFromJSObject(obj js.Value) (IDBDatabase, error)

func (IDBDatabase) Close

func (i IDBDatabase) Close() error

func (IDBDatabase) CreateObjectStore

func (i IDBDatabase) CreateObjectStore(name string, options ...map[string]interface{}) (IDBObjectStore, error)

func (IDBDatabase) DeleteObjectStore

func (i IDBDatabase) DeleteObjectStore(name string) error

func (IDBDatabase) IDBDatabase_

func (i IDBDatabase) IDBDatabase_() IDBDatabase

func (IDBDatabase) Name

func (i IDBDatabase) Name() (string, error)

func (IDBDatabase) ObjectStoreNames

func (i IDBDatabase) ObjectStoreNames() (domstringlist.DOMStringList, error)

func (IDBDatabase) OnAbort

func (i IDBDatabase) OnAbort(handler func(e event.Event)) (js.Func, error)

func (IDBDatabase) OnError

func (i IDBDatabase) OnError(handler func(e event.Event)) (js.Func, error)

func (IDBDatabase) OnVersionChange

func (i IDBDatabase) OnVersionChange(handler func(e event.Event)) (js.Func, error)

func (IDBDatabase) Transaction

func (i IDBDatabase) Transaction(store interface{}, mode ...string) (IDBTransaction, error)

func (IDBDatabase) Version

func (i IDBDatabase) Version() (int64, error)

type IDBDatabaseFrom

type IDBDatabaseFrom interface {
	IDBDatabase_() IDBDatabase
}

type IDBFactory

type IDBFactory struct {
	baseobject.BaseObject
}

IDBFactory struct

func IDBFactoryNewFromJSObject

func IDBFactoryNewFromJSObject(obj js.Value) (IDBFactory, error)

func (IDBFactory) Cmp

func (f IDBFactory) Cmp(a, b interface{}) (int, error)

func (IDBFactory) Databases

func (f IDBFactory) Databases() (promise.Promise, error)

func (IDBFactory) DeleteDatabase

func (f IDBFactory) DeleteDatabase(dbname string, option ...string) (IDBOpenDBRequest, error)

func (IDBFactory) IDBFactory_

func (i IDBFactory) IDBFactory_() IDBFactory

func (IDBFactory) Open

func (f IDBFactory) Open(dbname string, option ...string) (IDBOpenDBRequest, error)

type IDBFactoryFrom

type IDBFactoryFrom interface {
	IDBFactory_() IDBFactory
}

type IDBIndex

type IDBIndex struct {
	baseobject.BaseObject
}

IDBIndex struct

func IDBDIndexNewFromJSObject

func IDBDIndexNewFromJSObject(obj js.Value) (IDBIndex, error)

func (IDBIndex) Count

func (i IDBIndex) Count(key ...interface{}) (IDBRequest, error)

func (IDBIndex) Get

func (i IDBIndex) Get(key interface{}) (IDBRequest, error)

func (IDBIndex) GetAll

func (i IDBIndex) GetAll(option ...interface{}) (IDBRequest, error)

func (IDBIndex) GetAllKeys

func (i IDBIndex) GetAllKeys(option ...interface{}) (IDBRequest, error)

func (IDBIndex) GetKey

func (i IDBIndex) GetKey(key interface{}) (IDBRequest, error)

func (IDBIndex) IDBIndex_

func (i IDBIndex) IDBIndex_() IDBIndex

func (IDBIndex) KeyPath

func (i IDBIndex) KeyPath() (string, error)

func (IDBIndex) MultiEntry

func (i IDBIndex) MultiEntry() (bool, error)

func (IDBIndex) Name

func (i IDBIndex) Name() (string, error)

func (IDBIndex) ObjectStore

func (i IDBIndex) ObjectStore() (IDBObjectStore, error)

func (IDBIndex) OpenCursor

func (i IDBIndex) OpenCursor(options ...interface{}) (IDBRequest, error)

func (IDBIndex) OpenKeyCursor

func (i IDBIndex) OpenKeyCursor(options ...interface{}) (IDBRequest, error)

func (IDBIndex) Unique

func (i IDBIndex) Unique() (bool, error)

type IDBIndexFrom

type IDBIndexFrom interface {
	IDBIndex_() IDBIndex
}

type IDBKeyRange

type IDBKeyRange struct {
	baseobject.BaseObject
}

IDBKeyRange struct

func Bound

func Bound(values ...interface{}) (IDBKeyRange, error)

func IDBDKeyRangeNewFromJSObject

func IDBDKeyRangeNewFromJSObject(obj js.Value) (IDBKeyRange, error)

func LowerBound

func LowerBound(values ...interface{}) (IDBKeyRange, error)

func Only

func Only(value interface{}) (IDBKeyRange, error)

func UpperBound

func UpperBound(values ...interface{}) (IDBKeyRange, error)

func (IDBKeyRange) IDBKeyRange_

func (i IDBKeyRange) IDBKeyRange_() IDBKeyRange

func (IDBKeyRange) Includes

func (i IDBKeyRange) Includes(value interface{}) (bool, error)

func (IDBKeyRange) Lower

func (i IDBKeyRange) Lower() (interface{}, error)

func (IDBKeyRange) Upper

func (i IDBKeyRange) Upper() (interface{}, error)

type IDBKeyRangeFrom

type IDBKeyRangeFrom interface {
	IDBKeyRange_() IDBKeyRange
}

type IDBObjectStore

type IDBObjectStore struct {
	eventtarget.EventTarget
}

IDBObjectStore struct

func IDBObjectStoreNewFromJSObject

func IDBObjectStoreNewFromJSObject(obj js.Value) (IDBObjectStore, error)

func (IDBObjectStore) Add

func (i IDBObjectStore) Add(value interface{}, key ...string) (IDBRequest, error)

func (IDBObjectStore) Clear

func (i IDBObjectStore) Clear() (IDBRequest, error)

func (IDBObjectStore) Count

func (i IDBObjectStore) Count() (IDBRequest, error)

func (IDBObjectStore) CreateIndex

func (i IDBObjectStore) CreateIndex(index string, keyname string, option ...map[string]interface{}) (IDBIndex, error)

func (IDBObjectStore) Delete

func (i IDBObjectStore) Delete(key interface{}) (IDBRequest, error)

func (IDBObjectStore) DeleteIndex

func (i IDBObjectStore) DeleteIndex(key string) error

func (IDBObjectStore) Get

func (i IDBObjectStore) Get(key interface{}) (IDBRequest, error)

func (IDBObjectStore) GetAll

func (i IDBObjectStore) GetAll(option ...interface{}) (IDBRequest, error)

func (IDBObjectStore) GetAllKeys

func (i IDBObjectStore) GetAllKeys(option ...interface{}) (IDBRequest, error)

func (IDBObjectStore) GetKey

func (i IDBObjectStore) GetKey(key interface{}) (IDBRequest, error)

func (IDBObjectStore) IDBObjectStore_

func (i IDBObjectStore) IDBObjectStore_() IDBObjectStore

func (IDBObjectStore) Index

func (i IDBObjectStore) Index(indexname string) (IDBIndex, error)

func (IDBObjectStore) OpenCursor

func (i IDBObjectStore) OpenCursor(options ...interface{}) (IDBRequest, error)

func (IDBObjectStore) OpenKeyCursor

func (i IDBObjectStore) OpenKeyCursor(options ...interface{}) (IDBRequest, error)

func (IDBObjectStore) Put

func (i IDBObjectStore) Put(value interface{}, key ...string) (IDBRequest, error)

type IDBObjectStoreFrom

type IDBObjectStoreFrom interface {
	IDBObjectStore_() IDBObjectStore
}

type IDBOpenDBRequest

type IDBOpenDBRequest struct {
	IDBRequest
}

IDBOpenRequest struct

func IDBOpenDBRequestNewFromJSObject

func IDBOpenDBRequestNewFromJSObject(obj js.Value) (IDBOpenDBRequest, error)

func (IDBOpenDBRequest) IDBOpenDBRequest_

func (i IDBOpenDBRequest) IDBOpenDBRequest_() IDBOpenDBRequest

func (IDBOpenDBRequest) OnBlocked

func (i IDBOpenDBRequest) OnBlocked(handler func(e event.Event)) (js.Func, error)

func (IDBOpenDBRequest) OnComplete

func (i IDBOpenDBRequest) OnComplete(handler func(e event.Event)) (js.Func, error)

func (IDBOpenDBRequest) OnError

func (i IDBOpenDBRequest) OnError(handler func(e event.Event)) (js.Func, error)

func (IDBOpenDBRequest) OnUpgradeNeeded

func (i IDBOpenDBRequest) OnUpgradeNeeded(handler func(e event.Event)) (js.Func, error)

type IDBOpenDBRequestFrom

type IDBOpenDBRequestFrom interface {
	IDBOpenDBRequest_() IDBOpenDBRequest
}

type IDBRequest

type IDBRequest struct {
	eventtarget.EventTarget
}

IDBRequest struct

func IDBRequestNewFromJSObject

func IDBRequestNewFromJSObject(obj js.Value) (IDBRequest, error)

func (IDBRequest) Error

func (IDBRequest) IDBRequest_

func (i IDBRequest) IDBRequest_() IDBRequest

func (IDBRequest) OnError

func (i IDBRequest) OnError(handler func(e event.Event)) (js.Func, error)

func (IDBRequest) OnSuccess

func (i IDBRequest) OnSuccess(handler func(e event.Event)) (js.Func, error)

func (IDBRequest) ReadyState

func (i IDBRequest) ReadyState() (string, error)

func (IDBRequest) Result

func (i IDBRequest) Result() (interface{}, error)

func (IDBRequest) Source

func (i IDBRequest) Source() (interface{}, error)

func (IDBRequest) Transaction

func (i IDBRequest) Transaction() (IDBTransaction, error)

type IDBRequestFrom

type IDBRequestFrom interface {
	IDBRequest_() IDBRequest
}

type IDBTransaction

type IDBTransaction struct {
	eventtarget.EventTarget
}

IDBTransaction struct

func IDBTransactionNewFromJSObject

func IDBTransactionNewFromJSObject(obj js.Value) (IDBTransaction, error)

func (IDBTransaction) Abort

func (i IDBTransaction) Abort() error

func (IDBTransaction) Commit

func (i IDBTransaction) Commit() error

func (IDBTransaction) DB

func (i IDBTransaction) DB() (IDBDatabase, error)

func (IDBTransaction) Error

func (i IDBTransaction) Error() (string, error)

func (IDBTransaction) IDBTransaction_

func (i IDBTransaction) IDBTransaction_() IDBTransaction

func (IDBTransaction) Mode

func (i IDBTransaction) Mode() (string, error)

func (IDBTransaction) ObjectStore

func (i IDBTransaction) ObjectStore(name string) (IDBObjectStore, error)

func (IDBTransaction) ObjectStoreNames

func (i IDBTransaction) ObjectStoreNames() (domstringlist.DOMStringList, error)

func (IDBTransaction) OnAbort

func (i IDBTransaction) OnAbort(handler func(e event.Event)) (js.Func, error)

type IDBTransactionFrom

type IDBTransactionFrom interface {
	IDBTransaction_() IDBTransaction
}

Jump to

Keyboard shortcuts

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