@Test public void withoutRuleSsl() { RuleNode<SecurityFactory<SSLContext>> initialRule = new RuleNode<>( new RuleNode<>( new RuleNode<>(null, MatchRule.ALL.matchPort(3456), ssl3), MatchRule.ALL.matchPort(2345), ssl2), MatchRule.ALL.matchPort(1234), ssl1); AuthenticationContext ctx = new AuthenticationContext(null, initialRule) .withoutSsl(1); assertExpectedRuleNode(ctx.sslRules, ssl1, MatchRule.ALL.matchPort(1234)); RuleNode<SecurityFactory<SSLContext>> second = ctx.sslRules.getNext(); assertExpectedRuleNode(second, ssl3, MatchRule.ALL.matchPort(3456)); assertNull(second.getNext()); }
public AuthenticationContext withoutSsl(int idx) throws IndexOutOfBoundsException { return new AuthenticationContext(authRules, without(sslRules, idx)); }
AuthenticationContext implements Contextual<AuthenticationContext> { public AuthenticationContext withoutSsl(int idx) throws IndexOutOfBoundsException { return new AuthenticationContext(authRules, without(sslRules, idx)); } }
AuthenticationContext implements Contextual<AuthenticationContext> { public AuthenticationContext withoutSsl(int idx) throws IndexOutOfBoundsException { return new AuthenticationContext(authRules, without(sslRules, idx)); } private  AuthenticationContext();   AuthenticationContext(final RuleNode<AuthenticationConfiguration> authRules, final RuleNode<SecurityFactory<SSLContext>> sslRules); }
AuthenticationContext implements Contextual<AuthenticationContext> { public AuthenticationContext withoutSsl(int idx) throws IndexOutOfBoundsException { return new AuthenticationContext(authRules, without(sslRules, idx)); } private  AuthenticationContext();   AuthenticationContext(final RuleNode<AuthenticationConfiguration> authRules, final RuleNode<SecurityFactory<SSLContext>> sslRules); static AuthenticationContext empty(); static AuthenticationContext captureCurrent(); AuthenticationContext with(MatchRule rule, AuthenticationConfiguration configuration); AuthenticationContext withSsl(MatchRule rule, SecurityFactory<SSLContext> sslContext); AuthenticationContext with(AuthenticationContext other); AuthenticationContext with(int idx, MatchRule rule, AuthenticationConfiguration configuration); AuthenticationContext withSsl(int idx, MatchRule rule, SecurityFactory<SSLContext> sslContext); AuthenticationContext replacing(int idx, MatchRule rule, AuthenticationConfiguration configuration); AuthenticationContext replacingSslContext(int idx, MatchRule rule, SecurityFactory<SSLContext> sslContext); AuthenticationContext without(int idx); AuthenticationContext withoutSsl(int idx); T run(PrivilegedAction<T> action); T run(PrivilegedExceptionAction<T> action); T run(P parameter, ParametricPrivilegedAction<T, P> action); T run(P parameter, ParametricPrivilegedExceptionAction<T, P> action); void runAsObjIntConsumer(ObjIntConsumer<T> action, T parameter1, int parameter2); T runAsSupplier(Supplier<T> action); void runAsObjIntConsumerEx(ExceptionObjIntConsumer<T, E> action, T parameter1, int parameter2); T runAsSupplierEx(ExceptionSupplier<T, E> action); ContextManager<AuthenticationContext> getInstanceContextManager(); static ContextManager<AuthenticationContext> getContextManager(); }
AuthenticationContext implements Contextual<AuthenticationContext> { public AuthenticationContext withoutSsl(int idx) throws IndexOutOfBoundsException { return new AuthenticationContext(authRules, without(sslRules, idx)); } private  AuthenticationContext();   AuthenticationContext(final RuleNode<AuthenticationConfiguration> authRules, final RuleNode<SecurityFactory<SSLContext>> sslRules); static AuthenticationContext empty(); static AuthenticationContext captureCurrent(); AuthenticationContext with(MatchRule rule, AuthenticationConfiguration configuration); AuthenticationContext withSsl(MatchRule rule, SecurityFactory<SSLContext> sslContext); AuthenticationContext with(AuthenticationContext other); AuthenticationContext with(int idx, MatchRule rule, AuthenticationConfiguration configuration); AuthenticationContext withSsl(int idx, MatchRule rule, SecurityFactory<SSLContext> sslContext); AuthenticationContext replacing(int idx, MatchRule rule, AuthenticationConfiguration configuration); AuthenticationContext replacingSslContext(int idx, MatchRule rule, SecurityFactory<SSLContext> sslContext); AuthenticationContext without(int idx); AuthenticationContext withoutSsl(int idx); T run(PrivilegedAction<T> action); T run(PrivilegedExceptionAction<T> action); T run(P parameter, ParametricPrivilegedAction<T, P> action); T run(P parameter, ParametricPrivilegedExceptionAction<T, P> action); void runAsObjIntConsumer(ObjIntConsumer<T> action, T parameter1, int parameter2); T runAsSupplier(Supplier<T> action); void runAsObjIntConsumerEx(ExceptionObjIntConsumer<T, E> action, T parameter1, int parameter2); T runAsSupplierEx(ExceptionSupplier<T, E> action); ContextManager<AuthenticationContext> getInstanceContextManager(); static ContextManager<AuthenticationContext> getContextManager();  }