Currently printing uses BSD commands on Linux. That only provides
very limited options in combination with CUPS's BSD compatibility
layer:
E.g. I have one printer named brother. It has a default instance for
normal one-sided printing and two additional instances for for duplex
printing and two-sides-on-one duplex printing.
% lpstat -d -v
system default destination: brother/duplex
device for brother: ipp://192.168.1.20:631/ipp
device for brother/duplex: ipp://192.168.1.20:631/ipp
device for brother/papers: ipp://192.168.1.20:631/ipp
The current J2SE code only see one printer on Linux (Solaris should be
OK because it uses SYSV commands):
% java ListCUPSDestinations[1]
Unix Printer : brother
With a few modifications[2] I get better results:
% java ListCUPSDestinations
Unix Printer : brother/duplex
Unix Printer : brother
Unix Printer : brother/duplex
Unix Printer : brother/papers