Remove redundant throws clauses

Removes exceptions that are declared in a method's signature but never thrown by the method itself or its implementations/derivatives.
This commit is contained in:
Lars Grefer
2019-08-23 01:03:54 +02:00
parent f0515a021c
commit 34dd5fea30
418 changed files with 1146 additions and 1273 deletions

View File

@@ -79,7 +79,7 @@ public class OAuth2AccessTokenResponseHttpMessageConverter extends AbstractHttpM
@Override
protected OAuth2AccessTokenResponse readInternal(Class<? extends OAuth2AccessTokenResponse> clazz, HttpInputMessage inputMessage)
throws IOException, HttpMessageNotReadableException {
throws HttpMessageNotReadableException {
try {
@SuppressWarnings("unchecked")
@@ -94,7 +94,7 @@ public class OAuth2AccessTokenResponseHttpMessageConverter extends AbstractHttpM
@Override
protected void writeInternal(OAuth2AccessTokenResponse tokenResponse, HttpOutputMessage outputMessage)
throws IOException, HttpMessageNotWritableException {
throws HttpMessageNotWritableException {
try {
Map<String, String> tokenResponseParameters = this.tokenResponseParametersConverter.convert(tokenResponse);

View File

@@ -67,7 +67,7 @@ public class OAuth2ErrorHttpMessageConverter extends AbstractHttpMessageConverte
@Override
protected OAuth2Error readInternal(Class<? extends OAuth2Error> clazz, HttpInputMessage inputMessage)
throws IOException, HttpMessageNotReadableException {
throws HttpMessageNotReadableException {
try {
@SuppressWarnings("unchecked")
@@ -82,7 +82,7 @@ public class OAuth2ErrorHttpMessageConverter extends AbstractHttpMessageConverte
@Override
protected void writeInternal(OAuth2Error oauth2Error, HttpOutputMessage outputMessage)
throws IOException, HttpMessageNotWritableException {
throws HttpMessageNotWritableException {
try {
Map<String, String> errorParameters = this.errorParametersConverter.convert(oauth2Error);

View File

@@ -97,7 +97,7 @@ public class OAuth2BodyExtractorsTests {
}
@Test
public void oauth2AccessTokenResponseWhenValidThenCreated() throws Exception {
public void oauth2AccessTokenResponseWhenValidThenCreated() {
BodyExtractor<Mono<OAuth2AccessTokenResponse>, ReactiveHttpInputMessage> extractor = OAuth2BodyExtractors
.oauth2AccessTokenResponse();
@@ -124,7 +124,7 @@ public class OAuth2BodyExtractorsTests {
@Test
// gh-6087
public void oauth2AccessTokenResponseWhenMultipleAttributeTypesThenCreated() throws Exception {
public void oauth2AccessTokenResponseWhenMultipleAttributeTypesThenCreated() {
BodyExtractor<Mono<OAuth2AccessTokenResponse>, ReactiveHttpInputMessage> extractor = OAuth2BodyExtractors
.oauth2AccessTokenResponse();