63 Star 428 Fork 156

huifer/Code-Analysis

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
docs
beans
core
AttributeAccessor
Lifecycle
ParameterNameDiscoverer
convert
ConditionalConverter
GenericConverter
TypeConverter
images
Readme.md
Spring-ConditionalConverter.md
Spring-ConfigurableConversionService.md
Spring-ConversionService.md
Spring-Converter.md
Spring-ConverterRegistry.md
Spring-DefaultConversionService.md
Spring-DefaultFormattingConversionService.md
Spring-FormatterRegistry.md
Spring-FormattingConversionService.md
Spring-GenericConversionService.md
Spring-GenericConverter.md
Spring-TypeConverter.md
Spring-TypeDescriptor.md
io
registry
env
other
utils
release
.gitattributes
.gitignore
CHANGELOG.MD
LICENSE
Notice
README.md
_coverpage.md
index.html
summary.md
todo.md
克隆/下载
Spring-GenericConverter.md 801 Bytes
一键复制 编辑 原始数据 按行查看 历史

Spring GenericConverter

  • 类全路径: org.springframework.core.convert.converter.GenericConverter
  • 类图 GenericConverter

public interface GenericConverter {

	/**
	 * 返回对象 ConvertiblePair , ConvertiblePair 中包含了 原类型和目标类型
	 */
	@Nullable
	Set<ConvertiblePair> getConvertibleTypes();

	/**
	 * 类型转换
	 */
	@Nullable
	Object convert(@Nullable Object source, TypeDescriptor sourceType, TypeDescriptor targetType);

}

ConvertiblePair

  • 类全路径: org.springframework.core.convert.converter.GenericConverter.ConvertiblePair
	final class ConvertiblePair {
		/**
		 * 原类型
		 */
		private final Class<?> sourceType;

		/**
		 * 目标类型
		 */
		private final Class<?> targetType;
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Java
1
https://gitee.com/pychfarm_admin/code-analysis.git
git@gitee.com:pychfarm_admin/code-analysis.git
pychfarm_admin
code-analysis
Code-Analysis
v0.0.15

搜索帮助