Module org.jooq
Package org.jooq.impl

Class EnumConverter<T,​U extends Enum<U>>

    • Constructor Detail

      • EnumConverter

        public EnumConverter​(Class<T> fromType,
                             Class<U> toType)
    • Method Detail

      • from

        public final U from​(T databaseObject)
        Description copied from interface: Converter
        Convert a database object to a user object
        Parameters:
        databaseObject - The database object
        Returns:
        The user object
      • to

        public T to​(U userObject)
        Subclasses may override this method to provide a custom reverse mapping implementation

        Convert a user object to a database object

        Parameters:
        userObject - The user object
        Returns:
        The database object