Interface CapsForeachFunc

All Superinterfaces:
FunctionPointer
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface @Generated("org.javagi.JavaGI") public interface CapsForeachFunc extends FunctionPointer

Functional interface declaration of the CapsForeachFunc callback.

See Also:
  • Method Details

    • run

      boolean run(CapsFeatures features, Structure structure)
      A function that will be called in gst_caps_foreach(). The function may not modify features or structure.
      Parameters:
      features - the GstCapsFeatures
      structure - the GstStructure
      Returns:
      true if the foreach operation should continue, false if the foreach operation should stop with false.
      Since:
      1.6
    • upcall

      default int upcall(MemorySegment features, MemorySegment structure, MemorySegment userData)
      The upcall method is called from native code. The parameters are marshaled and run(CapsFeatures, Structure) is executed.
    • toCallback

      default MemorySegment toCallback(Arena arena)
      Creates a native function pointer to the upcall(MemorySegment, MemorySegment, MemorySegment) method.
      Specified by:
      toCallback in interface FunctionPointer
      Parameters:
      arena - the arena in which the function pointer is allocated
      Returns:
      the native function pointer