Class ArrayPools

java.lang.Object
net.dermetfan.gdx.utils.ArrayPools

public class ArrayPools
extends java.lang.Object
stores a map of ArrayPools (usually ReflectionArrayPool) for convenient static access
Since:
0.11.1
  • Method Summary

    Modifier and Type Method Description
    static void free​(float[] array)  
    static void free​(int[] array)  
    static <T> void free​(T[] array)  
    static <T> ArrayPool<T> get​(java.lang.Class<T> type)
    calls get(Class, int, int) with a max size of -1 (no max size) and a maxEach size of 100
    static <T> ArrayPool<T> get​(java.lang.Class<T> type, int max, int maxEach)
    note the max and maxEach sizes are ignored if this is not the first time this pool has been requested
    static FloatArrayPool getFloats()  
    static FloatArrayPool getFloats​(int max, int maxEach)  
    static IntArrayPool getInts()  
    static IntArrayPool getInts​(int max, int maxEach)  
    static <T> T[] obtain​(java.lang.Class<T> type, int length)  
    static float[] obtainFloats​(int length)  
    static int[] obtainInts​(int length)  
    static <T> void set​(java.lang.Class<T> type, ArrayPool<T> pool)  
    static void set​(FloatArrayPool pool)  
    static void set​(IntArrayPool pool)  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait