NASA World Wind

gov.nasa.worldwind.cache
Class BasicGpuResourceCache.CacheEntry

java.lang.Object
  extended by gov.nasa.worldwind.cache.BasicGpuResourceCache.CacheEntry
All Implemented Interfaces:
Cacheable
Enclosing class:
BasicGpuResourceCache

public static class BasicGpuResourceCache.CacheEntry
extends Object
implements Cacheable


Field Summary
protected  Object resource
           
protected  long resourceSize
           
protected  String resourceType
           
 
Constructor Summary
BasicGpuResourceCache.CacheEntry(Object resource, String resourceType)
           
BasicGpuResourceCache.CacheEntry(Object resource, String resourceType, long size)
           
 
Method Summary
 long getSizeInBytes()
          Retrieves the approximate size of this object in bytes.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

resource

protected final Object resource

resourceSize

protected long resourceSize

resourceType

protected final String resourceType
Constructor Detail

BasicGpuResourceCache.CacheEntry

public BasicGpuResourceCache.CacheEntry(Object resource,
                                        String resourceType)

BasicGpuResourceCache.CacheEntry

public BasicGpuResourceCache.CacheEntry(Object resource,
                                        String resourceType,
                                        long size)
Method Detail

getSizeInBytes

public long getSizeInBytes()
Description copied from interface: Cacheable
Retrieves the approximate size of this object in bytes. Implementors are encouraged to calculate the exact size for smaller objects, but use approximate values for objects that include such large components that the approximation would produce an error so small that the extra computation would be wasteful.

Specified by:
getSizeInBytes in interface Cacheable
Returns:
this Cacheable object's size in bytes

NASA World Wind