Rename AccountResolver#byId to accountCache
Change-Id: I5e609de45c2593ed9a547690f92f54dc49f20481
diff --git a/java/com/google/gerrit/server/account/AccountResolver.java b/java/com/google/gerrit/server/account/AccountResolver.java
index 8e1ed7e..24a2596 100644
--- a/java/com/google/gerrit/server/account/AccountResolver.java
+++ b/java/com/google/gerrit/server/account/AccountResolver.java
@@ -246,7 +246,7 @@
private abstract class AccountIdSearcher implements Searcher<Account.Id> {
@Override
public final Stream<AccountState> search(Account.Id input) {
- return Streams.stream(byId.get(input));
+ return Streams.stream(accountCache.get(input));
}
}
@@ -318,7 +318,7 @@
@Override
public Stream<AccountState> search(String input) {
- return Streams.stream(byId.getByUsername(input));
+ return Streams.stream(accountCache.getByUsername(input));
}
@Override
@@ -461,7 +461,7 @@
.addAll(nameOrEmailSearchers)
.build();
- private final AccountCache byId;
+ private final AccountCache accountCache;
private final AccountControl.Factory accountControlFactory;
private final Emails emails;
private final IdentifiedUser.GenericFactory userFactory;
@@ -472,7 +472,7 @@
@Inject
AccountResolver(
- AccountCache byId,
+ AccountCache accountCache,
Emails emails,
AccountControl.Factory accountControlFactory,
IdentifiedUser.GenericFactory userFactory,
@@ -481,7 +481,7 @@
Realm realm,
@AnonymousCowardName String anonymousCowardName) {
this.realm = realm;
- this.byId = byId;
+ this.accountCache = accountCache;
this.accountControlFactory = accountControlFactory;
this.userFactory = userFactory;
this.self = self;
@@ -608,6 +608,6 @@
}
private Stream<AccountState> toAccountStates(Set<Account.Id> ids) {
- return byId.get(ids).values().stream();
+ return accountCache.get(ids).values().stream();
}
}