org.apache.http.auth.AuthState.getCredentials()方法的使用及代码示例

x33g5p2x  于2022-01-15 转载在 其他  
字(5.5k)|赞(0)|评价(0)|浏览(132)

本文整理了Java中org.apache.http.auth.AuthState.getCredentials()方法的一些代码示例,展示了AuthState.getCredentials()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。AuthState.getCredentials()方法的具体详情如下:
包路径:org.apache.http.auth.AuthState
类名称:AuthState
方法名:getCredentials

AuthState.getCredentials介绍

[英]Returns user Credentials selected for authentication if available
[中]返回为身份验证选择的用户凭据(如果可用)

代码示例

代码示例来源:origin: robovm/robovm

private static Principal getAuthPrincipal(final AuthState authState) {
  AuthScheme scheme = authState.getAuthScheme();
  if (scheme != null && scheme.isComplete() && scheme.isConnectionBased()) {
    Credentials creds = authState.getCredentials();
    if (creds != null) {
      return creds.getUserPrincipal(); 
    }
  }
  return null;
}

代码示例来源:origin: robolectric/robolectric

this.log.debug("Authentication scope: " + authScope);
Credentials creds = authState.getCredentials();
if (creds == null) {
 creds = credsProvider.getCredentials(authScope);

代码示例来源:origin: robovm/robovm

Credentials creds = authState.getCredentials();
if (creds == null) {
  this.log.debug("User credentials not available");

代码示例来源:origin: robovm/robovm

Credentials creds = authState.getCredentials();
if (creds == null) {
  this.log.debug("User credentials not available");

代码示例来源:origin: robovm/robovm

this.log.debug("Authentication scope: " + authScope);
Credentials creds = authState.getCredentials();
if (creds == null) {
  creds = credsProvider.getCredentials(authScope);

代码示例来源:origin: robovm/robovm

if (this.targetAuthState.getCredentials() != null) {
if (this.proxyAuthState.getCredentials() != null) {

代码示例来源:origin: robovm/robovm

Credentials creds = this.proxyAuthState.getCredentials();
if (creds != null) {
  if (authScope != null || !authScheme.isConnectionBased()) {
    if (this.proxyAuthState.getCredentials() != null) {
      done = false;

代码示例来源:origin: robolectric/robolectric

if (this.proxyAuthState.getCredentials() != null) {
 done = false;

代码示例来源:origin: robolectric/robolectric

if (this.targetAuthState.getCredentials() != null) {
if (this.proxyAuthState.getCredentials() != null) {

代码示例来源:origin: MobiVM/robovm

private static Principal getAuthPrincipal(final AuthState authState) {
  AuthScheme scheme = authState.getAuthScheme();
  if (scheme != null && scheme.isComplete() && scheme.isConnectionBased()) {
    Credentials creds = authState.getCredentials();
    if (creds != null) {
      return creds.getUserPrincipal(); 
    }
  }
  return null;
}

代码示例来源:origin: ibinti/bugvm

private static Principal getAuthPrincipal(final AuthState authState) {
  final AuthScheme scheme = authState.getAuthScheme();
  if (scheme != null && scheme.isComplete() && scheme.isConnectionBased()) {
    final Credentials creds = authState.getCredentials();
    if (creds != null) {
      return creds.getUserPrincipal();
    }
  }
  return null;
}

代码示例来源:origin: com.impetus.fabric/fabric-jdbc-driver-shaded

private static Principal getAuthPrincipal(final AuthState authState) {
  final AuthScheme scheme = authState.getAuthScheme();
  if (scheme != null && scheme.isComplete() && scheme.isConnectionBased()) {
    final Credentials creds = authState.getCredentials();
    if (creds != null) {
      return creds.getUserPrincipal();
    }
  }
  return null;
}

代码示例来源:origin: com.mobidevelop.robovm/robovm-rt

private static Principal getAuthPrincipal(final AuthState authState) {
  AuthScheme scheme = authState.getAuthScheme();
  if (scheme != null && scheme.isComplete() && scheme.isConnectionBased()) {
    Credentials creds = authState.getCredentials();
    if (creds != null) {
      return creds.getUserPrincipal(); 
    }
  }
  return null;
}

代码示例来源:origin: com.hynnet/httpclient

private static Principal getAuthPrincipal(final AuthState authState) {
  final AuthScheme scheme = authState.getAuthScheme();
  if (scheme != null && scheme.isComplete() && scheme.isConnectionBased()) {
    final Credentials creds = authState.getCredentials();
    if (creds != null) {
      return creds.getUserPrincipal();
    }
  }
  return null;
}

代码示例来源:origin: com.gluonhq/robovm-rt

private static Principal getAuthPrincipal(final AuthState authState) {
  AuthScheme scheme = authState.getAuthScheme();
  if (scheme != null && scheme.isComplete() && scheme.isConnectionBased()) {
    Credentials creds = authState.getCredentials();
    if (creds != null) {
      return creds.getUserPrincipal(); 
    }
  }
  return null;
}

代码示例来源:origin: com.bugvm/bugvm-rt

private static Principal getAuthPrincipal(final AuthState authState) {
  final AuthScheme scheme = authState.getAuthScheme();
  if (scheme != null && scheme.isComplete() && scheme.isConnectionBased()) {
    final Credentials creds = authState.getCredentials();
    if (creds != null) {
      return creds.getUserPrincipal();
    }
  }
  return null;
}

代码示例来源:origin: at.bestsolution.efxclipse.eclipse/org.apache.httpcomponents.httpclient

private static Principal getAuthPrincipal(final AuthState authState) {
  final AuthScheme scheme = authState.getAuthScheme();
  if (scheme != null && scheme.isComplete() && scheme.isConnectionBased()) {
    final Credentials creds = authState.getCredentials();
    if (creds != null) {
      return creds.getUserPrincipal();
    }
  }
  return null;
}

代码示例来源:origin: FlexoVM/flexovm

private static Principal getAuthPrincipal(final AuthState authState) {
  AuthScheme scheme = authState.getAuthScheme();
  if (scheme != null && scheme.isComplete() && scheme.isConnectionBased()) {
    Credentials creds = authState.getCredentials();
    if (creds != null) {
      return creds.getUserPrincipal(); 
    }
  }
  return null;
}

代码示例来源:origin: Nextdoor/bender

private static Principal getAuthPrincipal(final AuthState authState) {
  final AuthScheme scheme = authState.getAuthScheme();
  if (scheme != null && scheme.isComplete() && scheme.isConnectionBased()) {
    final Credentials creds = authState.getCredentials();
    if (creds != null) {
      return creds.getUserPrincipal();
    }
  }
  return null;
}

代码示例来源:origin: MobiVM/robovm

Credentials creds = authState.getCredentials();
if (creds == null) {
  this.log.debug("User credentials not available");

相关文章