Package com.google.gerrit.server.account
Class DefaultRealm
- java.lang.Object
-
- com.google.gerrit.server.account.AbstractRealm
-
- com.google.gerrit.server.account.DefaultRealm
-
- All Implemented Interfaces:
Realm
- Direct Known Subclasses:
OpenIdRealm
public class DefaultRealm extends AbstractRealm
-
-
Constructor Summary
Constructors Constructor Description DefaultRealm(EmailExpander emailExpander, com.google.inject.Provider<Emails> emails, AuthConfig authConfig)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
allowsEdit(AccountFieldName field)
Can the end-user modify this field of their own account?AuthRequest
authenticate(AuthRequest who)
Account.Id
lookup(String accountName)
Locate an account whose local username is the given account name.void
onCreateAccount(AuthRequest who, Account account)
-
Methods inherited from class com.google.gerrit.server.account.AbstractRealm
getEditableFields, getEmailAddresses, hasEmailAddress
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.google.gerrit.server.account.Realm
accountBelongsToRealm, isActive
-
-
-
-
Constructor Detail
-
DefaultRealm
@Inject public DefaultRealm(EmailExpander emailExpander, com.google.inject.Provider<Emails> emails, AuthConfig authConfig)
-
-
Method Detail
-
allowsEdit
public boolean allowsEdit(AccountFieldName field)
Description copied from interface:Realm
Can the end-user modify this field of their own account?
-
authenticate
public AuthRequest authenticate(AuthRequest who)
-
onCreateAccount
public void onCreateAccount(AuthRequest who, Account account)
-
lookup
public Account.Id lookup(String accountName) throws IOException
Description copied from interface:Realm
Locate an account whose local username is the given account name.Generally this only works for local realms, such as one backed by an LDAP directory, or where there is an
EmailExpander
configured that knows how to convert the accountName into an email address, and then locate the user by that email address.- Throws:
IOException
-
-