decodeScaleAsInteger method
Implementation
LayoutDecodeResult<int> decodeScaleAsInteger(int offset) {
final decode = LayoutSerializationUtils.decodeScale(_bytes, offset: offset);
if (!decode.value.isValidInt) {
throw const LayoutException("scale number is too large for int.");
}
return LayoutDecodeResult(
consumed: decode.consumed,
value: decode.value.toInt(),
);
}