Skip to main content

Upgrade

type Upgrade​

Command to upgrade an already published package

BCS​

The BCS serialized form of this type is specified in [`bcs-schema.abnf`](https://github.com/iotaledger/iota-rust-sdk/blob/develop/crates/iota-sdk-types/bcs-schema.abnf\).

type Upgrade struct {
// contains filtered or unexported fields
}

func LiftFromExternalUpgrade​

func LiftFromExternalUpgrade(handle uint64) *Upgrade

func NewUpgrade​

func NewUpgrade(modules [][]byte, dependencies []*ObjectId, varPackage *ObjectId, ticket *Argument) *Upgrade

func UpgradeFromBcs​

func UpgradeFromBcs(bcs []byte) (*Upgrade, error)

Create this type from BCS encoded bytes.

func UpgradeFromJson​

func UpgradeFromJson(json string) (*Upgrade, error)

Create this type from a JSON encoded string.

func (*Upgrade) DebugString​

func (_self *Upgrade) DebugString() string

func (*Upgrade) Dependencies​

func (_self *Upgrade) Dependencies() []*ObjectId

Set of packages that the to-be published package depends on

func (*Upgrade) Destroy​

func (object *Upgrade) Destroy()

func (*Upgrade) Eq​

func (_self *Upgrade) Eq(other *Upgrade) bool

func (*Upgrade) Modules​

func (_self *Upgrade) Modules() [][]byte

The serialized move modules

func (*Upgrade) Ne​

func (_self *Upgrade) Ne(other *Upgrade) bool

func (*Upgrade) Package​

func (_self *Upgrade) Package() *ObjectId

Package id of the package to upgrade

func (*Upgrade) Ticket​

func (_self *Upgrade) Ticket() *Argument

Ticket authorizing the upgrade

func (*Upgrade) ToBcs​

func (_self *Upgrade) ToBcs() ([]byte, error)

Convert this type to BCS encoded bytes.

func (*Upgrade) ToDisplayString​

func (_self *Upgrade) ToDisplayString() string

Render this type as human-readable text.

Some types also print this through the binding's native string conversion; this method is the spelling every object type has.

The layout is meant for reading and can change between releases. Use the JSON or BCS conversions for output that gets parsed.

func (*Upgrade) ToJson​

func (_self *Upgrade) ToJson() (string, error)

Convert this type to a JSON encoded string.