Interface Allocator

  • All Known Implementing Classes:
    DefaultAllocator

    public interface Allocator
    A source of allocations.
    • Method Detail

      • release

        void release​(Allocation allocation)
        Releases an Allocation back to the allocator.
        Parameters:
        allocation - The Allocation being released.
      • release

        void release​(Allocation[] allocations)
        Releases an array of Allocations back to the allocator.
        Parameters:
        allocations - The array of Allocations being released.
      • trim

        void trim()
        Hints to the allocator that it should make a best effort to release any excess Allocations.
      • getTotalBytesAllocated

        int getTotalBytesAllocated()
        Returns the total number of bytes currently allocated.
      • getIndividualAllocationLength

        int getIndividualAllocationLength()
        Returns the length of each individual Allocation.