Class UnsupportedTypeConverter

java.lang.Object
org.fastnate.generator.converter.UnsupportedTypeConverter
All Implemented Interfaces:
ValueConverter<Object>

public class UnsupportedTypeConverter extends Object implements ValueConverter<Object>
Converter used for all types that we can't convert. Used to generate a lazy exception - only if someone fills a property of unsupported type, we need to throw an exception.
Author:
Tobias Liefke
  • Constructor Details

    • UnsupportedTypeConverter

      public UnsupportedTypeConverter(String attributeName)
  • Method Details

    • getExpression

      public ColumnExpression getExpression(Object value, GeneratorContext context)
      Description copied from interface: ValueConverter
      Builds the expression for writing the given value into an SQL clause.
      Specified by:
      getExpression in interface ValueConverter<Object>
      Parameters:
      value - the current value
      context - the current context (contains the database dialect).
      Returns:
      the expression (that is including surrounding ' for string literals)