Skip to content

Commit

Permalink
enh(checkstyle): made private classes final to conform to latest chec…
Browse files Browse the repository at this point in the history
…kstyle rules
  • Loading branch information
lprimak committed Jul 31, 2023
1 parent 42eacac commit 4728b6b
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,17 +44,17 @@ class AnnotatedTypeWrapperTest {
@RequiresAuthentication
@RequiresGuest
@RequiresPermissions("hello")
private class Annotated { }
private final class Annotated { }

@ShiroSecureAnnotation
private class ShiroSecureAnnotated { }
private final class ShiroSecureAnnotated { }

@Stateless
private class StatelessAnnotated { }
private final class StatelessAnnotated { }

@SessionScoped
@SuppressWarnings("serial")
private static class SessionScopedAnnotated implements Serializable { }
private static final class SessionScopedAnnotated implements Serializable { }

@Test
void noAnnotations() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,23 +46,23 @@ public class ShiroSessionScopeExtension implements Extension, Serializable {

@SessionScoped
@SuppressWarnings("serial")
private static class SessionScopedAnnotated implements Serializable { }
private static final class SessionScopedAnnotated implements Serializable { }
@javax.faces.view.ViewScoped
@SuppressWarnings("serial")
private static class FacesViewScopedAnnotated implements Serializable { }
private static final class FacesViewScopedAnnotated implements Serializable { }
@org.omnifaces.cdi.ViewScoped
@SuppressWarnings("serial")
private static class OmniViewScopedAnnotated implements Serializable { }
private static final class OmniViewScopedAnnotated implements Serializable { }

@ShiroSessionScoped
@SuppressWarnings("serial")
private static class ShiroSessionScopedAnnotated implements Serializable { }
private static final class ShiroSessionScopedAnnotated implements Serializable { }
@ShiroFacesViewScoped
@SuppressWarnings("serial")
private static class ShiroFacesViewScopedAnnotated implements Serializable { }
private static final class ShiroFacesViewScopedAnnotated implements Serializable { }
@ShiroOmniViewScoped
@SuppressWarnings("serial")
private static class ShiroOmniViewScopedAnnotated implements Serializable { }
private static final class ShiroOmniViewScopedAnnotated implements Serializable { }


/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public class FormAuthenticationFilter extends org.apache.shiro.web.filter.authc.
static final FallbackPredicate NO_PREDICATE = (path, request) -> false;
private final @Delegate AuthenticationFilterDelegate delegate;

private class Methods implements MethodsFromFilter {
private final class Methods implements MethodsFromFilter {
@Override
public Subject getSubject(ServletRequest request, ServletResponse response) {
return FormAuthenticationFilter.super.getSubject(request, response);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public class LogoutFilter extends org.apache.shiro.web.filter.authc.LogoutFilter
static final String LOGOUT_PREDICATE_ATTR_NAME = "org.apache.shiro.ee.logout-predicate";
private final @Delegate AuthenticationFilterDelegate delegate;

private class Methods implements MethodsFromFilter {
private final class Methods implements MethodsFromFilter {
@Override
public Subject getSubject(ServletRequest request, ServletResponse response) {
return LogoutFilter.super.getSubject(request, response);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
public class PassThruAuthenticationFilter extends org.apache.shiro.web.filter.authc.PassThruAuthenticationFilter {
private final @Delegate AuthenticationFilterDelegate delegate;

private class Methods implements MethodsFromFilter {
private final class Methods implements MethodsFromFilter {
@Override
public Subject getSubject(ServletRequest request, ServletResponse response) {
return PassThruAuthenticationFilter.super.getSubject(request, response);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public class IniEnvironment extends IniWebEnvironment {
private String otherConfigLocation;

@SuppressWarnings("deprecation")
private static class SecurityManagerFactory extends WebIniSecurityManagerFactory {
private static final class SecurityManagerFactory extends WebIniSecurityManagerFactory {
private final Lazy<AesCipherService> cipherService = new Lazy<>(AesCipherService::new);

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public class ShiroScopeContextTest {
private MyBean bean;
private ShiroScopeContext ctx;

private static class MyBean implements ViewScoped, Serializable {
private static final class MyBean implements ViewScoped, Serializable {
private static final long serialVersionUID = 1L;

@Override
Expand Down

0 comments on commit 4728b6b

Please sign in to comment.