本文整理了Java中org.apache.commons.httpclient.URI.setURI()
方法的一些代码示例,展示了URI.setURI()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。URI.setURI()
方法的具体详情如下:
包路径:org.apache.commons.httpclient.URI
类名称:URI
方法名:setURI
[英]Once it's parsed successfully, set this URI.
[中]成功解析后,设置此URI。
代码示例来源:origin: commons-httpclient/commons-httpclient
/**
* Set the authority. It can be one type of server, hostport, hostname,
* IPv4address, IPv6reference and reg_name.
* Note that there is no setAuthority method by the escape encoding reason.
*
* @param escapedAuthority the escaped authority string
* @throws URIException If {@link
* #parseAuthority(java.lang.String,boolean)} fails
*/
public void setEscapedAuthority(String escapedAuthority)
throws URIException {
parseAuthority(escapedAuthority, true);
setURI();
}
代码示例来源:origin: commons-httpclient/commons-httpclient
/**
* Set the escaped query string.
*
* @param escapedQuery the escaped query string
* @throws URIException escaped query not valid
*/
public void setEscapedQuery(String escapedQuery) throws URIException {
if (escapedQuery == null) {
_query = null;
setURI();
return;
}
setRawQuery(escapedQuery.toCharArray());
}
代码示例来源:origin: commons-httpclient/commons-httpclient
/**
* Set the escaped path.
*
* @param escapedPath the escaped path string
* @throws URIException encoding error or not proper for initial instance
* @see #encode
*/
public void setEscapedPath(String escapedPath) throws URIException {
if (escapedPath == null) {
_path = _opaque = null;
setURI();
return;
}
setRawPath(escapedPath.toCharArray());
}
代码示例来源:origin: commons-httpclient/commons-httpclient
/**
* Set the authority. It can be one type of server, hostport, hostname,
* IPv4address, IPv6reference and reg_name.
* <p><blockquote><pre>
* authority = server | reg_name
* </pre></blockquote><p>
*
* @param escapedAuthority the raw escaped authority
* @throws URIException If {@link
* #parseAuthority(java.lang.String,boolean)} fails
* @throws NullPointerException null authority
*/
public void setRawAuthority(char[] escapedAuthority)
throws URIException, NullPointerException {
parseAuthority(new String(escapedAuthority), true);
setURI();
}
代码示例来源:origin: commons-httpclient/commons-httpclient
/**
* Set the raw-escaped query.
*
* @param escapedQuery the raw-escaped query
* @throws URIException escaped query not valid
*/
public void setRawQuery(char[] escapedQuery) throws URIException {
if (escapedQuery == null || escapedQuery.length == 0) {
_query = escapedQuery;
setURI();
return;
}
// remove the fragment identifier
escapedQuery = removeFragmentIdentifier(escapedQuery);
if (!validate(escapedQuery, query)) {
throw new URIException(URIException.ESCAPING,
"escaped query not valid");
}
_query = escapedQuery;
setURI();
}
代码示例来源:origin: commons-httpclient/commons-httpclient
/**
* Normalizes the path part of this URI. Normalization is only meant to be performed on
* URIs with an absolute path. Calling this method on a relative path URI will have no
* effect.
*
* @throws URIException no more higher path level to be normalized
*
* @see #isAbsPath()
*/
public void normalize() throws URIException {
if (isAbsPath()) {
_path = normalize(_path);
setURI();
}
}
代码示例来源:origin: commons-httpclient/commons-httpclient
/**
* Set the query.
* <p>
* When a query string is not misunderstood the reserved special characters
* ("&", "=", "+", ",", and "$") within a query component, it is
* recommended to use in encoding the whole query with this method.
* <p>
* The additional APIs for the special purpose using by the reserved
* special characters used in each protocol are implemented in each protocol
* classes inherited from <code>URI</code>. So refer to the same-named APIs
* implemented in each specific protocol instance.
*
* @param query the query string.
* @throws URIException incomplete trailing escape pattern or unsupported
* character encoding
* @see #encode
*/
public void setQuery(String query) throws URIException {
if (query == null || query.length() == 0) {
_query = (query == null) ? null : query.toCharArray();
setURI();
return;
}
setRawQuery(encode(query, allowed_query, getProtocolCharset()));
}
代码示例来源:origin: commons-httpclient/commons-httpclient
setURI();
return;
throw new URIException(URIException.PARSING, "incorrect path");
setURI();
代码示例来源:origin: commons-httpclient/commons-httpclient
this._opaque = relative._opaque;
this._fragment = relative._fragment;
this.setURI();
return;
this._fragment = relative._fragment;
this.setURI();
代码示例来源:origin: commons-httpclient/commons-httpclient
setURI();
代码示例来源:origin: commons-httpclient/commons-httpclient
setURI();
代码示例来源:origin: commons-httpclient/commons-httpclient
if (escapedPath == null || escapedPath.length == 0) {
_path = _opaque = escapedPath;
setURI();
return;
throw new URIException(URIException.PARSING, "incorrect path");
setURI();
代码示例来源:origin: org.apache.commons/com.springsource.org.apache.commons.httpclient
/**
* Set the authority. It can be one type of server, hostport, hostname,
* IPv4address, IPv6reference and reg_name.
* Note that there is no setAuthority method by the escape encoding reason.
*
* @param escapedAuthority the escaped authority string
* @throws URIException If {@link
* #parseAuthority(java.lang.String,boolean)} fails
*/
public void setEscapedAuthority(String escapedAuthority)
throws URIException {
parseAuthority(escapedAuthority, true);
setURI();
}
代码示例来源:origin: org.apache.commons/com.springsource.org.apache.commons.httpclient
/**
* Set the escaped query string.
*
* @param escapedQuery the escaped query string
* @throws URIException escaped query not valid
*/
public void setEscapedQuery(String escapedQuery) throws URIException {
if (escapedQuery == null) {
_query = null;
setURI();
return;
}
setRawQuery(escapedQuery.toCharArray());
}
代码示例来源:origin: org.zaproxy/zap
/**
* Set the escaped query string.
*
* @param escapedQuery the escaped query string
* @throws URIException escaped query not valid
*/
public void setEscapedQuery(String escapedQuery) throws URIException {
if (escapedQuery == null) {
_query = null;
setURI();
return;
}
setRawQuery(escapedQuery.toCharArray());
}
代码示例来源:origin: org.wso2.commons-httpclient/commons-httpclient
/**
* Set the authority. It can be one type of server, hostport, hostname,
* IPv4address, IPv6reference and reg_name.
* Note that there is no setAuthority method by the escape encoding reason.
*
* @param escapedAuthority the escaped authority string
* @throws URIException If {@link
* #parseAuthority(java.lang.String,boolean)} fails
*/
public void setEscapedAuthority(String escapedAuthority)
throws URIException {
parseAuthority(escapedAuthority, true);
setURI();
}
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.commons-httpclient
/**
* Set the authority. It can be one type of server, hostport, hostname,
* IPv4address, IPv6reference and reg_name.
* Note that there is no setAuthority method by the escape encoding reason.
*
* @param escapedAuthority the escaped authority string
* @throws URIException If {@link
* #parseAuthority(java.lang.String,boolean)} fails
*/
public void setEscapedAuthority(String escapedAuthority)
throws URIException {
parseAuthority(escapedAuthority, true);
setURI();
}
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.commons-httpclient
/**
* Set the escaped query string.
*
* @param escapedQuery the escaped query string
* @throws URIException escaped query not valid
*/
public void setEscapedQuery(String escapedQuery) throws URIException {
if (escapedQuery == null) {
_query = null;
setURI();
return;
}
setRawQuery(escapedQuery.toCharArray());
}
代码示例来源:origin: org.apache.commons/httpclient
/**
* Set the authority. It can be one type of server, hostport, hostname,
* IPv4address, IPv6reference and reg_name.
* Note that there is no setAuthority method by the escape encoding reason.
*
* @param escapedAuthority the escaped authority string
* @throws URIException If {@link
* #parseAuthority(java.lang.String,boolean)} fails
*/
public void setEscapedAuthority(String escapedAuthority)
throws URIException {
parseAuthority(escapedAuthority, true);
setURI();
}
代码示例来源:origin: org.apache.commons/httpclient
/**
* Set the escaped query string.
*
* @param escapedQuery the escaped query string
* @throws URIException escaped query not valid
*/
public void setEscapedQuery(String escapedQuery) throws URIException {
if (escapedQuery == null) {
_query = null;
setURI();
return;
}
setRawQuery(escapedQuery.toCharArray());
}
内容来源于网络,如有侵权,请联系作者删除!