/** * This is a verification step, it can abort the instantiation by * throwing a RuntimeException * * @param provider a auth provider * @return the provider if valid */ private static AuthProvider verifyProvider(AuthProvider provider) { if (provider instanceof OAuth2Auth) { if (((OAuth2Auth) provider).getFlowType() != AUTH_CODE) { throw new IllegalArgumentException("OAuth2Auth + Bearer Auth requires OAuth2 AUTH_CODE flow"); } } return provider; }
/** * Returns the configured flow type for the Oauth2 provider. * @return the flow type. */ public OAuth2FlowType getFlowType() { OAuth2FlowType ret = delegate.getFlowType(); return ret; }
/** * Returns the configured flow type for the Oauth2 provider. * @return the flow type. */ public OAuth2FlowType getFlowType() { OAuth2FlowType ret = delegate.getFlowType(); return ret; }
/** * This is a verification step, it can abort the instantiation by * throwing a RuntimeException * * @param provider a auth provider * @return the provider if valid */ private static AuthProvider verifyProvider(AuthProvider provider) { if (provider instanceof OAuth2Auth) { if (((OAuth2Auth) provider).getFlowType() != AUTH_CODE) { throw new IllegalArgumentException("OAuth2Auth + Bearer Auth requires OAuth2 AUTH_CODE flow"); } } return provider; }
/** * This is a verification step, it can abort the instantiation by throwing a RuntimeException * * @param provider * a auth provider * @return the provider if valid */ private static AuthProvider verifyProvider(AuthProvider provider) { if (provider instanceof OAuth2Auth) { if (((OAuth2Auth) provider).getFlowType() != AUTH_CODE) { throw new IllegalArgumentException("OAuth2Auth + Bearer Auth requires OAuth2 AUTH_CODE flow"); } } return provider; }