SpringBoot Initializr

Introspector(内省)

class TestReflect {
@Test
fun testReflect() {
//获取字节码对象
val clazz = Product::class.java
//创建实体对象
val product = clazz.newInstance()
//获取声明的字段
val fields = clazz.declaredFields
/* val writeMethodName = "set${it.name.substring(0, 1).toUpperCase()}${it.name.substring(1)}"
println(writeMethodName)
val writeMethod = clazz.getDeclaredMethod(writeMethodName, it.type)
writeMethod.invoke(product,13)*/ //通过Introspector获取javaBean信息
val beanInfo = Introspector.getBeanInfo(clazz)
//通过beanInfo获取到所有的属性描述,遍历获取它们的set方法
beanInfo.propertyDescriptors.forEach {
println(it.writeMethod)
}
}

Hikari

file and code templates

Setting-----Editor-----Class

常用资讯网站

https://toutiao.io

csdn,简书,小红书,掘金,stackoverflow,androidWeekly,https://segmentfault.com/

最新文章

  1. 2次使用fork避免产生僵尸进程和不去处理SIGCHLD信号
  2. Coursera-Getting and Cleaning Data-Week2-课程笔记
  3. Opensource开源精神
  4. 自定义select控件开发
  5. CoreException: Could not calculate build plan: Plugin org.apache.maven.plugins:maven-compiler-plugin:3.1 or one of its dependencies could not be resolved
  6. iOS-appDelegate 生命周期
  7. Unity加入Android广告小结
  8. Graphviz-Gdot语言学习
  9. vim配置(vimplus)
  10. [Unity AssetBundle]Asset资源处理
  11. 【前端】一步一步使用webpack+react+scss脚手架重构项目
  12. Android学习笔记-TextView(文本框)(二)
  13. ubuntu 常用命令集
  14. BitCoin p2p通信过程
  15. 错误 103 未能加载文件或程序集“Telerik.Web.UI”或它的某一个依赖项。磁盘空间不足。 (异常来自 HRESULT:0x80070070)
  16. 关键字(7):属性的增删改add,drop,modify
  17. abap test msg
  18. spring quartz执行两次问题
  19. P2-Centos中安装vsftpd
  20. 使用SQL语句如何实现条件判断

热门文章

  1. P1089 津津的储蓄计划
  2. 2017.10.6 Java命名规范及使用情况
  3. cudaMemcpy2D介绍
  4. vue 城市搜索组件
  5. C/C++获取本机名+本机IP+本机MAC
  6. Codeforces#498F. Xor-Paths(折半搜索)
  7. 查询删除的SAP凭证
  8. kubernetes基础架构及原理
  9. 在ubuntu上安装subline
  10. 《python编程从入门到实践》第七章笔记