Class JAWT

  • All Implemented Interfaces:
    java.lang.AutoCloseable, NativeResource, Pointer

    public class JAWT
    extends Struct
    implements NativeResource
    Structure for containing native AWT functions.

    Member documentation

    • version – Version of this structure. This must always be set before calling JAWT_GetAWT()

    Layout

    
     struct JAWT {
         jint version;
         void * GetDrawingSurface;
         void * FreeDrawingSurface;
         void * Lock;
         void * Unlock;
         void * GetComponent;
         void * CreateEmbeddedFrame;
         void * SetBounds;
         void * SynthesizeWindowActivation;
     }
    • Field Detail

      • SIZEOF

        The struct size in bytes.
      • ALIGNOF

        The struct alignment in bytes.
      • VERSION, GETDRAWINGSURFACE, FREEDRAWINGSURFACE, LOCK, UNLOCK, GETCOMPONENT, CREATEEMBEDDEDFRAME, SETBOUNDS, SYNTHESIZEWINDOWACTIVATION

        The struct member offsets.
    • Constructor Detail

      • JAWT

        public JAWT​(java.nio.ByteBuffer container)
        Creates a JAWT instance at the current position of the specified ByteBuffer container. Changes to the buffer's content will be visible to the struct instance and vice versa.

        The created instance holds a strong reference to the container object.

    • Method Detail

      • sizeof

        public int sizeof()
        Description copied from class: Struct
        Returns sizeof(struct).
        Specified by:
        sizeof in class Struct
      • version

        public int version()
        Returns the value of the version field.
      • GetDrawingSurface

        public long GetDrawingSurface()
        Returns the value of the GetDrawingSurface field.
      • FreeDrawingSurface

        public long FreeDrawingSurface()
        Returns the value of the FreeDrawingSurface field.
      • Lock

        public long Lock()
        Returns the value of the Lock field.
      • Unlock

        public long Unlock()
        Returns the value of the Unlock field.
      • GetComponent

        public long GetComponent()
        Returns the value of the GetComponent field.
      • CreateEmbeddedFrame

        public long CreateEmbeddedFrame()
        Returns the value of the CreateEmbeddedFrame field.
      • SetBounds

        public long SetBounds()
        Returns the value of the SetBounds field.
      • SynthesizeWindowActivation

        public long SynthesizeWindowActivation()
        Returns the value of the SynthesizeWindowActivation field.
      • version

        public JAWT version​(int value)
        Sets the specified value to the version field.
      • GetDrawingSurface

        public JAWT GetDrawingSurface​(long value)
        Sets the specified value to the GetDrawingSurface field.
      • FreeDrawingSurface

        public JAWT FreeDrawingSurface​(long value)
        Sets the specified value to the FreeDrawingSurface field.
      • Lock

        public JAWT Lock​(long value)
        Sets the specified value to the Lock field.
      • Unlock

        public JAWT Unlock​(long value)
        Sets the specified value to the Unlock field.
      • GetComponent

        public JAWT GetComponent​(long value)
        Sets the specified value to the GetComponent field.
      • CreateEmbeddedFrame

        public JAWT CreateEmbeddedFrame​(long value)
        Sets the specified value to the CreateEmbeddedFrame field.
      • SetBounds

        public JAWT SetBounds​(long value)
        Sets the specified value to the SetBounds field.
      • SynthesizeWindowActivation

        public JAWT SynthesizeWindowActivation​(long value)
        Sets the specified value to the SynthesizeWindowActivation field.
      • set

        public JAWT set​(int version,
                        long GetDrawingSurface,
                        long FreeDrawingSurface,
                        long Lock,
                        long Unlock,
                        long GetComponent,
                        long CreateEmbeddedFrame,
                        long SetBounds,
                        long SynthesizeWindowActivation)
        Initializes this struct with the specified values.
      • set

        public JAWT set​(JAWT src)
        Copies the specified struct data to this struct.
        Parameters:
        src - the source struct
        Returns:
        this struct
      • malloc

        public static JAWT malloc()
        Returns a new JAWT instance allocated with memAlloc. The instance must be explicitly freed.
      • calloc

        public static JAWT calloc()
        Returns a new JAWT instance allocated with memCalloc. The instance must be explicitly freed.
      • create

        public static JAWT create​(long address)
        Returns a new JAWT instance for the specified memory address.
      • createSafe

        @Nullable
        public static JAWT createSafe​(long address)
        Like create, but returns null if address is NULL.
      • mallocStack

        public static JAWT mallocStack()
        Returns a new JAWT instance allocated on the thread-local MemoryStack.
      • callocStack

        public static JAWT callocStack()
        Returns a new JAWT instance allocated on the thread-local MemoryStack and initializes all its bits to zero.
      • mallocStack

        public static JAWT mallocStack​(MemoryStack stack)
        Returns a new JAWT instance allocated on the specified MemoryStack.
        Parameters:
        stack - the stack from which to allocate
      • callocStack

        public static JAWT callocStack​(MemoryStack stack)
        Returns a new JAWT instance allocated on the specified MemoryStack and initializes all its bits to zero.
        Parameters:
        stack - the stack from which to allocate
      • nversion

        public static int nversion​(long struct)
        Unsafe version of version().
      • nGetDrawingSurface

        public static long nGetDrawingSurface​(long struct)
        Unsafe version of GetDrawingSurface().
      • nFreeDrawingSurface

        public static long nFreeDrawingSurface​(long struct)
        Unsafe version of FreeDrawingSurface().
      • nLock

        public static long nLock​(long struct)
        Unsafe version of Lock().
      • nUnlock

        public static long nUnlock​(long struct)
        Unsafe version of Unlock().
      • nGetComponent

        public static long nGetComponent​(long struct)
        Unsafe version of GetComponent().
      • nCreateEmbeddedFrame

        public static long nCreateEmbeddedFrame​(long struct)
        Unsafe version of CreateEmbeddedFrame().
      • nSetBounds

        public static long nSetBounds​(long struct)
        Unsafe version of SetBounds().
      • nSynthesizeWindowActivation

        public static long nSynthesizeWindowActivation​(long struct)
        Unsafe version of SynthesizeWindowActivation().
      • nversion

        public static void nversion​(long struct,
                                    int value)
        Unsafe version of version.
      • nGetDrawingSurface

        public static void nGetDrawingSurface​(long struct,
                                              long value)
        Unsafe version of GetDrawingSurface.
      • nFreeDrawingSurface

        public static void nFreeDrawingSurface​(long struct,
                                               long value)
        Unsafe version of FreeDrawingSurface.
      • nLock

        public static void nLock​(long struct,
                                 long value)
        Unsafe version of Lock.
      • nUnlock

        public static void nUnlock​(long struct,
                                   long value)
        Unsafe version of Unlock.
      • nGetComponent

        public static void nGetComponent​(long struct,
                                         long value)
        Unsafe version of GetComponent.
      • nCreateEmbeddedFrame

        public static void nCreateEmbeddedFrame​(long struct,
                                                long value)
        Unsafe version of CreateEmbeddedFrame.
      • nSetBounds

        public static void nSetBounds​(long struct,
                                      long value)
        Unsafe version of SetBounds.
      • nSynthesizeWindowActivation

        public static void nSynthesizeWindowActivation​(long struct,
                                                       long value)
        Unsafe version of SynthesizeWindowActivation.