本文整理了Java中org.owasp.encoder.Encode.forUriComponent()
方法的一些代码示例,展示了Encode.forUriComponent()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Encode.forUriComponent()
方法的具体详情如下:
包路径:org.owasp.encoder.Encode
类名称:Encode
方法名:forUriComponent
[英]See #forUriComponent(String) for description of encoding. This version writes directly to a Writer without an intervening string.
[中]有关编码的说明,请参见#forUriComponent(字符串)。此版本直接写入写入程序,无需插入字符串。
代码示例来源:origin: primefaces/primefaces
/**
* @see Encode#forUriComponent(String)
*/
public static String forUriComponent(String input) {
return Encode.forUriComponent(input);
}
代码示例来源:origin: openmrs/openmrs-core
/**
* Performs percent-encoding for a component of a URI, such as a query parameter name or value, path or query-string.
*
* @param s
* @return Encoded String
*/
public static String encodeForUriComponent(String s) {
return Encode.forUriComponent(s);
}
代码示例来源:origin: OWASP/owasp-java-encoder
@Override
public void doTag() throws JspException, IOException {
Encode.forUriComponent(getJspContext().getOut(), _value);
}
}
代码示例来源:origin: org.owasp.encoder/encoder-jsp
@Override
public void doTag() throws JspException, IOException {
Encode.forUriComponent(getJspContext().getOut(), _value);
}
}
代码示例来源:origin: networknt/light
eventData.put("originalUrl", Encode.forUriComponent((String)eventData.get("originalUrl")));
代码示例来源:origin: org.wso2.carbon.identity/org.wso2.carbon.identity.oauth.ui
oauthTokenSecret = token.getOauthTokenSecret();
oauthCallbackConfirmed = "true";
reqToken = OAuthConstants.OAUTH_TOKEN + "=" + Encode.forUriComponent(oauthToken) + "&"
+ OAuthConstants.OAUTH_TOKEN_SECRET + "=" + Encode.forUriComponent(oauthTokenSecret) + "&"
+ OAuthConstants.OAUTH_CALLBACK_CONFIRMED + "=" + Encode.forUriComponent(oauthCallbackConfirmed);
out.write(reqToken);
out.close();
PrintWriter out = resp.getWriter();
token = client.getAccessToken(params);
accessToken = OAuthConstants.OAUTH_TOKEN + "=" + Encode.forUriComponent(token.getOauthToken()) + "&"
+ OAuthConstants.OAUTH_TOKEN_SECRET + "=" + Encode.forUriComponent(token.getOauthTokenSecret());
out.write(accessToken);
out.close();
代码示例来源:origin: networknt/light
eventData.put("originalAuthor", Encode.forJavaScriptSource((String)data.get("originalAuthor")));
eventData.put("originalSite", Encode.forJavaScriptSource((String)data.get("originalSite")));
eventData.put("originalUrl", Encode.forUriComponent((String)data.get("originalUrl")));
eventData.put("summary", data.get("summary"));
eventData.put("content", data.get("content"));
内容来源于网络,如有侵权,请联系作者删除!