Script class

Constructors

Script(Iterable<ScriptOp> ops)
Constructs a script from the operations
Script.decompile(Uint8List script, {bool requireMinimal = true})
Decompiles the script and may return a sub-class representing the script type. May return OutOfData if the script has an invalid pushdata. If requireMinimal is true (default), the script push push data minimally or PushDataNotMinimal will be thrown.
factory
Script.fromAsm(String asm)
Constructs a script from the given script assembly string (asm). May return a matching sub-class for the given script.
factory

Properties

asm String
Returns the ASM string representation of the script. All data and integers are provided in hex format.
no setter
compiled Uint8List
Returns the copied compiled bytes for the script.
no setter
hashCode int
The hash code for this object.
no setterinherited
length int
no setter
ops List<ScriptOp>
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

fill(List values) Script
Fills the script matchers (only ScriptPushDataMatcher right now) with the provided values. A Uint8List should be provided for each ScriptPushDataMatcher.
match(Script other) bool
Returns true if the script matches another, including a script containing a ScriptPushDataMatcher.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited
operator [](int i) ScriptOp