Package com.google.gerrit.common.data
Class AccountInfo
- java.lang.Object
-
- com.google.gerrit.common.data.AccountInfo
-
-
Field Summary
Fields Modifier and Type Field Description protected String
fullName
protected Account.Id
id
protected String
preferredEmail
protected String
username
-
Constructor Summary
Constructors Modifier Constructor Description protected
AccountInfo()
AccountInfo(Account a)
Create an account description from a real data store record.AccountInfo(Account.Id id)
Create an 'Anonymous Coward' account info, when only the id is known.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getFullName()
Account.Id
getId()
String
getPreferredEmail()
String
getUsername()
void
setFullName(String n)
void
setPreferredEmail(String email)
-
-
-
Field Detail
-
id
protected Account.Id id
-
fullName
protected String fullName
-
preferredEmail
protected String preferredEmail
-
username
protected String username
-
-
Constructor Detail
-
AccountInfo
protected AccountInfo()
-
AccountInfo
public AccountInfo(Account.Id id)
Create an 'Anonymous Coward' account info, when only the id is known.This constructor should only be a last-ditch effort, when the usual account lookup has failed and a stale account id has been discovered in the data store.
-
AccountInfo
public AccountInfo(Account a)
Create an account description from a real data store record.- Parameters:
a
- the data store record holding the specific account details.
-
-
Method Detail
-
getId
public Account.Id getId()
- Returns:
- the unique local id of the account
-
setFullName
public void setFullName(String n)
-
getFullName
public String getFullName()
- Returns:
- the full name of the account holder; null if not supplied
-
getPreferredEmail
public String getPreferredEmail()
- Returns:
- the email address of the account holder; null if not supplied
-
setPreferredEmail
public void setPreferredEmail(String email)
-
getUsername
public String getUsername()
- Returns:
- the username of the account holder
-
-