/** * Extracts only those parameters from an OAuthMessage that are OAuth-related. * An OAuthMessage may hold a whole bunch of non-OAuth-related parameters * because they were all needed for signing. But when constructing a request * we need to be able to extract just the OAuth-related parameters because * they, and only they, may have to be put into an Authorization: header or * some such thing. * * @param message the OAuthMessage object, which holds non-OAuth parameters * such as foo=bar (which may have been in the original URI query part, or * perhaps in the POST body), as well as OAuth-related parameters (such as * oauth_timestamp or oauth_signature). * * @return a list that contains only the oauth_related parameters. */ static List<Map.Entry<String, String>> selectOAuthParams(OAuthMessage message) { List<Map.Entry<String, String>> result = Lists.newArrayList(); for (Map.Entry<String, String> param : OAuthUtil.getParameters(message)) { if (isContainerInjectedParameter(param.getKey())) { result.add(param); } } return result; }
/** * Extracts only those parameters from an OAuthMessage that are OAuth-related. * An OAuthMessage may hold a whole bunch of non-OAuth-related parameters * because they were all needed for signing. But when constructing a request * we need to be able to extract just the OAuth-related parameters because * they, and only they, may have to be put into an Authorization: header or * some such thing. * * @param message the OAuthMessage object, which holds non-OAuth parameters * such as foo=bar (which may have been in the original URI query part, or * perhaps in the POST body), as well as OAuth-related parameters (such as * oauth_timestamp or oauth_signature). * * @return a list that contains only the oauth_related parameters. */ static List<Map.Entry<String, String>> selectOAuthParams(OAuthMessage message) { List<Map.Entry<String, String>> result = Lists.newArrayList(); for (Map.Entry<String, String> param : OAuthUtil.getParameters(message)) { if (isContainerInjectedParameter(param.getKey())) { result.add(param); } } return result; }
/** * Extracts only those parameters from an OAuthMessage that are OAuth-related. * An OAuthMessage may hold a whole bunch of non-OAuth-related parameters * because they were all needed for signing. But when constructing a request * we need to be able to extract just the OAuth-related parameters because * they, and only they, may have to be put into an Authorization: header or * some such thing. * * @param message the OAuthMessage object, which holds non-OAuth parameters * such as foo=bar (which may have been in the original URI query part, or * perhaps in the POST body), as well as OAuth-related parameters (such as * oauth_timestamp or oauth_signature). * * @return a list that contains only the oauth_related parameters. */ static List<Map.Entry<String, String>> selectOAuthParams(OAuthMessage message) { List<Map.Entry<String, String>> result = Lists.newArrayList(); for (Map.Entry<String, String> param : OAuthUtil.getParameters(message)) { if (isContainerInjectedParameter(param.getKey())) { result.add(param); } } return result; }
private String hasExtraParams(OAuthMessage message) { for (Entry<String, String> param : OAuthUtil.getParameters(message)) { // Our request token URL allows "param" as a query param, and also oauth params of course. if (!param.getKey().startsWith("oauth") && !param.getKey().equals("param")) { return param.getKey(); } } return null; }
private String hasExtraParams(OAuthMessage message) { for (Entry<String, String> param : OAuthUtil.getParameters(message)) { // Our request token URL allows "param" as a query param, and also oauth params of course. if (!param.getKey().startsWith("oauth") && !param.getKey().equals("param")) { return param.getKey(); } } return null; }
private String hasExtraParams(OAuthMessage message) { for (Entry<String, String> param : OAuthUtil.getParameters(message)) { // Our request token URL allows "param" as a query param, and also oauth params of course. if (!param.getKey().startsWith("oauth") && !param.getKey().equals("param")) { return param.getKey(); } } return null; }
for (Entry<String, String> param : OAuthUtil.getParameters(reply)) { if (!param.getKey().startsWith("oauth")) { accessTokenData.put(param.getKey(), param.getValue());
for (Entry<String, String> param : OAuthUtil.getParameters(reply)) { if (!param.getKey().startsWith("oauth")) { accessTokenData.put(param.getKey(), param.getValue());
for (Entry<String, String> param : OAuthUtil.getParameters(reply)) { if (!param.getKey().startsWith("oauth")) { accessTokenData.put(param.getKey(), param.getValue());