1
0
mirror of synced 2026-05-22 13:23:17 +00:00

Apply code cleanup rules to projects

Apply automated cleanup rules to add `@Override` and `@Deprecated`
annotations and to fix class references used with static methods.

Issue gh-8945
This commit is contained in:
Phillip Webb
2020-07-26 12:04:13 -07:00
committed by Rob Winch
parent 8866fa6fb0
commit 9e08b51ed3
558 changed files with 1418 additions and 102 deletions
@@ -17,6 +17,7 @@ package org.springframework.security.integration;
public class StubUserRepository implements UserRepository {
@Override
public void doSomething() {
}
@@ -64,6 +64,7 @@ public class ProtectPointcutPerformanceTests implements ApplicationContextAware
}
@Override
public void setApplicationContext(ApplicationContext applicationContext) throws BeansException {
this.ctx = applicationContext;
}
@@ -25,6 +25,7 @@ public class UserDetailsServiceImpl implements UserDetailsService {
@SuppressWarnings({ "unused", "FieldCanBeLocal" })
private UserRepository userRepository;
@Override
@Transactional(readOnly = true)
public UserDetails loadUserByUsername(String username) {
return null;
@@ -17,15 +17,19 @@ package org.springframework.security.integration.multiannotation;
public class MultiAnnotationServiceImpl implements MultiAnnotationService {
@Override
public void preAuthorizeDenyAllMethod() {
}
@Override
public void preAuthorizeHasRoleAMethod() {
}
@Override
public void securedAnonymousMethod() {
}
@Override
public void securedRoleAMethod() {
}
@@ -20,6 +20,7 @@ package org.springframework.security.integration.multiannotation;
*/
public class PreAuthorizeServiceImpl implements PreAuthorizeService {
@Override
public void preAuthorizedMethod() {
}
@@ -20,6 +20,7 @@ package org.springframework.security.integration.multiannotation;
*/
public class SecuredServiceImpl implements SecuredService {
@Override
public void securedMethod() {
}
@@ -24,6 +24,7 @@ import org.springframework.security.core.Authentication;
public class PythonInterpreterPostInvocationAdvice implements PostInvocationAuthorizationAdvice {
@Override
public Object after(Authentication authentication, MethodInvocation mi, PostInvocationAttribute pia,
Object returnedObject) throws AccessDeniedException {
return returnedObject;
@@ -38,6 +38,7 @@ public class PythonInterpreterPreInvocationAdvice implements PreInvocationAuthor
private final ParameterNameDiscoverer parameterNameDiscoverer = new LocalVariableTableParameterNameDiscoverer();
@Override
public boolean before(Authentication authentication, MethodInvocation mi, PreInvocationAttribute preAttr) {
PythonInterpreterPreInvocationAttribute pythonAttr = (PythonInterpreterPreInvocationAttribute) preAttr;
String script = pythonAttr.getScript();
@@ -25,6 +25,7 @@ public class PythonInterpreterPreInvocationAttribute implements PreInvocationAtt
this.script = script;
}
@Override
public String getAttribute() {
return null;
}
@@ -27,11 +27,13 @@ public class PythonInterpreterPrePostInvocationAttributeFactory implements PrePo
PythonInterpreter.initialize(System.getProperties(), null, new String[] {});
}
@Override
public PreInvocationAttribute createPreInvocationAttribute(String preFilterAttribute, String filterObject,
String preAuthorizeAttribute) {
return new PythonInterpreterPreInvocationAttribute(preAuthorizeAttribute);
}
@Override
public PostInvocationAttribute createPostInvocationAttribute(String postFilterAttribute,
String postAuthorizeAttribute) {
return null;
@@ -17,6 +17,7 @@ package org.springframework.security.integration.python;
public class TestServiceImpl implements TestService {
@Override
public void someMethod() {
System.out.print("Invoked someMethod()");
}