本文整理匯總了Java中org.apache.http.params.HttpParams.getBooleanParameter方法的典型用法代碼示例。如果您正苦於以下問題:Java HttpParams.getBooleanParameter方法的具體用法?Java HttpParams.getBooleanParameter怎麽用?Java HttpParams.getBooleanParameter使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類org.apache.http.params.HttpParams
的用法示例。
在下文中一共展示了HttpParams.getBooleanParameter方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: newInstance
import org.apache.http.params.HttpParams; //導入方法依賴的package包/類
public CookieSpec newInstance(final HttpParams params) {
if (params != null) {
String[] patterns = null;
Collection<?> param = (Collection<?>) params.getParameter(
CookieSpecPNames.DATE_PATTERNS);
if (param != null) {
patterns = new String[param.size()];
patterns = param.toArray(patterns);
}
boolean singleHeader = params.getBooleanParameter(
CookieSpecPNames.SINGLE_COOKIE_HEADER, false);
return new BestMatchSpec(patterns, singleHeader);
} else {
return new BestMatchSpec();
}
}
示例2: newInstance
import org.apache.http.params.HttpParams; //導入方法依賴的package包/類
public CookieSpec newInstance(final HttpParams params) {
if (params != null) {
String[] patterns = null;
Collection<?> param = (Collection<?>) params.getParameter(
CookieSpecPNames.DATE_PATTERNS);
if (param != null) {
patterns = new String[param.size()];
patterns = param.toArray(patterns);
}
boolean singleHeader = params.getBooleanParameter(
CookieSpecPNames.SINGLE_COOKIE_HEADER, false);
return new RFC2109Spec(patterns, singleHeader);
} else {
return new RFC2109Spec();
}
}
示例3: newInstance
import org.apache.http.params.HttpParams; //導入方法依賴的package包/類
public CookieSpec newInstance(final HttpParams params) {
if (params != null) {
String[] patterns = null;
Collection<?> param = (Collection<?>) params.getParameter(
CookieSpecPNames.DATE_PATTERNS);
if (param != null) {
patterns = new String[param.size()];
patterns = param.toArray(patterns);
}
boolean singleHeader = params.getBooleanParameter(
CookieSpecPNames.SINGLE_COOKIE_HEADER, false);
return new RFC2965Spec(patterns, singleHeader);
} else {
return new RFC2965Spec();
}
}
示例4: isRedirecting
import org.apache.http.params.HttpParams; //導入方法依賴的package包/類
public static boolean isRedirecting(final HttpParams params) {
if (params == null) {
throw new IllegalArgumentException("HTTP parameters may not be null");
}
return params.getBooleanParameter
(ClientPNames.HANDLE_REDIRECTS, true);
}
示例5: isAuthenticating
import org.apache.http.params.HttpParams; //導入方法依賴的package包/類
public static boolean isAuthenticating(final HttpParams params) {
if (params == null) {
throw new IllegalArgumentException("HTTP parameters may not be null");
}
return params.getBooleanParameter
(ClientPNames.HANDLE_AUTHENTICATION, true);
}