net.sf.qualitytest.blueprint.strategy.creation
Class DefaultEnumCreationStrategy

java.lang.Object
  extended by net.sf.qualitytest.blueprint.strategy.creation.ValueCreationStrategy<Enum<?>>
      extended by net.sf.qualitytest.blueprint.strategy.creation.DefaultEnumCreationStrategy
All Implemented Interfaces:
CreationStrategy<Enum<?>>

public class DefaultEnumCreationStrategy
extends ValueCreationStrategy<Enum<?>>

Creation strategy which creates an enum using the first value in an enum constant.

Author:
Dominik Seichter

Constructor Summary
DefaultEnumCreationStrategy()
           
 
Method Summary
 Enum<?> createValue(Class<?> expectedClazz)
          Blueprint an enum value using the default configuration.
 
Methods inherited from class net.sf.qualitytest.blueprint.strategy.creation.ValueCreationStrategy
createValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultEnumCreationStrategy

public DefaultEnumCreationStrategy()
Method Detail

createValue

public Enum<?> createValue(Class<?> expectedClazz)
Blueprint an enum value using the default configuration. This method will return the first enum constant in the enumeration.

Specified by:
createValue in class ValueCreationStrategy<Enum<?>>
Type Parameters:
T -
Parameters:
expectedClazz - the class of an enumeration.
Returns:
a valid enum value.


Copyright © 2012-2013. All Rights Reserved.