UniPRT 软件开发工具包 v2.0-pyd (Python)
 
载入中...
搜索中...
未找到
Discovery.Discovery类 参考

Public 成员函数

 GetPrinterList (self, brand=BRAND_IDX.ALL.value, responseTimeoutMs=5000)
 透过网络寻找打印机。
 
 GetPrinterList_IPv6 (self, str prefix, str interface_name, int responseTimeoutMs=3000)
 透过 IPv6 网络寻找打印机。
 

Public 属性

 ping_ipv6_address
 

成员函数说明

◆ GetPrinterList()

Discovery.Discovery.GetPrinterList ( self,
brand = BRAND_IDX.ALL.value,
responseTimeoutMs = 5000 )

透过网络寻找打印机。

参数
[in]brand: 设置打印机品牌
[in]responseTimeoutMs: 响应的暂停时间,单位: ms
返回
IP 链结字符串
程序代码
printer_list = GetPrinterList(BRAND_IDX.ALL.value, 3000)
printer_list = GetPrinterList(BRAND_IDX.TSC.value, 3000)
printer_list = GetPrinterList(BRAND_IDX.PTX.value, 3000)

◆ GetPrinterList_IPv6()

Discovery.Discovery.GetPrinterList_IPv6 ( self,
str prefix,
str interface_name,
int responseTimeoutMs = 3000 )

透过 IPv6 网络寻找打印机。

参数
[in]prefix: IPv6 前缀,会以 ping IP 作法搜寻最后 16 bits 的 IP 组合
[in]interface_name: 平台界面 ID
[in]responseTimeoutMs: 响应的暂停时间,单位: ms
返回
IPv6 链结字符串
程序代码
link_local_list = GetPrinterList_IPv6("fe80::208:96ff:fe40:", "eth0", 1000)
global_list = GetPrinterList_IPv6("2001:b030:2219:c40:208:96ff:fe40:", "", 1000)

类成员变量说明

◆ ping_ipv6_address

Discovery.Discovery.ping_ipv6_address