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:
@@ -50,7 +50,7 @@ public class ServiceProperties implements InitializingBean {
|
||||
// ~ Methods
|
||||
// ========================================================================================================
|
||||
|
||||
public void afterPropertiesSet() throws Exception {
|
||||
public void afterPropertiesSet() {
|
||||
Assert.hasLength(this.service, "service cannot be empty.");
|
||||
Assert.hasLength(this.artifactParameter, "artifactParameter cannot be empty.");
|
||||
Assert.hasLength(this.serviceParameter, "serviceParameter cannot be empty.");
|
||||
|
||||
@@ -77,7 +77,7 @@ public class CasAuthenticationProvider implements AuthenticationProvider,
|
||||
// ~ Methods
|
||||
// ========================================================================================================
|
||||
|
||||
public void afterPropertiesSet() throws Exception {
|
||||
public void afterPropertiesSet() {
|
||||
Assert.notNull(this.authenticationUserDetailsService,
|
||||
"An authenticationUserDetailsService must be set");
|
||||
Assert.notNull(this.ticketValidator, "A ticketValidator must be set");
|
||||
|
||||
@@ -44,7 +44,7 @@ public class EhCacheBasedTicketCache implements StatelessTicketCache, Initializi
|
||||
// ~ Methods
|
||||
// ========================================================================================================
|
||||
|
||||
public void afterPropertiesSet() throws Exception {
|
||||
public void afterPropertiesSet() {
|
||||
Assert.notNull(cache, "cache mandatory");
|
||||
}
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@ public class SpringCacheBasedTicketCache implements StatelessTicketCache {
|
||||
// ~ Constructors
|
||||
// ===================================================================================================
|
||||
|
||||
public SpringCacheBasedTicketCache(Cache cache) throws Exception {
|
||||
public SpringCacheBasedTicketCache(Cache cache) {
|
||||
Assert.notNull(cache, "cache mandatory");
|
||||
this.cache = cache;
|
||||
}
|
||||
|
||||
@@ -65,7 +65,7 @@ public class CasAuthenticationEntryPoint implements AuthenticationEntryPoint,
|
||||
// ~ Methods
|
||||
// ========================================================================================================
|
||||
|
||||
public void afterPropertiesSet() throws Exception {
|
||||
public void afterPropertiesSet() {
|
||||
Assert.hasLength(this.loginUrl, "loginUrl must be specified");
|
||||
Assert.notNull(this.serviceProperties, "serviceProperties must be specified");
|
||||
Assert.notNull(this.serviceProperties.getService(),
|
||||
@@ -74,8 +74,7 @@ public class CasAuthenticationEntryPoint implements AuthenticationEntryPoint,
|
||||
|
||||
public final void commence(final HttpServletRequest servletRequest,
|
||||
final HttpServletResponse response,
|
||||
final AuthenticationException authenticationException) throws IOException,
|
||||
ServletException {
|
||||
final AuthenticationException authenticationException) throws IOException {
|
||||
|
||||
final String urlEncodedService = createServiceUrl(servletRequest, response);
|
||||
final String redirectUrl = createRedirectUrl(urlEncodedService);
|
||||
|
||||
@@ -418,8 +418,7 @@ public class CasAuthenticationProviderTests {
|
||||
this.returnTicket = returnTicket;
|
||||
}
|
||||
|
||||
public Assertion validate(final String ticket, final String service)
|
||||
throws TicketValidationException {
|
||||
public Assertion validate(final String ticket, final String service) {
|
||||
if (returnTicket) {
|
||||
return new AssertionImpl("rod");
|
||||
}
|
||||
|
||||
@@ -128,7 +128,7 @@ public class CasAuthenticationTokenMixinTests {
|
||||
}
|
||||
|
||||
@Test
|
||||
public void deserializeCasAuthenticationTest() throws IOException, JSONException {
|
||||
public void deserializeCasAuthenticationTest() throws IOException {
|
||||
CasAuthenticationToken token = mapper.readValue(CAS_TOKEN_JSON, CasAuthenticationToken.class);
|
||||
assertThat(token).isNotNull();
|
||||
assertThat(token.getPrincipal()).isNotNull().isInstanceOf(User.class);
|
||||
|
||||
Reference in New Issue
Block a user