Skip to content

AssetName

Extends: RefCounted

Description

An AssetName (or currency symbol).

An AssetName (or currency symbol).

Constants Descriptions

Status

enum Status{SUCCESS = 0, COULD_NOT_DECODE_HEX = 1}

Method Descriptions

_init

func _init(asset_name: _AssetName) -> AssetName

to_bytes

func to_bytes() -> PackedByteArray

to_hex

func to_hex() -> String

Get the hex encoding of the AssetName.

from_hex (static)

func from_hex(hash: String) -> FromHexResult

Try to parse an [class AssetName] from [param hash] containing its hex encoding.

from_bytes (static)

func from_bytes(bytes: PackedByteArray) -> FromBytesResult

Try to parse an AssetName.

Sub-classes

FromHexResult

Property Descriptions

value

var value: AssetName
  • Getter: @value_getter

WARNING: This function may fail! First match on Result.tag or call Result.is_ok.

error

var error: String
  • Getter: @error_getter

WARNING: This function may fail! First match on Result.tag or call Result._is_err.

FromBytesResult

Property Descriptions

value

var value: AssetName
  • Getter: @value_getter

WARNING: This function may fail! First match on Result.tag or call Result.is_ok.

error

var error: String
  • Getter: @error_getter

WARNING: This function may fail! First match on Result.tag or call Result._is_err.