finish method
Finish building, and store into the fbBuilder
.
Implementation
@override
int finish(fb.Builder fbBuilder) {
final int? ciphertextOffset =
_ciphertext == null ? null : fbBuilder.writeListUint8(_ciphertext!);
final int? labelOffset =
_label == null ? null : fbBuilder.writeString(_label!);
final int? privateKeyOffset =
_privateKey == null ? null : fbBuilder.writeString(_privateKey!);
fbBuilder.startTable(4);
fbBuilder.addOffset(0, ciphertextOffset);
fbBuilder.addOffset(1, labelOffset);
fbBuilder.addInt32(2, _hash?.value);
fbBuilder.addOffset(3, privateKeyOffset);
return fbBuilder.endTable();
}