且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

java/grails中的服务器端网络打印

更新时间:2023-11-27 21:56:16

网络打印机的处理方式通常与本地连接的打印机没有区别;它们首先在操作系统中设置,这使得它们可用于 Java 打印服务.

Network printers are typically treated no differently from locally connected printers; they are set up in the OS first and this makes them available to the Java Print Service.

如果您需要直接打印到 POS 打印机,它们通常有自己的二进制协议,您可以通过 TCP/UDP 使用该协议.例如,爱普生有 ESC/POS 系统.

If you need to print directly to a POS printer, they usually have their own binary protocol that you can use over TCP/UDP. Epson has the ESC/POS system, for example.

根据打印服务器的不同,您可以通过 CUPS/LRP/LPD/IPP 将 PostScript 直接发送到打印机.请参阅 http://www.cups4j.orghttp://lpdspooler.sourceforge.net.

Depending on the print server, you may be able to send PostScript straight to the printer via CUPS/LRP/LPD/IPP. See http://www.cups4j.org and http://lpdspooler.sourceforge.net.