Package org.gnome.gtk
Class Printer.Builder<B extends Printer.Builder<B>>
java.lang.Object
org.javagi.gobject.Builder<B>
org.gnome.gobject.GObject.Builder<B>
org.gnome.gtk.Printer.Builder<B>
- Type Parameters:
B- the type of the Builder that is returned
- All Implemented Interfaces:
BuilderInterface
- Enclosing class:
Printer
Inner class implementing a builder pattern to construct a GObject with
properties.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Finish building thePrinterobject.Emitted in response to a request for detailed information about a printer from the print backend.setAcceptsPdf(boolean acceptsPdf) trueif this printer can accept PDF.setAcceptsPs(boolean acceptsPs) trueif this printer can accept PostScript.setBackend(MemorySegment backend) The backend for the printer.setIsVirtual(boolean isVirtual) falseif this represents a real hardware device.The name of the printer.Methods inherited from class org.gnome.gobject.GObject.Builder
onNotifyMethods inherited from class org.javagi.gobject.Builder
addBuilderProperty, connect, connect, connectSignals, getArena, getNames, getValues
-
Constructor Details
-
Builder
protected Builder()Default constructor for aBuilderobject.
-
-
Method Details
-
build
Finish building thePrinterobject. This will callGObject.withProperties(org.gnome.glib.Type, java.lang.String[], org.gnome.gobject.Value[])to create a new GObject instance, which is then cast toPrinter.- Overrides:
buildin classGObject.Builder<B extends Printer.Builder<B>>- Returns:
- a new instance of
Printerwith the properties that were set in the Builder object.
-
setAcceptsPdf
trueif this printer can accept PDF.- Parameters:
acceptsPdf- the value for theaccepts-pdfproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-
setAcceptsPs
trueif this printer can accept PostScript.- Parameters:
acceptsPs- the value for theaccepts-psproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-
setBackend
The backend for the printer.- Parameters:
backend- the value for thebackendproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-
setIsVirtual
falseif this represents a real hardware device.- Parameters:
isVirtual- the value for theis-virtualproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-
setName
-
onDetailsAcquired
Emitted in response to a request for detailed information about a printer from the print backend.The
successparameter indicates if the information was actually obtained.- Parameters:
handler- the signal handler- Returns:
- the
Builderinstance is returned, to allow method chaining - See Also:
-