Class ViewSwitcher.Builder<B extends ViewSwitcher.Builder<B>>

Type Parameters:
B - the type of the Builder that is returned
All Implemented Interfaces:
Accessible.Builder<B>, BuilderInterface
Enclosing class:
ViewSwitcher

public static class ViewSwitcher.Builder<B extends ViewSwitcher.Builder<B>> extends Widget.Builder<B> implements Accessible.Builder<B>
Inner class implementing a builder pattern to construct a GObject with properties.
  • Constructor Details

    • Builder

      protected Builder()
      Default constructor for a Builder object.
  • Method Details

    • build

      public ViewSwitcher build()
      Finish building the ViewSwitcher object. This will call GObject.withProperties(Type, String[], Value[]) to create a new GObject instance, which is then cast to ViewSwitcher.
      Overrides:
      build in class Widget.Builder<B extends ViewSwitcher.Builder<B>>
      Returns:
      a new instance of ViewSwitcher with the properties that were set in the Builder object.
    • setPolicy

      public B setPolicy(ViewSwitcherPolicy policy)
      The policy to determine which mode to use.
      Parameters:
      policy - the value for the policy property
      Returns:
      the Builder instance is returned, to allow method chaining
    • setStack

      public B setStack(ViewStack stack)
      The stack the view switcher controls.
      Parameters:
      stack - the value for the stack property
      Returns:
      the Builder instance is returned, to allow method chaining