using System.Runtime.Serialization; using ESCPOS_NET.Emitters; public abstract class BaseInstruction { [DataMember(IsRequired = true)] public string? type { get; set; } public abstract List GetInstructions(); protected byte[] alignmentCommand(Alignment alignment){ var e = new EPSON(); switch (alignment) { case Alignment.Center: return e.CenterAlign(); case Alignment.Left: return e.LeftAlign(); case Alignment.Right: return e.RightAlign(); default: return e.LeftAlign(); } } }