ICode9

精准搜索请尝试: 精确搜索
  • CommandLineRunner和@PostConstruct区别2022-07-20 08:01:09

    实现CommandLineRunner接口;容器启动之后,加载实现类的逻辑资源,已达到完成资源初始化的任务; @PostConstruct;在具体Bean的实例化过程中执行,@PostConstruct注解的方法,会在构造方法之后执行; @Componentpublic class TestRun implements CommandLineRunner { @Override public vo

专注分享技术,共同学习,共同进步。侵权联系[81616952@qq.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有