Class PrimefacesFileUploadServletContextAutoConfiguration
java.lang.Object
org.joinfaces.autoconfigure.primefaces.PrimefacesFileUploadServletContextAutoConfiguration
@Configuration(proxyBeanMethods=false)
@ConditionalOnClass(org.primefaces.webapp.filter.FileUploadFilter.class)
@ConditionalOnWebApplication(type=SERVLET)
@AutoConfigureAfter(JakartaFaces3AutoConfiguration.class)
@EnableConfigurationProperties(PrimefacesFileUploadFilterProperties.class)
public class PrimefacesFileUploadServletContextAutoConfiguration
extends Object
FileUploadFilter
bean is needed for requests to be wrapped as a
MultipartRequest
.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.boot.web.servlet.FilterRegistrationBean<org.primefaces.webapp.filter.FileUploadFilter>
primefacesFileUploadFilterRegistrationBean
(PrimefacesFileUploadFilterProperties uploadFilterProperties, ObjectProvider<org.springframework.boot.web.servlet.ServletRegistrationBean<FacesServlet>> facesServletRegistrationBean) File upload filter is required only if commons fileupload is chosen.
-
Constructor Details
-
PrimefacesFileUploadServletContextAutoConfiguration
public PrimefacesFileUploadServletContextAutoConfiguration()
-
-
Method Details
-
primefacesFileUploadFilterRegistrationBean
@Bean @ConditionalOnProperty(value="joinfaces.primefaces.uploader", havingValue="commons") @ConditionalOnClass(name="org.apache.commons.fileupload.servlet.ServletFileUpload") public org.springframework.boot.web.servlet.FilterRegistrationBean<org.primefaces.webapp.filter.FileUploadFilter> primefacesFileUploadFilterRegistrationBean(PrimefacesFileUploadFilterProperties uploadFilterProperties, ObjectProvider<org.springframework.boot.web.servlet.ServletRegistrationBean<FacesServlet>> facesServletRegistrationBean) File upload filter is required only if commons fileupload is chosen.- Parameters:
uploadFilterProperties
-ConfigurationProperties
object for theFileUploadFilter
.facesServletRegistrationBean
-RegistrationBean
for theFacesServlet
, if available.- Returns:
- file upload filter
-