com.voidsearch.voidbase.apps.cache.containers
Enum CacheLockType

java.lang.Object
  extended by java.lang.Enum<CacheLockType>
      extended by com.voidsearch.voidbase.apps.cache.containers.CacheLockType
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<CacheLockType>

public enum CacheLockType
extends java.lang.Enum<CacheLockType>

Cache lock types, currently supported are - ATOMIC, GLOBAL and NONE locks where: - ATOMIC level locks on a level of key, thus guarantees atomicity of an operation - GLOBAL level locks on a level of operation blocking all other similar operations running concurrently - NONE level doesn't lock concurrent similar operations in any respect


Enum Constant Summary
ATOMIC
           
DEFAULT
           
GLOBAL
           
NONE
           
 
Method Summary
static CacheLockType deserialize(java.lang.String str)
          Initializes a CacheLockType object
 java.lang.String serialize()
          Serializes a content of a CacheLockType
static CacheLockType valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static CacheLockType[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

ATOMIC

public static final CacheLockType ATOMIC

GLOBAL

public static final CacheLockType GLOBAL

NONE

public static final CacheLockType NONE

DEFAULT

public static final CacheLockType DEFAULT
Method Detail

values

public static CacheLockType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (CacheLockType c : CacheLockType.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static CacheLockType valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null

serialize

public java.lang.String serialize()
Serializes a content of a CacheLockType

Returns:
serialized CacheLockType object

deserialize

public static CacheLockType deserialize(java.lang.String str)
Initializes a CacheLockType object

Parameters:
str -
Returns:
a new CacheLockType object from a String


Copyright © 2009. All Rights Reserved.