dextuploadjk.support.spring
Class JKServletContextAwareBean
- Minimum version
- 1.0.0
- Minimum environment
- Java 17, Spring Framework 6.0.14, Spring Boot 3.0.12
- Description
-
Utility class used to obtain a javax.servlet.ServletContext object from a servlet context XML file.
<bean id="servletContextAware" class="dextuploadjk.support.spring.JKServletContextAwareBean"/> <bean id="multipartResolver" class="dextuploadjk.support.spring.JKMultipartResolver"> <property name="environment"> <bean class="dextuploadjk.engine.Environment"> <property name="defaultRepository"> <!-- Sets the web application root/files directory as the default storage directory. --> <bean factory-bean="servletContextAware" factory-method="getRealPath"> <constructor-arg value="files"/> </bean> </property> </bean> </property> </bean> - Methods
-
getRealPath
-
Returns a physical absolute path with the given path as a relative path to the web application root location.
-
Signatures
public String getRealPath(String relative)
-
Parameters
Name Type Description relative java.lang.String Sub-path -
Return
A physical absolute path with the given path as a relative path to the web application root location.
-