getIndicesBySignature method
Get the indices associated to a signature proposition
signatureProposition
The signature proposition to get the indices for
Returns the indices associated to the signature proposition if it exists. Else null
Implementation
@override
Indices? getIndicesBySignature(
Proposition_DigitalSignature signatureProposition) {
final result = cartesiansStore.findSync(_instance,
finder: Finder(
filter: Filter.and([
Filter.equals("routine", signatureProposition.routine),
Filter.equals(
"vk",
Encoding().encodeToBase58Check(
signatureProposition.verificationKey.writeToBuffer())),
])));
if (result.isEmpty) return null;
return Indices(
x: result.first["xFellowship"] as int?,
y: result.first["yContract"] as int?,
z: result.first["zState"] as int?,
);
}