code: protected boolean isRefreshTokenSupported(String grantType, Set<String> scope) {
          if (!isRestrictRefreshGrant) {
              return GRANT_TYPE_AUTHORIZATION_CODE.equals(grantType) ||
                  GRANT_TYPE_PASSWORD.equals(grantType) ||
                  GRANT_TYPE_USER_TOKEN.equals(grantType) ||
                  GRANT_TYPE_REFRESH_TOKEN.equals(grantType) ||
                  GRANT_TYPE_SAML2_BEARER.equals(grantType);
          } else {
              return scope.contains(UAA_REFRESH_TOKEN);
          }
      }
docs: Check the current authorization request to indicate whether a refresh
  token should be issued or not.
  
  @param grantType the current grant type
  @param scope
  @return boolean to indicate if refresh token is supported