Class GroupDelta.Builder
- java.lang.Object
-
- com.google.gerrit.server.group.db.GroupDelta.Builder
-
- Enclosing class:
- GroupDelta
public abstract static class GroupDelta.Builder extends Object
A builder for aGroupDelta
.
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract GroupDelta
build()
abstract GroupDelta.MemberModification
getMemberModification()
Returns the currently definedGroupDelta.MemberModification
for the prospectiveGroupDelta
.abstract GroupDelta.SubgroupModification
getSubgroupModification()
Returns the currently definedGroupDelta.SubgroupModification
for the prospectiveGroupDelta
.abstract GroupDelta.Builder
setDescription(String description)
Defines the new description of the groupabstract GroupDelta.Builder
setMemberModification(GroupDelta.MemberModification memberModification)
SetGroupDelta.MemberModification
for the prospectiveGroupDelta
abstract GroupDelta.Builder
setName(AccountGroup.NameKey name)
Defines the new name of the groupabstract GroupDelta.Builder
setOwnerGroupUUID(AccountGroup.UUID ownerGroupUUID)
Defines the new owner of the groupabstract GroupDelta.Builder
setSubgroupModification(GroupDelta.SubgroupModification subgroupModification)
SetGroupDelta.SubgroupModification
for the prospectiveGroupDelta
abstract GroupDelta.Builder
setUpdatedOn(Timestamp timestamp)
Defines theTimestamp
to be used for the NoteDb commits of the update.abstract GroupDelta.Builder
setVisibleToAll(boolean visibleToAll)
Defines the new state of the 'visibleToAll' flag of the group
-
-
-
Method Detail
-
setName
public abstract GroupDelta.Builder setName(AccountGroup.NameKey name)
Defines the new name of the groupSee
GroupDelta.getName()
.
-
setDescription
public abstract GroupDelta.Builder setDescription(String description)
Defines the new description of the group
-
setOwnerGroupUUID
public abstract GroupDelta.Builder setOwnerGroupUUID(AccountGroup.UUID ownerGroupUUID)
Defines the new owner of the group
-
setVisibleToAll
public abstract GroupDelta.Builder setVisibleToAll(boolean visibleToAll)
Defines the new state of the 'visibleToAll' flag of the group
-
setMemberModification
public abstract GroupDelta.Builder setMemberModification(GroupDelta.MemberModification memberModification)
-
getMemberModification
public abstract GroupDelta.MemberModification getMemberModification()
Returns the currently definedGroupDelta.MemberModification
for the prospectiveGroupDelta
.This modification can be tweaked further and passed to
setMemberModification(GroupDelta.MemberModification)
in order to combine multiple member additions, deletions, or other modifications into one update.
-
setSubgroupModification
public abstract GroupDelta.Builder setSubgroupModification(GroupDelta.SubgroupModification subgroupModification)
-
getSubgroupModification
public abstract GroupDelta.SubgroupModification getSubgroupModification()
Returns the currently definedGroupDelta.SubgroupModification
for the prospectiveGroupDelta
.This modification can be tweaked further and passed to
setSubgroupModification(GroupDelta.SubgroupModification)
in order to combine multiple subgroup additions, deletions, or other modifications into one update.
-
setUpdatedOn
public abstract GroupDelta.Builder setUpdatedOn(Timestamp timestamp)
Defines theTimestamp
to be used for the NoteDb commits of the update. If not specified, the currentTimestamp
when creating the commit will be used.
-
build
public abstract GroupDelta build()
-
-