Class Fraction

All Implemented Interfaces:
Proxy

@Generated("org.javagi.JavaGI") public class Fraction extends TypeInstance
A fundamental type that describes a fraction of an integer numerator over an integer denominator
  • Constructor Details

    • Fraction

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

    • getType

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

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

      protected Fraction 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.
      Returns:
      the instance as if it were its parent type