com.atlassian.crowd.util.persistence.hibernate
Class GenericEnumUserType

java.lang.Object
  extended by com.atlassian.hibernate.extras.type.GenericEnumUserType
      extended by com.atlassian.crowd.util.persistence.hibernate.GenericEnumUserType
All Implemented Interfaces:
Serializable, org.hibernate.usertype.EnhancedUserType, org.hibernate.usertype.ParameterizedType, org.hibernate.usertype.UserType

public class GenericEnumUserType
extends com.atlassian.hibernate.extras.type.GenericEnumUserType

This class is now an alias for GenericEnumUserType from the atlassian-hibernate-extras library. It is retained in Crowd only for backward compatibility.

In addition to providing backward compatibility for the class being referenced, this class also applies the historical Crowd defaults for the identifierMethod and valueOf methods. In the base class, the defaults are "getId" and "fromId", respectively; for this class, they are "name" and "valueOf". While the defaults used here are satisfied automatically by every Java enumeration, they are weak for refactoring; renaming an enum constant requires a database upgrade task to adjust previous rows.

See Also:
Serialized Form

Field Summary
static String DEFAULT_IDENTIFIER_METHOD_NAME
           
static String DEFAULT_VALUE_OF_METHOD_NAME
           
 
Constructor Summary
GenericEnumUserType()
           
 
Method Summary
 void setParameterValues(Properties parameters)
           
 
Methods inherited from class com.atlassian.hibernate.extras.type.GenericEnumUserType
assemble, deepCopy, disassemble, equals, fromXMLString, hashCode, isMutable, nullSafeGet, nullSafeSet, objectToSQLString, replace, returnedClass, sqlTypes, toXMLString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_IDENTIFIER_METHOD_NAME

public static final String DEFAULT_IDENTIFIER_METHOD_NAME
See Also:
Constant Field Values

DEFAULT_VALUE_OF_METHOD_NAME

public static final String DEFAULT_VALUE_OF_METHOD_NAME
See Also:
Constant Field Values
Constructor Detail

GenericEnumUserType

public GenericEnumUserType()
Method Detail

setParameterValues

public void setParameterValues(Properties parameters)
Specified by:
setParameterValues in interface org.hibernate.usertype.ParameterizedType
Overrides:
setParameterValues in class com.atlassian.hibernate.extras.type.GenericEnumUserType


Copyright © 2013 Atlassian. All Rights Reserved.