Resource

interface Resource<Z>

A resource interface that wraps a particular type so that it can be pooled and reused.

Parameters

<Z>

The type of resource wrapped by this class.

Functions

Link copied to clipboard
abstract fun get(): Z
Returns an instance of the wrapped resource.
Link copied to clipboard
abstract fun getResourceClass(): Class<Z>
Returns the Class of the wrapped resource.
Link copied to clipboard
abstract fun getSize(): Int
Returns the size in bytes of the wrapped resource to use to determine how much of the memory cache this resource uses.
Link copied to clipboard
abstract fun recycle()
Cleans up and recycles internal resources.

Inheritors

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard