com.sleepycat.je.rep.impl
Class EnumConfigParam<T extends Enum<T>>

java.lang.Object
  extended by com.sleepycat.je.config.ConfigParam
      extended by com.sleepycat.je.rep.impl.EnumConfigParam<T>

public class EnumConfigParam<T extends Enum<T>>
extends ConfigParam

A JE configuration parameter with an enumerated value


Field Summary
 
Fields inherited from class com.sleepycat.je.config.ConfigParam
name
 
Constructor Summary
EnumConfigParam(String configName, Enum<T> defaultValue, boolean mutable, boolean forReplication, Class<T> enumClass)
           
 
Method Summary
 T getEnumerator(String enumName)
          Returns the enumerator associated with the name
 void validateValue(String value)
          Validate your value.
 
Methods inherited from class com.sleepycat.je.config.ConfigParam
getDefault, getName, isForReplication, isMultiValueParam, isMutable, multiValueParamName, mvParamIndex, setForReplication, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

EnumConfigParam

public EnumConfigParam(String configName,
                       Enum<T> defaultValue,
                       boolean mutable,
                       boolean forReplication,
                       Class<T> enumClass)
Method Detail

getEnumerator

public T getEnumerator(String enumName)
Returns the enumerator associated with the name

Parameters:
enumName - the string naming the enumerator
Returns:
the enumerator

validateValue

public void validateValue(String value)
                   throws IllegalArgumentException
Description copied from class: ConfigParam
Validate your value. (No default validation for strings.) May be overridden for (e.g.) Multi-value params.

Overrides:
validateValue in class ConfigParam
Throws:
IllegalArgumentException - via XxxConfig.setXxx methods and XxxConfig(Properties) ctor.


Copyright (c) 2004-2012 Oracle. All rights reserved.