Class Win32Printer
java.lang.Object
io.github.eggy03.ferrumx.windows.entity.peripheral.Win32Printer
Immutable representation of a Printing device on a Windows system.
Fields correspond to properties retrieved from the Win32_Printer WMI class.
Usage example
// Build a new instance
Win32Printer printer = Win32Printer.builder()
.deviceId("PR1")
.name("Primary Printer")
.isShared(true)
.shareName("Shared Primary Printer")
.build();
// Modify using toBuilder()
Win32Printer updated = printer.toBuilder()
.isShared(false)
.shareName(null)
.build();
- Since:
- 3.0.0
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionList of capability codes supported by the printer.Descriptive text corresponding tocapabilities.(package private) @Nullable StringSystem-assigned unique identifier of the printer.(package private) @Nullable StringName of the printer driver installed.(package private) @Nullable BooleanSpecifies whether the printer is hidden from standard user interfaces.(package private) @Nullable LongPrinter’s horizontal resolution in DPI (dots per inch).(package private) @Nullable StringName of the printer as recognized by the system.Numeric codes of paper sizes supported by the printer.(package private) @Nullable StringWindows Plug and Play device identifierNames of paper types or forms supported by the printer.(package private) @Nullable IntegerCurrent operational state of the printer.(package private) @Nullable StringData type of print jobs Example: RAW or EMF(package private) @Nullable StringPrint processor used to process print jobs Example: WinPrint(package private) @Nullable BooleanIndicates whether the printer is shared on the network.(package private) @Nullable StringShare name of the printer if it is shared.(package private) @Nullable BooleanIndicates whether spooling is enabled for the printer.(package private) @Nullable LongPrinter’s vertical resolution in DPI (dots per inch). -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
deviceId
System-assigned unique identifier of the printer. -
name
Name of the printer as recognized by the system. -
pnpDeviceId
Windows Plug and Play device identifier -
capabilities
List of capability codes supported by the printer.- 1 - Other
- 2 - Color printing
- 3 - Duplex printing
- 4 - Copies
- 5 - Collation
- 6 - Stapling
- 7 - Transparency printing
- 8 - Punch
- 9 - Cover
- 10 - Bind
- 11 - Black-and-white printing
- 12 - One-sided
- 13 - Two-sided long edge
- 14 - Two-sided short edge
- 15 - Portrait
- 16 - Landscape
- 17 - Reverse Portrait
- 18 - Reverse Landscape
- 19 - Quality High
- 20 - Quality Normal
- 21 - Quality Low
-
capabilityDescriptions
Descriptive text corresponding tocapabilities. -
horizontalResolution
Printer’s horizontal resolution in DPI (dots per inch). -
verticalResolution
Printer’s vertical resolution in DPI (dots per inch). -
paperSizesSupported
-
printerPaperNames
-
printerStatus
Current operational state of the printer.- 1 - Other
- 2 - Unknown
- 3 - Idle
- 4 - Printing
- 5 - Warm-up
- 6 - Stopped printing
- 7 - Offline
-
printJobDataType
Data type of print jobs Example: RAW or EMF -
printProcessor
Print processor used to process print jobs Example: WinPrint -
driverName
Name of the printer driver installed. -
spoolEnabled
Indicates whether spooling is enabled for the printer.
-
-
Constructor Details
-
Win32Printer
public Win32Printer()
-
-
Method Details
-
hasSpoolEnabled
-
isHidden
-
toString