springboot一些注解

  1. @SpringBootApplication:
  2. @Configuration:
  3. @Value:
  4. @ConfigurationProperties(preifx="xxx"):下面的属性根据配置文件中变量名或方法名自动注入
  5. @ComponentScan:自动扫描本包下面的东西
  6. @Bean :如果类没有@Configuration会有很大的区别,据说是多例,如果有的话就是生成一个代理对象。
  7. @RestController:
  8. @Controller:
  9. @ResponseBody:
  10. @RequestBody:
  11. @MapperScan:扫包
  12. @Runwith(SpringRunner.class)
  13. @SpringBaootTest
  14. @RequestMapping
  15. @GetMapping
  16. @DeleteMapping
  17. PostMapping
  18. PutMapping 修改
  19. @PathVariable
  20. @PointCut
  21. @Aspect
  22. @ComponentScan
  23. @Autowired
  24. @Resource
  25. @After
  26. @Before
  27. @Around
  28. @Scope
  29. @EnableScheduling
  30. @Scheduled配合上面最定时器
  31. @ControllerAdvice
  32. @ExceptionHandler异常处理.
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值