Class ViewStackPages

All Implemented Interfaces:
Iterable<ViewStackPage>, Collection<ViewStackPage>, List<ViewStackPage>, SequencedCollection<ViewStackPage>, ListModel<ViewStackPage>, SectionModel<ViewStackPage>, SelectionModel<ViewStackPage>, Proxy, ListModelJavaList<ViewStackPage>

@Generated("org.javagi.JavaGI") public final class ViewStackPages extends GObject implements ListModel<ViewStackPage>, SectionModel<ViewStackPage>, SelectionModel<ViewStackPage>

An auxiliary class used by ViewStack.

See ViewStack:pages.

Since:
1.4
  • Constructor Details

    • ViewStackPages

      public ViewStackPages(MemorySegment address)
      Create a ViewStackPages instance for the provided memory address.
      Parameters:
      address - the memory address of the native object
    • ViewStackPages

      public ViewStackPages()
      Create a new ViewStackPages.
  • Method Details

    • getType

      public static @Nullable Type getType()
      Get the GType of the ViewStackPages class.
      Returns:
      the GType
    • getMemoryLayout

      public static MemoryLayout getMemoryLayout()
      The memory layout of the native struct.
      Returns:
      the memory layout
    • asParent

      protected ViewStackPages asParent()
      Return this instance as if it were its parent type. Comparable to the Java super keyword, but ensures the parent typeclass is also used in native code.
      Overrides:
      asParent in class GObject
      Returns:
      the instance as if it were its parent type
    • getSelectedPage

      public @Nullable ViewStackPage getSelectedPage()

      Gets the ViewStackPage for the visible child of a view stack

      Gets the ViewStackPage for the visible child of the associated stack.

      Returns NULL if there's no selected page.

      Returns:
      the stack page
      Since:
      1.4
    • setSelectedPage

      public void setSelectedPage(ViewStackPage page)

      Sets the visible child in the associated ViewStack.

      See ViewStack:visible-child.

      Parameters:
      page - a stack page within the associated stack
      Since:
      1.4
    • builder

      public static ViewStackPages.Builder<? extends ViewStackPages.Builder> builder()
      A ViewStackPages.Builder object constructs a ViewStackPages with the specified properties. Use the various set...() methods to set properties, and finish construction with ViewStackPages.Builder.build().
      Returns:
      the builder object