asset

package
v0.0.0-...-c453f8b Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2025 License: Apache-2.0, Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_ingest_asset_asset_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Asset

type Asset struct {

	// Types that are valid to be assigned to AssetType:
	//
	//	*Asset_Native
	//	*Asset_IssuedAsset
	AssetType isAsset_AssetType `protobuf_oneof:"asset_type"`
	// contains filtered or unexported fields
}

Asset message that can represent either a native asset or an issued asset

func NewIssuedAsset

func NewIssuedAsset(assetCode, issuer string) *Asset

NewIssuedAsset creates an Asset with an asset code and issuer.

func NewNativeAsset

func NewNativeAsset() *Asset

NewNativeAsset creates an Asset representing the native token (XLM).

func (*Asset) Descriptor deprecated

func (*Asset) Descriptor() ([]byte, []int)

Deprecated: Use Asset.ProtoReflect.Descriptor instead.

func (*Asset) GetAssetType

func (x *Asset) GetAssetType() isAsset_AssetType

func (*Asset) GetIssuedAsset

func (x *Asset) GetIssuedAsset() *IssuedAsset

func (*Asset) GetNative

func (x *Asset) GetNative() bool

func (*Asset) ProtoMessage

func (*Asset) ProtoMessage()

func (*Asset) ProtoReflect

func (x *Asset) ProtoReflect() protoreflect.Message

func (*Asset) Reset

func (x *Asset) Reset()

func (*Asset) String

func (x *Asset) String() string

type Asset_IssuedAsset

type Asset_IssuedAsset struct {
	IssuedAsset *IssuedAsset `protobuf:"bytes,2,opt,name=issued_asset,json=issuedAsset,proto3,oneof"` // Issued asset - via classic operations.
}

type Asset_Native

type Asset_Native struct {
	Native bool `protobuf:"varint,1,opt,name=native,proto3,oneof"` // Native asset (XLM)
}

type IssuedAsset

type IssuedAsset struct {
	AssetCode string `protobuf:"bytes,1,opt,name=asset_code,json=assetCode,proto3" json:"asset_code,omitempty"` // Asset code (e.g., USD, BTC)
	Issuer    string `protobuf:"bytes,2,opt,name=issuer,proto3" json:"issuer,omitempty"`                        // Issuer account address
	// contains filtered or unexported fields
}

func (*IssuedAsset) Descriptor deprecated

func (*IssuedAsset) Descriptor() ([]byte, []int)

Deprecated: Use IssuedAsset.ProtoReflect.Descriptor instead.

func (*IssuedAsset) GetAssetCode

func (x *IssuedAsset) GetAssetCode() string

func (*IssuedAsset) GetIssuer

func (x *IssuedAsset) GetIssuer() string

func (*IssuedAsset) ProtoMessage

func (*IssuedAsset) ProtoMessage()

func (*IssuedAsset) ProtoReflect

func (x *IssuedAsset) ProtoReflect() protoreflect.Message

func (*IssuedAsset) Reset

func (x *IssuedAsset) Reset()

func (*IssuedAsset) String

func (x *IssuedAsset) String() string

Jump to

Keyboard shortcuts

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