public function resolve(IRequest $request)
    {
        foreach ($this->grantTypes as $grantType) {
            if ($grantType->match($request)) {
                return $grantType;
            }
        }

        throw new UnsupportedGrantTypeException;
    }
public function resolve(IRequest $request)
    {
        foreach ($this->grantTypes as $grantType) {
            if ($grantType->match($request)) {
                return $grantType;
            }
        }

        throw new UnsupportedGrantTypeException;
    }
public function resolve ( IRequest $ request ) { foreach ( $ this -> grantTypes as $ grantType ) { if ( $ grantType -> match ( $ request ) ) { return $ grantType ; } } throw new UnsupportedGrantTypeException ; }
Resolves grant type for given request

@param IRequest $request

@return IGrantType|IAuthorizationGrantType
@throws \OAuth2\Exception\UnsupportedGrantTypeException
Resolves grant type for given request