views:

38

answers:

0

Hi,

I'd like to set polymorphism="explicit" property to several hibernate mapping classes. is it possible to override the default implicit value, so that I do not need to set explicit in multiple classes?

<class name="xxxxx" table="XXXXX" polymorphism="explicit">

I am using hibernate mapping xml files (No annotations or JPA) and it was loaded by Spring as follows,

<bean id="xxxsessionFactory"   class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
    <property name="dataSource">
        <ref bean="xxxDataSource"/>
    </property>
    <property name="mappingResources">
        <list>
            <value>xxx.hbm.xml</value>
            --------
            --------
        </list>
    </property>
    <property name="hibernateProperties">
        <props>
            <prop key="hibernate.dialect">org.hibernate.dialect.OracleDialect</prop>
            ----
            ----
        </props>
    </property>
</bean>

Thank you.