Class NullMemory

java.lang.Object
org.python.modules.jffi.InvalidMemory
org.python.modules.jffi.NullMemory
All Implemented Interfaces:
DirectMemory, Memory

public class NullMemory extends InvalidMemory implements DirectMemory
An implementation of MemoryIO that throws an exception on any access.
  • Constructor Details

    • NullMemory

      public NullMemory()
  • Method Details

    • getAddress

      public long getAddress()
      Specified by:
      getAddress in interface DirectMemory
    • isNull

      public boolean isNull()
      Description copied from interface: Memory
      Checks if the memory area is NULL.
      Specified by:
      isNull in interface Memory
      Returns:
      true if the memory area is invalid.
    • isDirect

      public final boolean isDirect()
      Description copied from interface: Memory
      Checks if the memory area is a native memory pointer.
      Specified by:
      isDirect in interface Memory
      Returns:
      true if the memory area is a native pointer.
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object