public interface ConditionalDirectCopyTransformersManager
<bean id="blCommonConditionalDirectCopyTransformerMember" class="org.broadleafcommerce.common.weave.ConditionalDirectCopyTransformMemberDto">
<property name="templateTokens">
<util:constant static-field="org.broadleafcommerce.common.extensibility.jpa.copy.DirectCopyTransformTypes.MULTITENANT_SITE"/>
</property>
<property name="conditionalProperty" value="enable.site.map.mt.disc"/>
</bean>
<bean id="blCommonConditionalDirectCopyTransformers" class="org.springframework.beans.factory.config.MapFactoryBean">
<property name="sourceMap">
<map>
<entry key="org.broadleafcommerce.common.sitemap.domain.SiteMapGeneratorConfigurationImpl" value-ref="blCommonConditionalDirectCopyTransformerMember"/>
</map>
</property>
</bean>
<bean class="org.broadleafcommerce.common.extensibility.context.merge.EarlyStageMergeBeanPostProcessor">
<property name="collectionRef" value="blCommonConditionalDirectCopyTransformers"/>
<property name="targetRef" value="blConditionalDirectCopyTransformers"/>
</bean>
The goal is to add configuration for one or more entities and then add that configuration to the "blConditionalDirectCopyTransformers" map in
Spring. The activity of this configuration will remain dormant until the "conditionalProperty" is defined and set to true in the implementation's
Spring property files (or override property file). At that point, based on the type of templateTokens defined, Hibernate will
expect to find and utilize the new columns in the database associated with those templateTokens.Modifier and Type | Method and Description |
---|---|
ConditionalDirectCopyTransformMemberDto |
getTransformMember(String entityName)
Retrieve the direct copy transform config info
|
Boolean |
isEntityEnabled(String entityName)
Based on the entity name, this method will determine if the associated conditionalProperty from the Spring configuration is true.
|
Boolean isEntityEnabled(String entityName)
entityName
- ConditionalDirectCopyTransformMemberDto getTransformMember(String entityName)
entityName
- Copyright © 2022. All rights reserved.