Pointer.fromBytes constructor

Pointer.fromBytes(
  1. List<int> data
)

Implementation

factory Pointer.fromBytes(List<int> data) {
  final slot = BigintUtils.variableNatDecode(data);
  final txIndex = BigintUtils.variableNatDecode(data.sublist(slot.$2));
  final certIndex = BigintUtils.variableNatDecode(
    data.sublist(slot.$2 + txIndex.$2),
  );
  return Pointer(slot: slot.$1, txIndex: txIndex.$1, certIndex: certIndex.$1);
}