What is the block tag in Javadoc to describe the method return value?
时间: 2023-02-14 07:28:39 浏览: 78
在 Javadoc 中,用来描述方法返回值的块标记是 `@return`。例如:
```
/**
* Returns the result of adding two integers.
*
* @param a the first integer to add
* @param b the second integer to add
* @return the result of adding a and b
*/
public int add(int a, int b) {
return a + b;
}
```
在这个示例中,`@return` 标记用来描述 `add()` 方法的返回值。
相关问题
.HttpRequestMethodNotSupportedException: Request method 'POST' is not supported]
HttpRequestMethodNotSupportedException是一个异常,表示请求方法不被支持。当客户端发送一个不被服务器支持的请求方法时,就会抛出这个异常。
解决办法可以有以下几种:
1. 确认请求方法是否正确:首先要确认请求方法是否正确,比如使用了GET方法而服务器只支持POST方法。可以通过查看请求的代码或者网络请求工具来确认请求方法是否正确。
2. 检查URL地址:有时候URL地址可能写错了,导致请求方法不匹配。可以检查URL地址是否正确。
3. 检查服务器配置:有时候服务器可能没有正确配置请求方法的支持。可以检查服务器的配置文件,比如web.xml文件,确认是否正确配置了请求方法的支持。
参考链接:
- [HttpRequestMethodNotSupportedException](https://docs.spring.io/spring-framework/docs/current/javadoc-api/org/springframework/web/HttpRequestMethodNotSupportedException.html)
You have tried to change the API from what has been previously approved. To make these errors go away, you have two choices: 1. You can add '@hide' javadoc comments (and remove @SystemApi/@TestApi/etc) to the new methods, etc. shown in the above diff. 2. You can update current.txt and/or removed.txt by executing the following command: m api-stubs-docs-non-updatable-update-current-api To submit the revised current.txt to the main Android repository, you will need approval.
这似乎是一个关于 Android API 的问题。从你的描述中看,你可能尝试更改了之前已经批准的 API,导致出现了错误。为了解决这个问题,你有两个选择:
1. 在新方法中添加 '@hide' javadoc 注释(并删除 @SystemApi/@TestApi 等),这样就可以消除这些错误。
2. 通过执行以下命令更新 current.txt 和/或 removed.txt:
m api-stubs-docs-non-updatable-update-current-api
要将修订后的 current.txt 提交到主 Android 存储库,您需要获得批准。