using System.Collections.Generic; using System.ComponentModel; using System.Runtime.Serialization; using System.Text.Json.Serialization; using ESCPOS_NET.Emitters; using ESCPOS_NET.Utilities; public class PrintInstruction : BaseInstruction { [DataMember(IsRequired = true)] public string? text { get; set; } public bool newLine { get; set; } = true; public override List GetInstructions() { var e = new EPSON(); var commands = new List(); if (newLine) { commands.Add(e.PrintLine(text)); } else { commands.Add(e.Print(text)); } return commands; } }