I need to customize the Y/N chars in YesNoType so I ended up doing a
extends AbstractSingleColumnStandardBasicType<Boolean> implements PrimitiveType<Boolean>, DiscriminatorType<Boolean>
and passing along a new BooleanTypeDescriptor in the super-constructor and overloading ObjectToSQLString just like YesNoType does
Question 1: Is this the recommended approach? There is no way to extend YesNoType anymore?
Then I'd like to use Envers with it and it likes to work with UserType so I add an implements UserType and end up with anothe 10 or so methods to implement
Question 2: Is there no simpler way of doing this? Is the UserType so different from the normal type implementation hierarchy on purpose or am I missing something? I initialliy thought I would just extend YesNoType, override the yes and no values used add implements UserType and have the interface methods already implemented by the YesNoType hierarchy but apparently not
Thanks in advance, Nik
|