Package com.google.gerrit.server.project
Class GroupList
- java.lang.Object
-
- com.google.gerrit.server.git.meta.TabFile
-
- com.google.gerrit.server.project.GroupList
-
public class GroupList extends TabFile
File format for group name aliases.Project configuration must use aliases for groups used in the permission section. The aliases/group mapping is stored in a file "groups", (de)serialized with this class.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.gerrit.server.git.meta.TabFile
TabFile.Parser, TabFile.Row
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description String
asText()
GroupReference
byName(String name)
Map<AccountGroup.UUID,GroupReference>
byUUID()
GroupReference
byUUID(AccountGroup.UUID uuid)
static GroupList
parse(Project.NameKey project, String text, ValidationError.Sink errors)
void
put(AccountGroup.UUID uuid, GroupReference reference)
Collection<GroupReference>
references()
void
renameGroup(AccountGroup.UUID uuid, String name)
GroupReference
resolve(GroupReference group)
Returns theGroupReference
instance thatGroupList
holds on to that has the sameAccountGroup.UUID
as the argument.void
retainUUIDs(Collection<AccountGroup.UUID> toBeRetained)
Set<AccountGroup.UUID>
uuids()
-
-
-
Field Detail
-
FILE_NAME
public static final String FILE_NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
parse
public static GroupList parse(Project.NameKey project, String text, ValidationError.Sink errors) throws IOException
- Throws:
IOException
-
byUUID
public GroupReference byUUID(AccountGroup.UUID uuid)
-
byUUID
public Map<AccountGroup.UUID,GroupReference> byUUID()
-
byName
public GroupReference byName(String name)
-
resolve
public GroupReference resolve(GroupReference group)
Returns theGroupReference
instance thatGroupList
holds on to that has the sameAccountGroup.UUID
as the argument. Will store the argument internally, if no group with thisAccountGroup.UUID
was stored previously.
-
renameGroup
public void renameGroup(AccountGroup.UUID uuid, String name)
-
references
public Collection<GroupReference> references()
-
uuids
public Set<AccountGroup.UUID> uuids()
-
put
public void put(AccountGroup.UUID uuid, GroupReference reference)
-
asText
public String asText()
-
retainUUIDs
public void retainUUIDs(Collection<AccountGroup.UUID> toBeRetained)
-
-