Package hudson.plugins.collabnet.auth
Class CNAuthProjectProperty
- java.lang.Object
-
- hudson.model.JobProperty<Job<?,?>>
-
- hudson.plugins.collabnet.auth.CNAuthProjectProperty
-
- All Implemented Interfaces:
ExtensionPoint
,Describable<JobProperty<?>>
,ReconfigurableDescribable<JobProperty<?>>
,BuildStep
public class CNAuthProjectProperty extends JobProperty<Job<?,?>>
Job property to associate a Jenkins job with a CollabNet Project for Authorization purposes (used with CollabNet Authorization).
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
CNAuthProjectProperty.DescriptorImpl
Descriptor class.-
Nested classes/interfaces inherited from interface hudson.tasks.BuildStep
BuildStep.PublisherList
-
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
-
Field Summary
Fields Modifier and Type Field Description static Permission
CONFIGURE_PROPERTY
-
Fields inherited from class hudson.model.JobProperty
owner
-
Fields inherited from interface hudson.tasks.BuildStep
BUILDERS, PUBLISHERS
-
-
Constructor Summary
Constructors Constructor Description CNAuthProjectProperty(String project, boolean createRoles, String storedProjectId, boolean grantDefaultRoles)
Constructor
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
getCreateRoles()
static Collection<String>
getDefaultAdminRoles()
static Collection<String>
getDefaultUserRoles()
boolean
getGrantDefaultRoles()
String
getProject()
String
getProjectId()
void
setProjectId(String projectId)
Set the project id and reprocure the corresponding project name-
Methods inherited from class hudson.model.JobProperty
getDescriptor, getJobAction, getJobActions, getJobOverrides, getProjectAction, getProjectActions, getRequiredMonitorService, getSubTasks, perform, prebuild, reconfigure, setOwner
-
-
-
-
Field Detail
-
CONFIGURE_PROPERTY
public static final Permission CONFIGURE_PROPERTY
-
-
Constructor Detail
-
CNAuthProjectProperty
@DataBoundConstructor public CNAuthProjectProperty(String project, boolean createRoles, String storedProjectId, boolean grantDefaultRoles)
Constructor- Parameters:
project
- name of project to tie the auth tocreateRoles
- true to create special Jenkins rolesgrantDefaultRoles
- true to grant default roles to project members
-
-
Method Detail
-
getProject
public String getProject()
- Returns:
- the name of the CollabNet project.
-
getProjectId
public String getProjectId()
- Returns:
- the id of the TeamForge project.
-
setProjectId
public void setProjectId(String projectId)
Set the project id and reprocure the corresponding project name- Parameters:
projectId
- project id
-
getCreateRoles
public boolean getCreateRoles()
- Returns:
- true if creating the roles on the CollabNet server should be attempted.
-
getGrantDefaultRoles
public boolean getGrantDefaultRoles()
- Returns:
- true if the default roles should be added.
-
getDefaultUserRoles
public static Collection<String> getDefaultUserRoles()
- Returns:
- the default user roles. Lazily initialized.
-
getDefaultAdminRoles
public static Collection<String> getDefaultAdminRoles()
- Returns:
- the default admin roles. Lazily initialized.
-
-