当前位置:网站首页>idea 方法注释:自定义修改method的return和params,void不显示
idea 方法注释:自定义修改method的return和params,void不显示
2022-08-11 08:30:00 【hhkun0120】
/** 演示有参数返回void
* <p>
*
* </p>
*
* @param a a
* @param b b
* @author hk2018
* @since 2020/5/21
*/
public void x(int a, String b){
System.out.println("dd");
}
/** 演示无参数返回void
* <p>
*
* </p>
*
* @author hk2018
* @since 2020/5/21
*/
public void x1(){
System.out.println("dd");
}
**
* <p>
*
* </p>
* $param$$returns$
* @author hk2018
* @since $date$
*/
下面为脚本
groovyScript("def result=' \\n'; def params=\"${_1}\".replaceAll('[\\\\[|\\\\]|\\\\s]', '').split(',').toList(); for(i = 0; i < params.size(); i++) {if(params[i] == '') return ''; result+=' * @param ' + params[i] + ' ' + params[i] + ((i < params.size() - 1) ? ' \\n' : '')}; return result", methodParameters())
returns脚本
groovyScript("if(\"${_1}\" == 'void') {return ;} else { def returnType = \"${_1}\"; def result = ' @return: ' + returnType; return result;}", methodReturnType());
边栏推荐
猜你喜欢
研发了 5 年的时序数据库,到底要解决什么问题?
Active users of mobile banking grew rapidly in June, hitting a half-year high
几何EX3 功夫牛宣布停售,入门级纯电产品为何总成弃子
如何通过开源数据库管理工具 DBeaver 连接 TDengine
Write a resume like this, easy to get the interviewer
C Primer Plus(6) 中文版 第1章 初识C语言 1.7 使用C语言的7个步骤
囍楽cloud task source code
3.1-Classification-probabilistic generative model
LoRa芯片的特征
Unity3D - modification of the Inspector panel of the custom class
随机推荐
Filesystem Hierarchy Standard
flex布局回顾
Redis 只会用缓存?20种妙用让同事直呼牛X(荣耀典藏版)
通过记账,了解当月收支情况
【LeetCode】Summary of linked list problems
FPGA 20个例程篇:11.USB2.0接收并回复CRC16位校验
nodejs微服务中跨域,请求,接口,参数拦截等功能
【实战系列】OpenApi设计规范
机器学习(三)多项式回归
场地预订系统,帮助场馆提高坪效
mysql添加用户以及设置权限
RestTemplate工具类
快速幂,逆元的求解
《剑指offer》题解——week3(持续更新)
支持各种文件快速重命名最简单的小技巧
小目标检测3_注意力机制_Self-Attention
Interview questions about Android Service
Square, multi-power, square root calculation in Tf
1.2 - error sources
研发了 5 年的时序数据库,到底要解决什么问题?