OperationOrigination
public class OperationOrigination : Operation
Operation subclass for originating a contract on the Tezos network
-
The initial balance to give to the contract
Declaration
Swift
public let balance: String -
Dictionary holding the
codeandstorageof the contract to create.Declaration
Swift
public let script: [String : Any] -
Create an OperationOrigination.
Declaration
Swift
public init(source: String, balance: XTZAmount, code: String, storage: String)Parameters
sourceThe address originating the contract and paying the fees.
balanceHow much XTZ to initiate the contract with.
codeMicheline string containing the contract code.
storageMicheline string containing the initial storage of the contract.
-
Create a base operation.
Declaration
Swift
public required init(from decoder: Decoder) throwsParameters
fromA decoder used to convert a data fromat (such as JSON) into the model object.
-
Convert the object into a data format, such as JSON.
Declaration
Swift
public override func encode(to encoder: Encoder) throwsParameters
toAn encoder that will allow conversions to multipel data formats.
-
A function to check if two operations are equal.
Declaration
Swift
public func isEqual(_ op: OperationOrigination) -> BoolParameters
_An
Operationto compare againstReturn Value
A
Boolindicating the result.
Install in Dash