Package org.gnome.gtksourceview
Class FileLoader.Builder<B extends FileLoader.Builder<B>>
java.lang.Object
org.javagi.gobject.Builder<B>
org.gnome.gobject.GObject.Builder<B>
org.gnome.gtksourceview.FileLoader.Builder<B>
- Type Parameters:
B- the type of the Builder that is returned
- All Implemented Interfaces:
BuilderInterface
- Enclosing class:
FileLoader
Inner class implementing a builder pattern to construct a GObject with
properties.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Finish building theFileLoaderobject.TheGtkSourceBufferto load the contents into.TheGtkSourceFile.setInputStream(InputStream inputStream) TheGInputStreamto load.setLocation(File location) TheGFileto load.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 theFileLoaderobject. 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 toFileLoader.- Overrides:
buildin classGObject.Builder<B extends FileLoader.Builder<B>>- Returns:
- a new instance of
FileLoaderwith the properties that were set in the Builder object.
-
setBuffer
-
setFile
-
setInputStream
TheGInputStreamto load. Useful for reading stdin. If this property is set, theGtkSourceFileLoader:location property is ignored.- Parameters:
inputStream- the value for theinput-streamproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-
setLocation
TheGFileto load. If theGtkSourceFileLoader:input-stream isnull, by default the location is taken from theGtkSourceFileat construction time.- Parameters:
location- the value for thelocationproperty- Returns:
- the
Builderinstance is returned, to allow method chaining
-