hudson.plugins.collabnet.auth
Class CNAuthProjectProperty

java.lang.Object
  extended by hudson.model.JobProperty<hudson.model.Job<?,?>>
      extended by hudson.plugins.collabnet.auth.CNAuthProjectProperty
All Implemented Interfaces:
hudson.ExtensionPoint, hudson.model.Describable<hudson.model.JobProperty<?>>, hudson.tasks.BuildStep

public class CNAuthProjectProperty
extends hudson.model.JobProperty<hudson.model.Job<?,?>>

Job property to associate a Hudson job with a CollabNet Project for Authorization purposes (used with CollabNet Authorization).


Nested Class Summary
static class CNAuthProjectProperty.DescriptorImpl
          Descriptor class.
 
Nested classes/interfaces inherited from interface hudson.tasks.BuildStep
hudson.tasks.BuildStep.PublisherList
 
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
hudson.ExtensionPoint.LegacyInstancesAreScopedToHudson
 
Field Summary
static hudson.security.Permission CONFIGURE_PROPERTY
           
 
Fields inherited from class hudson.model.JobProperty
owner
 
Fields inherited from interface hudson.tasks.BuildStep
BUILDERS, PUBLISHERS
 
Constructor Summary
CNAuthProjectProperty(java.lang.String projectName, java.lang.Boolean createRoles, java.lang.Boolean grantDefaults, boolean isNotLoadedFromDisk)
          Constructor
 
Method Summary
 boolean createRoles()
           
 java.util.Collection<java.lang.String> getDefaultAdminRoles()
           
 java.util.Collection<java.lang.String> getDefaultUserRoles()
           
 java.lang.String getProject()
           
 java.lang.String getProjectId()
           
 boolean grantDefaultRoles()
           
 void setProjectId(java.lang.String projectId)
          Set the project id and reprocure the corresponding project name
 
Methods inherited from class hudson.model.JobProperty
getDescriptor, getJobAction, getProjectAction, getRequiredMonitorService, perform, prebuild, setOwner
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CONFIGURE_PROPERTY

public static hudson.security.Permission CONFIGURE_PROPERTY
Constructor Detail

CNAuthProjectProperty

public CNAuthProjectProperty(java.lang.String projectName,
                             java.lang.Boolean createRoles,
                             java.lang.Boolean grantDefaults,
                             boolean isNotLoadedFromDisk)
Constructor

Parameters:
projectName - name of project to tie the auth to
createRoles - true to create special hudson roles
grantDefaults - true to grant default roles to project members
isNotLoadedFromDisk - true for newly instantiated jobs
Method Detail

getProject

public java.lang.String getProject()
Returns:
the name of the CollabNet project.

getProjectId

public java.lang.String getProjectId()
Returns:
the id of the TeamForge project.

setProjectId

public void setProjectId(java.lang.String projectId)
Set the project id and reprocure the corresponding project name

Parameters:
projectId - project id

createRoles

public boolean createRoles()
Returns:
true if creating the roles on the CollabNet server should be attempted.

grantDefaultRoles

public boolean grantDefaultRoles()
Returns:
true if the default roles should be added.

getDefaultUserRoles

public java.util.Collection<java.lang.String> getDefaultUserRoles()
Returns:
the default user roles. Lazily initialized.

getDefaultAdminRoles

public java.util.Collection<java.lang.String> getDefaultAdminRoles()
Returns:
the default admin roles. Lazily initialized.


Copyright © 2010. All Rights Reserved.