Class CryptodocSwitchableApplicationContextFactory

  • All Implemented Interfaces:
    java.util.EventListener, ApplicationContextFactory, PropertyBackedBean, PropertyBackedBeanState, org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanNameAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean, org.springframework.context.ApplicationContextAware, org.springframework.context.ApplicationListener<org.springframework.context.ApplicationEvent>

    public class CryptodocSwitchableApplicationContextFactory
    extends SwitchableApplicationContextFactory
    SwitchableApplicationContextFactory that only allows the subsystem to be switched if the current subsystem is the unencrypted content store. When an attempt is made to switch away from any other store (e.g. the encrypted store) then nothing happens. This is achieved by returning false for isUpdateable(String) calls when the current sourceBeanName is that of the unencrypted content store's subsystem.
    Author:
    Matt Ward
    • Constructor Detail

      • CryptodocSwitchableApplicationContextFactory

        public CryptodocSwitchableApplicationContextFactory()
    • Method Detail

      • setUnencryptedContentStoreBeanName

        public void setUnencryptedContentStoreBeanName​(java.lang.String unencryptedContentStoreBeanName)
        The bean name of the unencrypted ContentStore subsystem.
        Parameters:
        unencryptedContentStoreBeanName - String
      • getEncryptedContentStoreBeanName

        public java.lang.String getEncryptedContentStoreBeanName()
      • setEncryptedContentStoreBeanName

        public void setEncryptedContentStoreBeanName​(java.lang.String encryptedContentStoreBeanName)
      • onApplicationEvent

        public void onApplicationEvent​(org.springframework.context.ApplicationEvent event)
        Description copied from class: AbstractPropertyBackedBean
        Specified by:
        onApplicationEvent in interface org.springframework.context.ApplicationListener<org.springframework.context.ApplicationEvent>
        Overrides:
        onApplicationEvent in class AbstractPropertyBackedBean