Package org.hibernate.cache.jcache
Enum Class MissingCacheStrategy
- All Implemented Interfaces:
Serializable
,Comparable<MissingCacheStrategy>
,Constable
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionCreate a new cache when a cache is not found, without logging any warning about the missing cache.Create a new cache when a cache is not found (seeCREATE
), and also log a warning about the missing cache.Fail with an exception on missing caches. -
Method Summary
Modifier and TypeMethodDescriptionstatic MissingCacheStrategy
interpretSetting
(Object value) static MissingCacheStrategy
Returns the enum constant of this class with the specified name.static MissingCacheStrategy[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
FAIL
Fail with an exception on missing caches. -
CREATE_WARN
Create a new cache when a cache is not found (seeCREATE
), and also log a warning about the missing cache. -
CREATE
Create a new cache when a cache is not found, without logging any warning about the missing cache. Note that caches created this way may be very badly configured (unlimited size and no eviction in particular) unless the cache provider was explicitly configured to use an appropriate configuration for default caches. Ehcache in particular allows to set such default configuration using cache templates, see http://www.ehcache.org/documentation/3.0/107.html#supplement-jsr-107-configurations
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
getExternalRepresentation
-
interpretSetting
-