Package org.gnome.gio
Class PropertyAction.Builder<B extends PropertyAction.Builder<B>>
java.lang.Object
io.github.jwharm.javagi.gobject.Builder<B>
org.gnome.gobject.GObject.Builder<B>
org.gnome.gio.PropertyAction.Builder<B>
- Type Parameters:
B
- the type of the Builder that is returned
- All Implemented Interfaces:
BuilderInterface
,Action.Builder<B>
- Enclosing class:
PropertyAction
public static class PropertyAction.Builder<B extends PropertyAction.Builder<B>>
extends GObject.Builder<B>
implements Action.Builder<B>
Inner class implementing a builder pattern to construct a GObject with
properties.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Finish building thePropertyAction
object.setInvertBoolean
(boolean invertBoolean) Iftrue
, the state of the action will be the negation of the property value, provided the property is boolean.The name of the action.The object to wrap a property on.setPropertyName
(String propertyName) The name of the property to wrap on the object.Methods inherited from class org.gnome.gobject.GObject.Builder
onNotify
Methods inherited from class io.github.jwharm.javagi.gobject.Builder
addBuilderProperty, connect, connect, connectSignals, getArena, getNames, getValues
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.github.jwharm.javagi.gobject.BuilderInterface
addBuilderProperty, connect, connect, getArena
-
Constructor Details
-
Builder
protected Builder()Default constructor for aBuilder
object.
-
-
Method Details
-
build
Finish building thePropertyAction
object. 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 toPropertyAction
.- Overrides:
build
in classGObject.Builder<B extends PropertyAction.Builder<B>>
- Returns:
- a new instance of
PropertyAction
with the properties that were set in the Builder object.
-
setInvertBoolean
Iftrue
, the state of the action will be the negation of the property value, provided the property is boolean.- Parameters:
invertBoolean
- the value for theinvert-boolean
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-
setName
-
setObject
-
setPropertyName
The name of the property to wrap on the object.The property must exist on the passed-in object and it must be readable and writable (and not construct-only).
- Parameters:
propertyName
- the value for theproperty-name
property- Returns:
- the
Builder
instance is returned, to allow method chaining
-