zplCore.comzplCore.com

RawFilePrinterConnection

public sealed class RawFilePrinterConnection : IPrinterConnection, IAsyncDisposable

Writes to a device path or file: /dev/usb/lp0, LPT1, \\.\USB001, a share, or a plain file. Write-only.

Constructors

SignatureDescription
# RawFilePrinterConnection(string path, bool append = true)Writes to a device path or file: /dev/usb/lp0, LPT1, \\.\USB001, a share, or a plain file. Write-only.

Properties

PropertyTypeDescription
Append { get; }bool
Path { get; }string

Methods

Method SignatureReturnsDescription
# DisposeAsync()ValueTask
# QueryAsync(string command, TimeSpan timeout, CancellationToken ct = default)Task<string>Write-only transport: returns null without sending anything (a query must not end up as a print job).
# SendAsync(byte[] data, CancellationToken ct = default)Task