addRfuForEMVCo method
add rfu for emvcode
RFU for EMVCo is list type.
u can add more than one item.
id
id No. is "65" up to "79".
max length of value
is 99.
Implementation
addRfuForEMVCo({String? id, String? value}) {
if (id != null && value != null) {
if (int.parse(id) < int.parse(ID.rfuForEMVCoRangeStart) ||
int.parse(id) > int.parse(ID.rfuForEMVCoRangeEnd)) {
// this.value = this.value.copyWith(rfuForEmvCo: []);
throw InvalidId(title: "RfuForEMVCo");
}
if (value.length > 99) {
throw MaxValueLengthErr(title: "RFUFforEmvCo", length: "99");
}
if (this.value.rfuForEmvCo != null) {
this.value.rfuForEmvCo?.add(setTLV(value, id));
} else {
List<TLVModel> tlv = [];
tlv.add(setTLV(value, id));
this.value = this.value.copyWith(rfuForEmvCo: tlv);
}
}
}