|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.jooq.impl.EnumConverter<T,U>
public class EnumConverter<T,U extends Enum<U>>
A base class for enum conversion.
| Constructor Summary | |
|---|---|
EnumConverter(Class<T> fromType,
Class<U> toType)
|
|
| Method Summary | |
|---|---|
U |
from(T databaseObject)
Convert a database object to a user object |
Class<T> |
fromType()
The database type |
T |
to(U userObject)
Subclasses may override this method to provide a custom reverse mapping implementation Convert a user object to a database object |
Class<U> |
toType()
The user type |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public EnumConverter(Class<T> fromType,
Class<U> toType)
| Method Detail |
|---|
public final U from(T databaseObject)
Converter
from in interface Converter<T,U extends Enum<U>>databaseObject - The database object
public T to(U userObject)
Convert a user object to a database object
to in interface Converter<T,U extends Enum<U>>userObject - The user object
public final Class<T> fromType()
Converter
fromType in interface Converter<T,U extends Enum<U>>public final Class<U> toType()
Converter
toType in interface Converter<T,U extends Enum<U>>
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||