Package org.lwjgl

# Class PointerWrapperAbstract

java.lang.Object
org.lwjgl.PointerWrapperAbstract

All Implemented Interfaces:
  `PointerWrapper`

Direct Known Subclasses:
  `AMDDebugOutputCallback`, `ARBDebugOutputCallback`, `CLBuildProgramCallback`, `CLCommandQueue`, `CLCompileProgramCallback`, `CLContext`, `CLContextCallback`, `CLDevice`, `CLEvent`, `CLEventCallback`, `CLKernel`, `CLLinkProgramCallback`, `CLMem`, `CLMemObjectDestructorCallback`, `CLNativeKernel`, `CLPlatform`, `CLPrintfCallback`, `CLProgram`, `CLSampler`, `EGLConfig`, `EGLContext`, `EGLDisplay`, `EGLImageOES`, `EGLSurface`, `EGLSyncKHR`, `EGLSyncNV`, `GLSync`, `GLSync`, `KHRDebugCallback`, `KHRDebugCallback`

public abstract class PointerWrapperAbstract extends Object implements PointerWrapper
Base PointerWrapper implementation.

Author:
  Spasi

## Field Summary

Fields
Modifier and Type
Field
Description
`protected final long`
`pointer`

## Constructor Summary

Constructors
Modifier
Constructor
Description
`protected`
`PointerWrapperAbstract(long pointer)`

## Method Summary

Modifier and Type
Method
Description
`final void`
`checkValid()`
Checks if the pointer is valid and throws an IllegalStateException if it is not.
`boolean`
`equals(Object o)`
`final long`
`getPointer()`
`int`
`hashCode()`
`boolean`
`isValid()`
Returns true if this object represents a valid pointer.
`String`
`toString()`

### Methods inherited from class java.lang.Object

`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

## Field Details

### pointer

protected final long pointer

## Constructor Details

### PointerWrapperAbstract

protected PointerWrapperAbstract(long pointer)

## Method Details

### isValid

public boolean isValid()
Returns true if this object represents a valid pointer. The pointer might be invalid because it is NULL or because some other action has deleted the object that this pointer represents.

Returns:
  true if the pointer is valid

### checkValid

public final void checkValid()
Checks if the pointer is valid and throws an IllegalStateException if it is not. This method is a NO-OP, unless the org.lwjgl.util.Debug property has been set to true.

### getPointer

public final long getPointer()

Specified by:
  `getPointer` in interface `PointerWrapper`

### equals

public boolean equals(Object o)

Overrides:
  `equals` in class `Object`

### hashCode

public int hashCode()

Overrides:
  `hashCode` in class `Object`

### toString

public String toString()

Overrides:
  `toString` in class `Object`