Package org.kohsuke.github
Class GHTeamBuilder
- java.lang.Object
-
- org.kohsuke.github.GHTeamBuilder
-
public class GHTeamBuilder extends Object
Creates a team. https://developer.github.com/v3/teams/#create-team
-
-
Field Summary
Fields Modifier and Type Field Description protected org.kohsuke.github.RequesterbuilderThe builder.
-
Constructor Summary
Constructors Constructor Description GHTeamBuilder(GitHub root, String orgName, String name)Instantiates a new GH team builder.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description GHTeamcreate()Creates a team with all the parameters.GHTeamBuilderdescription(String description)Description for this team.GitHubgetRoot()Deprecated.For access to theGitHubinstance, use a local copy instead of pulling it out of objects.GHTeamBuildermaintainers(String... maintainers)Maintainers for this team.GHTeamBuilderparentTeamId(long parentTeamId)Parent team id for this team.GHTeamBuilderprivacy(GHTeam.Privacy privacy)Description for this team.GHTeamBuilderrepositories(String... repoNames)Repository names to add this team to.
-
-
-
Method Detail
-
description
public GHTeamBuilder description(String description)
Description for this team.- Parameters:
description- description of team- Returns:
- a builder to continue with building
-
maintainers
public GHTeamBuilder maintainers(String... maintainers)
Maintainers for this team.- Parameters:
maintainers- maintainers of team- Returns:
- a builder to continue with building
-
repositories
public GHTeamBuilder repositories(String... repoNames)
Repository names to add this team to.- Parameters:
repoNames- repoNames to add team to- Returns:
- a builder to continue with building
-
privacy
public GHTeamBuilder privacy(GHTeam.Privacy privacy)
Description for this team.- Parameters:
privacy- privacy of team- Returns:
- a builder to continue with building
-
parentTeamId
public GHTeamBuilder parentTeamId(long parentTeamId)
Parent team id for this team.- Parameters:
parentTeamId- parentTeamId of team- Returns:
- a builder to continue with building
-
create
public GHTeam create() throws IOException
Creates a team with all the parameters.- Returns:
- the gh team
- Throws:
IOException- if team cannot be created
-
getRoot
@Deprecated public GitHub getRoot()
Deprecated.For access to theGitHubinstance, use a local copy instead of pulling it out of objects.Get the rootGitHubinstance for this object.- Returns:
- the root
GitHubinstance
-
-