discriminatorInsertable = entityBinding.getHierarchyDetails().getEntityDiscriminator().isInserted()
&& ! DerivedValue.class.isInstance( discriminatorRelationalValue );
try {
DiscriminatorType dtype = ( DiscriminatorType ) discriminatorType;
discriminatorValue = dtype.stringToObject( entityBinding.getDiscriminatorMatchValue() );
discriminatorSQLValue = dtype.objectToSQLString( discriminatorValue, factory.getDialect() );
}
catch (ClassCastException cce) {
throw new MappingException("Illegal discriminator type: " + discriminatorType.getName() );
}
catch (Exception e) {