本文整理了Java中fathom.realm.Account.isAuthenticated()
方法的一些代码示例,展示了Account.isAuthenticated()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Account.isAuthenticated()
方法的具体详情如下:
包路径:fathom.realm.Account
类名称:Account
方法名:isAuthenticated
[英]Returns true if this Account is authenticated.
[中]如果此帐户经过身份验证,则返回true。
代码示例来源:origin: gitblit/fathom
/**
* Ensures this Account has actively authenticated.
* <p>
*
* @throws fathom.authc.AuthenticationException if the Account is not authenticated.
*/
public void checkAuthenticated() throws AuthenticationException {
if (!isAuthenticated()) {
throw new AuthorizationException("'{}' has not authenticated", toString());
}
}
代码示例来源:origin: com.gitblit.fathom/fathom-security
/**
* Ensures this Account has actively authenticated.
* <p>
*
* @throws fathom.authc.AuthenticationException if the Account is not authenticated.
*/
public void checkAuthenticated() throws AuthenticationException {
if (!isAuthenticated()) {
throw new AuthorizationException("'{}' has not authenticated", toString());
}
}
代码示例来源:origin: gitblit/fathom
/**
* Determines if the current Context has already been authenticated.
*
* @param context
* @return true if this Context is authenticated.
*/
protected final boolean isAuthenticated(Context context) {
Account account = context.getSession(AuthConstants.ACCOUNT_ATTRIBUTE);
if (account == null) {
account = context.getLocal(AuthConstants.ACCOUNT_ATTRIBUTE);
}
return account != null && account.isAuthenticated();
}
代码示例来源:origin: com.gitblit.fathom/fathom-rest-security
/**
* Determines if the current Context has already been authenticated.
*
* @param context
* @return true if this Context is authenticated.
*/
protected final boolean isAuthenticated(Context context) {
Account account = context.getSession(AuthConstants.ACCOUNT_ATTRIBUTE);
if (account == null) {
account = context.getLocal(AuthConstants.ACCOUNT_ATTRIBUTE);
}
return account != null && account.isAuthenticated();
}
内容来源于网络,如有侵权,请联系作者删除!