使用sendToPrinter API using-the-sendtoprinter-api
概述 overview
在AEM Forms中,您可以使用SendToPrinter服务将文档发送到打印机。 SendToPrinter服务支持以下打印访问机制:
-
可直接访问的打印机
: A printer that is installed on the same computer is called a direct accessible printer, and the computer is named printer host. This type of printer can be a local printer that is connected to the computer directly.
-
间接可访问的打印机
: The printer that is installed on a print server is accessed from other computers. Technologies such as the common UNIX® printing system (CUPS) and the Line Printer Daemon (LPD) protocol are available to connect to a network printer. To access an indirect accessible printer, specify the print server’s IP or host name. Using this mechanism, you can send a document to an LPD URI when the network has an LPD running. The mechanism lets you route the document to any printer that is connected to the network that has an LPD running.
将文档发送到打印机时,请指定以下打印协议之一:
- 杯子
: A printing protocol named common UNIX printing system. This protocol is used for UNIX operating systems and enables a computer to function as a print server. The print server accepts print requests from client applications, processes them, and sends them to configured printers. On the IBM AIX® operating system, usage of CUPS is not recommended.
- "DirectIP
: A standard protocol for remote printing and managing print jobs. This protocol can be used locally or remotely. Print queues are not required.
- "LPD
: A printing protocol named Line Printer Daemon protocol or Line Printer Remote (LPR) protocol. This protocol provides network print server functionality for UNIX-based systems.
- SharedPrinter
: A printing protocol that enables a computer to use a printer that is configured for that computer.
- CIFS:输出服务支持通用Internet文件系统(CIFS)打印协议。
- 杯子
使用SendToPrinter服务 using-sendtoprinter-service
下表列出:
- 有关用于各种协议的printerName或printServer的信息。
- 打印机返回的打印机服务器URI和打印机名称的各种组合的值或例外
身份验证支持 authentication-support
仅CIFS打印支持身份验证。 要进行身份验证,请在PrinterSpec中提供用户名/密码/域。 您可以通过执行以下步骤,使用AEM Granite CyprotoSupport服务加密密码:
-
转到https://<server>:<port>/system/console.
-
转到 主要 > 加密支持.
-
输入一些纯文本,然后单击 Protect.