插件安装
Mac 安装
打开IDEA:IntelliJ IDEA - Preferences… - Plugins
Windows 安装
打开IDEA:File - Settings… - Plugins
1、搜索选择自己想要安装的插件,下载安装并重启idea客户端即可。
2、已经安装的插件默认是启用(☑️)状态,如果要禁用某个插件,只用去除勾选,点击应用并保存,同样也需要重启生效。
项目开发过程中经常会遇到页面上传回来的参数或者请求接口返回的参数是带下划线的,所以需要对参数进行转换以方便我们的使用,在这里记录下下划线命名和驼峰名相互转换。
1 |
|
如下Spring中的一个常用注解@Controller代码:1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
package org.springframework.stereotype;
import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
/**
* Indicates that an annotated class is a "Controller" (e.g. a web controller).
*
* @author Arjen Poutsma
* @author Juergen Hoeller
* @since 2.5
* @see Component
* @see org.springframework.web.bind.annotation.RequestMapping
* @see org.springframework.context.annotation.ClassPathBeanDefinitionScanner
*/
@Target({ElementType.TYPE})
@Retention(RetentionPolicy.RUNTIME)
@Documented
@Component
public @interface Controller {
/**
* The value may indicate a suggestion for a logical component name,
* to be turned into a Spring bean in case of an autodetected component.
* @return the suggested component name, if any
*/
String value() default "";
}