1 Star 0 Fork 156

南风不竞 / Spring-Analysis

forked from huifer / Code-Analysis 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
Spring-PlaceholderResolver.md 755 Bytes
一键复制 编辑 原始数据 按行查看 历史
huifer 提交于 2020-11-09 10:08 . :fire:doc: env + PropertyResolver

Spring PlaceholderResolver

  • 类全路径: org.springframework.util.PropertyPlaceholderHelper.PlaceholderResolver

  • 类作用将占位符中的内容替换成属性值.

    • 假设现有属性表: user.dir = c:\home 传入参数 user.dir 会获得 c:\home

	@FunctionalInterface
	public interface PlaceholderResolver {

		/**
		 * Resolve the supplied placeholder name to the replacement value.
		 * @param placeholderName the name of the placeholder to resolve
		 * @return the replacement value, or {@code null} if no replacement is to be made
		 */
		@Nullable
		String resolvePlaceholder(String placeholderName);
	}
  • 类图如下

PropertyPlaceholderConfigurerResolver

Java
1
https://gitee.com/limengcanyu/spring-analysis.git
git@gitee.com:limengcanyu/spring-analysis.git
limengcanyu
spring-analysis
Spring-Analysis
master

搜索帮助