org.jenkinsci.plugins.authorizeproject
Class AuthorizeProjectProperty

java.lang.Object
  extended by hudson.model.JobProperty<hudson.model.Job<?,?>>
      extended by org.jenkinsci.plugins.authorizeproject.AuthorizeProjectProperty
All Implemented Interfaces:
hudson.ExtensionPoint, hudson.model.Describable<hudson.model.JobProperty<?>>, hudson.model.ReconfigurableDescribable<hudson.model.JobProperty<?>>, hudson.tasks.BuildStep

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

Specifies how to authorize its builds.


Nested Class Summary
static class AuthorizeProjectProperty.DescriptorImpl
          Descriptor for AuthorizeProjectProperty.
 
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 String PROPERTYNAME
          Property name used for job configuration page.
 
Fields inherited from class hudson.model.JobProperty
owner
 
Fields inherited from interface hudson.tasks.BuildStep
BUILDERS, PUBLISHERS
 
Constructor Summary
AuthorizeProjectProperty(AuthorizeProjectStrategy strategy)
          Create a new instance.
 
Method Summary
 org.acegisecurity.Authentication authenticate(hudson.model.Queue.Item item)
          Return the authorization for a build.
 AuthorizeProjectStrategy getEnabledStrategy()
           
 AuthorizeProjectStrategy getStrategy()
           
 
Methods inherited from class hudson.model.JobProperty
getDescriptor, getJobAction, getJobActions, getJobOverrides, getProjectAction, getProjectActions, getRequiredMonitorService, getSubTasks, perform, prebuild, reconfigure, setOwner
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PROPERTYNAME

public static final String PROPERTYNAME
Property name used for job configuration page.

See Also:
Constant Field Values
Constructor Detail

AuthorizeProjectProperty

public AuthorizeProjectProperty(AuthorizeProjectStrategy strategy)
Create a new instance. Not annotated with DataBoundConstructor for instantiating explicitly in AuthorizeProjectProperty.DescriptorImpl.newInstance(StaplerRequest, JSONObject). It is required to call newInstance of AuthorizeProjectProperty.

Parameters:
strategy -
Method Detail

getStrategy

public AuthorizeProjectStrategy getStrategy()
Returns:

getEnabledStrategy

public AuthorizeProjectStrategy getEnabledStrategy()
Returns:
strategy only when it's enabled. null otherwise.

authenticate

public org.acegisecurity.Authentication authenticate(hudson.model.Queue.Item item)
Return the authorization for a build.

Parameters:
item - the item in queue, which will be a build.
Returns:
authorization for this build.
See Also:
AuthorizeProjectStrategy.authenticate(hudson.model.Job, hudson.model.Queue.Item)


Copyright © 2004-2015. All Rights Reserved.