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:
@@ -70,7 +70,7 @@ public class OpenID4JavaConsumer implements OpenIDConsumer {
|
||||
}
|
||||
|
||||
public OpenID4JavaConsumer(ConsumerManager consumerManager,
|
||||
AxFetchListFactory attributesToFetchFactory) throws ConsumerException {
|
||||
AxFetchListFactory attributesToFetchFactory) {
|
||||
this.consumerManager = consumerManager;
|
||||
this.attributesToFetchFactory = attributesToFetchFactory;
|
||||
}
|
||||
|
||||
+1
-1
@@ -58,7 +58,7 @@ public class OpenIDAuthenticationProvider
|
||||
// ~ Methods
|
||||
// ========================================================================================================
|
||||
|
||||
public void afterPropertiesSet() throws Exception {
|
||||
public void afterPropertiesSet() {
|
||||
Assert.notNull(this.userDetailsService, "The userDetailsService must be set");
|
||||
}
|
||||
|
||||
|
||||
@@ -51,12 +51,11 @@ public class MockOpenIDConsumer implements OpenIDConsumer {
|
||||
// ========================================================================================================
|
||||
|
||||
public String beginConsumption(HttpServletRequest req, String claimedIdentity,
|
||||
String returnToUrl, String realm) throws OpenIDConsumerException {
|
||||
String returnToUrl, String realm) {
|
||||
return redirectUrl;
|
||||
}
|
||||
|
||||
public OpenIDAuthenticationToken endConsumption(HttpServletRequest req)
|
||||
throws OpenIDConsumerException {
|
||||
public OpenIDAuthenticationToken endConsumption(HttpServletRequest req) {
|
||||
return token;
|
||||
}
|
||||
|
||||
|
||||
+2
-3
@@ -42,7 +42,7 @@ public class OpenIDAuthenticationFilterTests {
|
||||
private static final String DEFAULT_TARGET_URL = FILTER_PROCESS_URL;
|
||||
|
||||
@Before
|
||||
public void setUp() throws Exception {
|
||||
public void setUp() {
|
||||
filter = new OpenIDAuthenticationFilter();
|
||||
filter.setConsumer(new MockOpenIDConsumer(REDIRECT_URL));
|
||||
SavedRequestAwareAuthenticationSuccessHandler successHandler = new SavedRequestAwareAuthenticationSuccessHandler();
|
||||
@@ -65,8 +65,7 @@ public class OpenIDAuthenticationFilterTests {
|
||||
|
||||
filter.setConsumer(new MockOpenIDConsumer() {
|
||||
public String beginConsumption(HttpServletRequest req,
|
||||
String claimedIdentity, String returnToUrl, String realm)
|
||||
throws OpenIDConsumerException {
|
||||
String claimedIdentity, String returnToUrl, String realm) {
|
||||
assertThat(claimedIdentity).isEqualTo(CLAIMED_IDENTITY_URL);
|
||||
assertThat(returnToUrl).isEqualTo(DEFAULT_TARGET_URL);
|
||||
assertThat(realm).isEqualTo("http://localhost:8080/");
|
||||
|
||||
Reference in New Issue
Block a user