coreblob

package
v0.6.0-alpha.4 Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2023 License: Apache-2.0, Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ScName        = "blob"
	ScDescription = "Blob Contract"
	HScName       = wasmtypes.ScHname(0xfd91bc63)
)
View Source
const (
	ParamBlobs      = "this"
	ParamDataSchema = "d"
	ParamField      = "field"
	ParamHash       = "hash"
	ParamProgBinary = "p"
	ParamSources    = "s"
	ParamVMType     = "v"
)
View Source
const (
	ResultBlobSizes = "this"
	ResultBytes     = "bytes"
	ResultHash      = "hash"
)
View Source
const (
	FuncStoreBlob    = "storeBlob"
	ViewGetBlobField = "getBlobField"
	ViewGetBlobInfo  = "getBlobInfo"
	ViewListBlobs    = "listBlobs"
)
View Source
const (
	HFuncStoreBlob    = wasmtypes.ScHname(0xddd4c281)
	HViewGetBlobField = wasmtypes.ScHname(0x1f448130)
	HViewGetBlobInfo  = wasmtypes.ScHname(0xfde4ab46)
	HViewListBlobs    = wasmtypes.ScHname(0x62ca7990)
)

Variables

This section is empty.

Functions

func OnDispatch added in v1.0.3

func OnDispatch(index int32)

Types

type Funcs

type Funcs struct{}
var ScFuncs Funcs

func (Funcs) GetBlobField

func (sc Funcs) GetBlobField(ctx wasmlib.ScViewCallContext) *GetBlobFieldCall

Returns the chunk associated with the given blob field name.

func (Funcs) GetBlobInfo

func (sc Funcs) GetBlobInfo(ctx wasmlib.ScViewCallContext) *GetBlobInfoCall

Returns the size of each chunk of the blob.

func (Funcs) ListBlobs

func (sc Funcs) ListBlobs(ctx wasmlib.ScViewCallContext) *ListBlobsCall

Returns a list of all blobs hashes in the registry and their sized.

func (Funcs) StoreBlob

func (sc Funcs) StoreBlob(ctx wasmlib.ScFuncCallContext) *StoreBlobCall

Stores a new blob in the registry.

type GetBlobFieldCall

type GetBlobFieldCall struct {
	Func    *wasmlib.ScView
	Params  MutableGetBlobFieldParams
	Results ImmutableGetBlobFieldResults
}

type GetBlobInfoCall

type GetBlobInfoCall struct {
	Func    *wasmlib.ScView
	Params  MutableGetBlobInfoParams
	Results ImmutableGetBlobInfoResults
}

type ImmutableGetBlobFieldParams

type ImmutableGetBlobFieldParams struct {
	Proxy wasmtypes.Proxy
}

func NewImmutableGetBlobFieldParams added in v1.0.3

func NewImmutableGetBlobFieldParams() ImmutableGetBlobFieldParams

func (ImmutableGetBlobFieldParams) Field

chunk name

func (ImmutableGetBlobFieldParams) Hash

hash of the blob

type ImmutableGetBlobFieldResults

type ImmutableGetBlobFieldResults struct {
	Proxy wasmtypes.Proxy
}

func (ImmutableGetBlobFieldResults) Bytes

data for named chunk

type ImmutableGetBlobInfoParams

type ImmutableGetBlobInfoParams struct {
	Proxy wasmtypes.Proxy
}

func NewImmutableGetBlobInfoParams added in v1.0.3

func NewImmutableGetBlobInfoParams() ImmutableGetBlobInfoParams

func (ImmutableGetBlobInfoParams) Hash

hash of the blob

type ImmutableGetBlobInfoResults

type ImmutableGetBlobInfoResults struct {
	Proxy wasmtypes.Proxy
}

func (ImmutableGetBlobInfoResults) BlobSizes

sizes for each named chunk

type ImmutableListBlobsResults

type ImmutableListBlobsResults struct {
	Proxy wasmtypes.Proxy
}

func (ImmutableListBlobsResults) BlobSizes

sizes for each blob hash

type ImmutableStoreBlobParams

type ImmutableStoreBlobParams struct {
	Proxy wasmtypes.Proxy
}

func NewImmutableStoreBlobParams added in v1.0.3

func NewImmutableStoreBlobParams() ImmutableStoreBlobParams

func (ImmutableStoreBlobParams) Blobs

set of named chunks

func (ImmutableStoreBlobParams) DataSchema added in v1.0.3

data schema for external tools

func (ImmutableStoreBlobParams) ProgBinary added in v0.3.0

