public function getAuthProvider($key)
    {
        if (array_key_exists($key, $this->authproviders)) {
            return $this->authproviders[$key];
        }

        throw \InvalidArgumentException(sprintf("Auth provider doesn't exists", $key));
    }
public function getAuthProvider($key)
    {
        if (array_key_exists($key, $this->authproviders)) {
            return $this->authproviders[$key];
        }

        throw \InvalidArgumentException(sprintf("Auth provider doesn't exists", $key));
    }
public function getAuthProvider ( $ key ) { if ( array_key_exists ( $ key , $ this -> authproviders ) ) { return $ this -> authproviders [ $ key ] ; } throw \ InvalidArgumentException ( sprintf ( "Auth provider doesn't exists" , $ key ) ) ; }
Get auth provider.

@param string $key

@return AuthenticationProviderInterface

@throws InvalidArgumentException if provider not found
Get auth provider .