Class MemoryTextureBuilder.Builder<B extends MemoryTextureBuilder.Builder<B>>

java.lang.Object
org.javagi.gobject.Builder<B>
org.gnome.gobject.GObject.Builder<B>
org.gnome.gdk.MemoryTextureBuilder.Builder<B>
Type Parameters:
B - the type of the Builder that is returned
All Implemented Interfaces:
BuilderInterface
Enclosing class:
MemoryTextureBuilder

public static class MemoryTextureBuilder.Builder<B extends MemoryTextureBuilder.Builder<B>> extends GObject.Builder<B>
Inner class implementing a builder pattern to construct a GObject with properties.
Since:
4.16
  • Constructor Details

    • Builder

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

    • build

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

      public B setBytes(byte[] bytes)
      The bytes holding the data.
      Parameters:
      bytes - the value for the bytes property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.16
    • setColorState

      public B setColorState(ColorState colorState)
      The colorstate describing the data.
      Parameters:
      colorState - the value for the color-state property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.16
    • setFormat

      public B setFormat(MemoryFormat format)
      The format of the data.
      Parameters:
      format - the value for the format property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.16
    • setHeight

      public B setHeight(int height)
      The height of the texture.
      Parameters:
      height - the value for the height property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.16
    • setStride

      public B setStride(long stride)

      The rowstride of the texture.

      The rowstride is the number of bytes between the first pixel in a row of image data, and the first pixel in the next row.

      Parameters:
      stride - the value for the stride property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.16
    • setUpdateRegion

      public B setUpdateRegion(org.freedesktop.cairo.Region updateRegion)
      The update region for Gdk.MemoryTextureBuilder:update-texture.
      Parameters:
      updateRegion - the value for the update-region property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.16
    • setUpdateTexture

      public B setUpdateTexture(Texture updateTexture)
      The texture Gdk.MemoryTextureBuilder:update-region is an update for.
      Parameters:
      updateTexture - the value for the update-texture property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.16
    • setWidth

      public B setWidth(int width)
      The width of the texture.
      Parameters:
      width - the value for the width property
      Returns:
      the Builder instance is returned, to allow method chaining
      Since:
      4.16