Class JAWTDrawingSurface

  • All Implemented Interfaces:

    public class JAWTDrawingSurface
    extends Struct
    Structure for containing the underlying drawing information of a component.

    All operations on a JAWT_DrawingSurface MUST be performed from the same thread as the call to GetDrawingSurface.

    Member documentation

    • env – Cached reference to the Java environment of the calling thread.

      If Lock(), Unlock(), GetDrawingSurfaceInfo() or FreeDrawingSurfaceInfo() are called from a different thread, this data member should be set before calling those functions.

    • target – Cached reference to the target object.


     struct JAWT_DrawingSurface {
         JNIEnv * env;
         jobject target;
         void * Lock;
         void * GetDrawingSurfaceInfo;
         void * FreeDrawingSurfaceInfo;
         void * Unlock;
    • Field Detail

      • SIZEOF

        The struct size in bytes.
      • ALIGNOF

        The struct alignment in bytes.

        The struct member offsets.
    • Constructor Detail

      • JAWTDrawingSurface

        public JAWTDrawingSurface​(java.nio.ByteBuffer container)
        Creates a JAWTDrawingSurface 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
      • env

        public long env()
        Returns the value of the env field.
      • target

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

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

        public long GetDrawingSurfaceInfo()
        Returns the value of the GetDrawingSurfaceInfo field.
      • FreeDrawingSurfaceInfo

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

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

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

        public static JAWTDrawingSurface createSafe​(long address)
        Like create, but returns null if address is NULL.
      • createSafe

        public static JAWTDrawingSurface.Buffer createSafe​(long address,
                                                           int capacity)
        Like create, but returns null if address is NULL.
      • nenv

        public static long nenv​(long struct)
        Unsafe version of env().
      • ntarget

        public static long ntarget​(long struct)
        Unsafe version of target().
      • nLock

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

        public static long nGetDrawingSurfaceInfo​(long struct)
        Unsafe version of GetDrawingSurfaceInfo().
      • nFreeDrawingSurfaceInfo

        public static long nFreeDrawingSurfaceInfo​(long struct)
        Unsafe version of FreeDrawingSurfaceInfo().
      • nUnlock

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