Permalink
Switch branches/tags
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
168 lines (143 sloc) 11.3 KB
<?xml version='1.0' encoding='UTF-8'?>
<!--
Copyright 2016 - 2018 Acosix GmbH
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">
<bean id="${moduleId}-css.theme.handler-postProcessor" abstract="true"
class="${common.artifactId}.spring.ImplementationClassReplacingBeanDefinitionRegistryPostProcessor">
<property name="enabledPropertyKey" value="${moduleId}.surf.stateSafeCssThemeHandler.enabled" />
<property name="propertiesSource" ref="global-properties" />
<property name="targetBeanName" value="css.theme.handler" />
</bean>
<bean id="${moduleId}.stateSafeExternalLessCssThemeHandlerPatchVariant1" parent="${moduleId}-css.theme.handler-postProcessor">
<property name="originalClassName" value="org.springframework.extensions.surf.CssThemeHandler" />
<property name="replacementClassName" value="${project.artifactId}.surf.StateSafeCssThemeHandler" />
</bean>
<bean id="${moduleId}.stateSafeExternalLessCssThemeHandlerPatchVariant2" parent="${moduleId}-css.theme.handler-postProcessor">
<property name="originalClassName" value="org.springframework.extensions.surf.HybridCssThemeHandler" />
<property name="replacementClassName" value="${project.artifactId}.surf.StateSafeHybridCssThemeHandler" />
</bean>
<bean id="${moduleId}.stateSafeExternalLessCssThemeHandlerPatchVariant3" parent="${moduleId}-css.theme.handler-postProcessor">
<property name="originalClassName" value="org.springframework.extensions.surf.LessForJavaCssThemeHandler" />
<property name="replacementClassName" value="${project.artifactId}.surf.StateSafeLessForJavaCssThemeHandler" />
</bean>
<bean id="${moduleId}.stateSafeExternalLessCssThemeHandlerPatchVariant4" parent="${moduleId}-css.theme.handler-postProcessor">
<property name="originalClassName" value="org.springframework.extensions.surf.ExternalLessCssThemeHandler" />
<property name="replacementClassName" value="${project.artifactId}.surf.StateSafeExternalLessCssThemeHandler" />
</bean>
<bean id="${moduleId}.jLesscCssThemeHandlerPatchVariant1" parent="${moduleId}-css.theme.handler-postProcessor">
<property name="enabledPropertyKey" value="${moduleId}.surf.jlesscCssThemeHandler.enabled" />
<property name="originalClassName" value="org.springframework.extensions.surf.CssThemeHandler" />
<property name="replacementClassName" value="${project.artifactId}.surf.JLesscCssThemeHandler" />
</bean>
<bean id="${moduleId}.jLesscCssThemeHandlerPatchVariant2" parent="${moduleId}-css.theme.handler-postProcessor">
<property name="enabledPropertyKey" value="${moduleId}.surf.jlesscCssThemeHandler.enabled" />
<property name="originalClassName" value="${project.artifactId}.surf.StateSafeCssThemeHandler" />
<property name="replacementClassName" value="${project.artifactId}.surf.JLesscCssThemeHandler" />
</bean>
<bean id="${moduleId}.jLesscCssThemeHandlerPatchVariant3" parent="${moduleId}-css.theme.handler-postProcessor">
<property name="enabledPropertyKey" value="${moduleId}.surf.jlesscCssThemeHandler.enabled" />
<property name="originalClassName" value="org.springframework.extensions.surf.HybridCssThemeHandler" />
<property name="replacementClassName" value="${project.artifactId}.surf.JLesscCssThemeHandler" />
</bean>
<bean id="${moduleId}.jLesscCssThemeHandlerPatchVariant4" parent="${moduleId}-css.theme.handler-postProcessor">
<property name="enabledPropertyKey" value="${moduleId}.surf.jlesscCssThemeHandler.enabled" />
<property name="originalClassName" value="${project.artifactId}.surf.StateSafeHybridCssThemeHandler" />
<property name="replacementClassName" value="${project.artifactId}.surf.JLesscCssThemeHandler" />
</bean>
<bean id="${moduleId}.jLesscCssThemeHandlerPatchVariant5" parent="${moduleId}-css.theme.handler-postProcessor">
<property name="enabledPropertyKey" value="${moduleId}.surf.jlesscCssThemeHandler.enabled" />
<property name="originalClassName" value="org.springframework.extensions.surf.LessForJavaCssThemeHandler" />
<property name="replacementClassName" value="${project.artifactId}.surf.JLesscCssThemeHandler" />
</bean>
<bean id="${moduleId}.jLesscCssThemeHandlerPatchVariant6" parent="${moduleId}-css.theme.handler-postProcessor">
<property name="enabledPropertyKey" value="${moduleId}.surf.jlesscCssThemeHandler.enabled" />
<property name="originalClassName" value="${project.artifactId}.surf.StateSafeLessForJavaCssThemeHandler" />
<property name="replacementClassName" value="${project.artifactId}.surf.JLesscCssThemeHandler" />
</bean>
<bean id="${moduleId}.jLesscCssThemeHandlerPatchVariant7" parent="${moduleId}-css.theme.handler-postProcessor">
<property name="enabledPropertyKey" value="${moduleId}.surf.jlesscCssThemeHandler.enabled" />
<property name="originalClassName" value="org.springframework.extensions.surf.ExternalLessCssThemeHandler" />
<property name="replacementClassName" value="${project.artifactId}.surf.JLesscCssThemeHandler" />
</bean>
<bean id="${moduleId}.jLesscCssThemeHandlerPatchVariant8" parent="${moduleId}-css.theme.handler-postProcessor">
<property name="enabledPropertyKey" value="${moduleId}.surf.jlesscCssThemeHandler.enabled" />
<property name="originalClassName" value="${project.artifactId}.surf.StateSafeExternalLessCssThemeHandler" />
<property name="replacementClassName" value="${project.artifactId}.surf.JLesscCssThemeHandler" />
</bean>
<!-- better detection of widget configs -->
<!-- this supports single- and multi-widget configs -->
<!-- this allows use of single quotes in addition to double-quotes -->
<!-- this supports variables and members -->
<!-- this supports aggregated variable / member names -->
<bean id="${moduleId}.betterWidgetDependenciesRegexPatch" class="${common.artifactId}.spring.PropertyAlteringBeanFactoryPostProcessor">
<property name="targetBeanName" value="define.dojo.widgets.dependency.rule" />
<property name="propertyName" value="declarationRegex" />
<property name="value"
value="[&quot;']?(?:_+)?(?:widgets?|[\w]+Widgets?|widgets?[A-Z]\w+)(?:_+)?[&quot;']?[^:=]*?[:=][\r\s\t\n]*\[?(\{(.*)\})\]?" />
<property name="enabled" value="\${${moduleId}.surf.betterRegexDojoWidgetsRule.enabled}" />
</bean>
<!-- better detection of CSS dependency configs -->
<!-- this allows use of single quotes in addition to double-quotes -->
<!-- this allows different source styling with whitespace leniency -->
<!-- this supports detection in JSON model in addition to in JS files -->
<bean id="${moduleId}.betterWidgetCSSFileRegexPatch" class="${common.artifactId}.spring.PropertyAlteringBeanFactoryPostProcessor">
<property name="targetBeanName" value="define.dojo.css.dependency.rule.abstract" />
<property name="propertyName" value="dependencyRegex" />
<property name="value"
value="[&quot;']?cssFile[&quot;']?:[\r\s\t\n]*[&quot;'](.*?)[&quot;']([\r\s\t\n]*,[\r\s\t\n]*[&quot;']?mediaType[&quot;']?:[\r\s\t\n]*[&quot;'](.*?)[&quot;'])?" />
<property name="enabled" value="\${${moduleId}.surf.betterRegexDojoCSSDependencyRule.enabled}" />
</bean>
<bean id="${moduleId}.betterWidgetCSSRequirementsRegexPatch" class="${common.artifactId}.spring.PropertyAlteringBeanFactoryPostProcessor">
<property name="targetBeanName" value="define.dojo.css.dependency.rule.abstract" />
<property name="propertyName" value="declarationRegex" />
<property name="value"
value="([&quot;']?cssRequirements[&quot;']?:[\r\s\t\n]*\[[\r\s\t\n]*\{(.*)\}[\r\s\t\n]*\])" />
<property name="enabled" value="\${${moduleId}.surf.betterRegexDojoCSSDependencyRule.enabled}" />
</bean>
<bean id="${moduleId}.jsonAwareWidgetsDependencyRulePatch" class="${common.artifactId}.spring.ImplementationClassReplacingBeanFactoryPostProcessor">
<property name="targetBeanName" value="define.dojo.widgets.dependency.rule" />
<property name="originalClassName" value="org.springframework.extensions.surf.DojoWidgetsDependencyRule" />
<property name="replacementClassName" value="${project.artifactId}.surf.JSONAwareWidgetsDependencyRule" />
<property name="enabled" value="\${${moduleId}.surf.jsonAwareDojoWidgetsRule.enabled}" />
</bean>
<bean id="${moduleId}.jsonAwareCssDependencyRulePatch" class="${common.artifactId}.spring.ImplementationClassReplacingBeanFactoryPostProcessor">
<property name="targetBeanName" value="define.dojo.css.dependency.rule" />
<property name="originalClassName" value="org.springframework.extensions.surf.DojoCssDependencyRule" />
<property name="replacementClassName" value="${project.artifactId}.surf.JSONAwareCssDependencyRule" />
<property name="enabled" value="\${${moduleId}.surf.jsonAwareDojoCssRule.enabled}" />
</bean>
<bean id="${moduleId}-ExtensibleDeclarativeWebScriptPatch" class="${common.artifactId}.spring.ImplementationClassReplacingBeanFactoryPostProcessor">
<property name="enabled" value="\${${moduleId}.web.scripts.correctScriptCustomizationLookup.enabled}" />
<property name="targetBeanName" value="webscript.default" />
<!-- this should be the default -->
<property name="originalClassName" value="org.springframework.extensions.webscripts.DeclarativeWebScript" />
<property name="replacementClassName" value="${common.artifactId}.web.scripts.ExtensibleDeclarativeWebScript" />
</bean>
<bean id="${moduleId}-ExtensibilityFixedWebscriptRuntimeContainerPatch" class="${common.artifactId}.spring.ImplementationClassReplacingBeanFactoryPostProcessor">
<property name="enabled" value="\${${moduleId}.web.scripts.extensibilityFixedLocalWebScriptRuntimeContainer.enabled}" />
<property name="targetBeanName" value="webscripts.container" />
<!-- this should be the default -->
<property name="originalClassName" value="org.springframework.extensions.webscripts.LocalWebScriptRuntimeContainer" />
<property name="replacementClassName" value="${project.artifactId}.surf.ExtensibilityFixedLocalWebScriptRuntimeContainer" />
</bean>
<bean class="org.alfresco.i18n.ResourceBundleBootstrapComponent">
<property name="resourceBundles">
<list>
<value>alfresco.messages.${messages.packageId}.labels</value>
</list>
</property>
</bean>
</beans>