Class LocalDatabaseFileServiceProducer

java.lang.Object
fr.paris.lutece.plugins.newsletter.service.LocalDatabaseFileServiceProducer

@ApplicationScoped public class LocalDatabaseFileServiceProducer extends Object
CDI producer for the newsletter file store provider. Replaces the Spring XML bean localDatabaseFileService which wrapped the core LocalDatabaseFileService store with a named FileStoreServiceProvider.
  • Constructor Details

    • LocalDatabaseFileServiceProducer

      public LocalDatabaseFileServiceProducer()
  • Method Details

    • produceNewsletterDatabaseFileProvider

      @Produces @ApplicationScoped @Named("newsletterDatabaseFileProvider") public fr.paris.lutece.portal.service.file.IFileStoreServiceProvider produceNewsletterDatabaseFileProvider(String providerName, boolean isDefault, String fileStoreImplName, String downloadImplName, String rbacImplName)
      Produces the newsletter file store provider. The referenced store, download and RBAC services are resolved by name at runtime via CdiHelper.getReference(java.lang.reflect.Type, java.lang.String), so operators can swap implementations through the plugin properties file.
      Parameters:
      providerName - The logical name of this provider (matches the newsletter.FileProviderStore property)
      isDefault - Whether this provider is the default file store
      fileStoreImplName - The CDI bean name of the backing IFileStoreService
      downloadImplName - The CDI bean name of the IFileDownloadUrlService
      rbacImplName - The CDI bean name of the IFileRBACService
      Returns:
      The configured file store provider