smart contract program binary code

func (ImmutableStoreBlobParams) Sources added in v1.0.3

smart contract program source code

func (ImmutableStoreBlobParams) VMType added in v0.3.1

VM type that must be used to run progBinary

type ImmutableStoreBlobResults

type ImmutableStoreBlobResults struct {
	Proxy wasmtypes.Proxy
}

func (ImmutableStoreBlobResults) Hash

calculated hash of blob chunks

type ListBlobsCall

type ListBlobsCall struct {
	Func    *wasmlib.ScView
	Results ImmutableListBlobsResults
}

type MapHashToImmutableInt32

type MapHashToImmutableInt32 struct {
	Proxy wasmtypes.Proxy
}

func (MapHashToImmutableInt32) GetInt32

type MapHashToMutableInt32

type MapHashToMutableInt32 struct {
	Proxy wasmtypes.Proxy
}

func (MapHashToMutableInt32) Clear

func (m MapHashToMutableInt32) Clear()

func (MapHashToMutableInt32) GetInt32

type MapStringToImmutableBytes

type MapStringToImmutableBytes struct {
	Proxy wasmtypes.Proxy
}

func (MapStringToImmutableBytes) GetBytes

type MapStringToImmutableInt32

type MapStringToImmutableInt32 struct {
	Proxy wasmtypes.Proxy
}

func (MapStringToImmutableInt32) GetInt32

type MapStringToMutableBytes

type MapStringToMutableBytes struct {
	Proxy wasmtypes.Proxy
}

func (MapStringToMutableBytes) Clear

func (m MapStringToMutableBytes) Clear()

func (MapStringToMutableBytes) GetBytes

type MapStringToMutableInt32

type MapStringToMutableInt32 struct {
	Proxy wasmtypes.Proxy
}

func (MapStringToMutableInt32) Clear

func (m MapStringToMutableInt32) Clear()

func (MapStringToMutableInt32) GetInt32

type MutableGetBlobFieldParams

type MutableGetBlobFieldParams struct {
	Proxy wasmtypes.Proxy
}

func (MutableGetBlobFieldParams) Field

chunk name

func (MutableGetBlobFieldParams) Hash

hash of the blob

type MutableGetBlobFieldResults

type MutableGetBlobFieldResults struct {
	Proxy wasmtypes.Proxy
}

func NewMutableGetBlobFieldResults added in v1.0.3

func NewMutableGetBlobFieldResults() MutableGetBlobFieldResults

func (MutableGetBlobFieldResults) Bytes

data for named chunk

type MutableGetBlobInfoParams

type MutableGetBlobInfoParams struct {
	Proxy wasmtypes.Proxy
}

func (MutableGetBlobInfoParams) Hash

hash of the blob

type MutableGetBlobInfoResults

type MutableGetBlobInfoResults struct {
	Proxy wasmtypes.Proxy
}

func NewMutableGetBlobInfoResults added in v1.0.3

func NewMutableGetBlobInfoResults() MutableGetBlobInfoResults

func (MutableGetBlobInfoResults) BlobSizes

sizes for each named chunk

type MutableListBlobsResults

type MutableListBlobsResults struct {
	Proxy wasmtypes.Proxy
}

func NewMutableListBlobsResults added in v1.0.3

func NewMutableListBlobsResults() MutableListBlobsResults

func (MutableListBlobsResults) BlobSizes

sizes for each blob hash

type MutableStoreBlobParams

type MutableStoreBlobParams struct {
	Proxy wasmtypes.Proxy
}

func (MutableStoreBlobParams) Blobs

set of named chunks

func (MutableStoreBlobParams) DataSchema added in v1.0.3

data schema for external tools

func (MutableStoreBlobParams) ProgBinary added in v0.3.0

smart contract program binary code

func (MutableStoreBlobParams) Sources added in v1.0.3

smart contract program source code

func (MutableStoreBlobParams) VMType added in v0.3.1

VM type that must be used to run progBinary

type MutableStoreBlobResults

type MutableStoreBlobResults struct {
	Proxy wasmtypes.Proxy
}

func NewMutableStoreBlobResults added in v1.0.3

func NewMutableStoreBlobResults() MutableStoreBlobResults

func (MutableStoreBlobResults) Hash

calculated hash of blob chunks

type StoreBlobCall

type StoreBlobCall struct {
	Func    *wasmlib.ScFunc
	Params  MutableStoreBlobParams
	Results ImmutableStoreBlobResults
}

Jump to

Keyboard shortcuts

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