For CheckCostFuncOperation we use 1-511 range op codes.
For CheckCostFuncOperation we use 1-511 range op codes. Thus
ChangedRule.newValue
should be parsed as a sequence of getUShort
values and then the exOpCode should be checked against that parsed
sequence.
Note, we don't need to store a number of items in a sequence,
because at the time of parsing we may assume that ChangedRule.newValue
has correct length, so we just parse it until end of bytes (of cause
checking consistency).
This rule doesn't have it's own validation logic, however it is used in creation of
ValidationExceptions, which in turn can be checked for soft-fork condition using this.isSoftFork
.
The id of the first validation rule.
The id of the first validation rule. Can be used as the beginning of the rules id range.
Validation settings that correspond to the current version of the ErgoScript implementation.
Validation settings that correspond to the current version of the ErgoScript implementation. Different version of the code will have a different set of rules here. This variable is globally available and can be use wherever checking of the rules is necessary. This is immutable data structure, it can be augmented with RuleStates from block extension sections of the blockchain, but that augmentation is only available in stateful context.