getTemplateList method
Gets a list of the templates that have been downloaded to the printer.
Implementation
Future<PrinterStatus> getTemplateList(List<TemplateInfo> outTmplList) async {
var params = {
"printerId": mPrinterId,
"printInfo": mPrinterInfo.toMap(),
};
final Map resultMap = await _channel.invokeMethod("getTemplateList", params);
PrinterStatus status = PrinterStatus.fromMap(resultMap["printerStatus"]);
final List<dynamic> templates = resultMap["templateList"];
templates.forEach((element) {
outTmplList.add(TemplateInfo.fromMap(element));
});
return status;
}