Package org.ehcache.config
Interface ResourceType<T extends ResourcePool>
- Type Parameters:
T- associatedResourcePooltype
- All Known Implementing Classes:
ResourceType.Core,ResourceType.SharedResource
public interface ResourceType<T extends ResourcePool>
A resource type.
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumAn enumeration of coreResourceTypes in Ehcache.static classResourceType.SharedResource<T extends ResourceType<?>> -
Method Summary
Modifier and TypeMethodDescriptionGets theResourcePooltype associated with thisResourceType.intIndicates the level this resource sits in the tiering system.booleanIndicates whether thisResourceTypesupports persistence.booleanIndicates whether thisResourceTyperequiresserializationsupport.
-
Method Details
-
getResourcePoolClass
Gets theResourcePooltype associated with thisResourceType.- Returns:
- the
ResourcePooltype associated with this type
-
isPersistable
boolean isPersistable()Indicates whether thisResourceTypesupports persistence.Persistence in this context means that a
ResourcePoolof thisResourceTypecan be configured so that data stored in it will survive a JVM restart.- Returns:
trueif it supports persistence,falseotherwise
-
requiresSerialization
boolean requiresSerialization()Indicates whether thisResourceTyperequiresserializationsupport.- Returns:
trueif serializers are required,falseotherwise
-
getTierHeight
int getTierHeight()Indicates the level this resource sits in the tiering system.Higher means resource is faster and less abundant, lower means resource is slower but potentially larger.
- Returns:
- the resource tier height
-