Class CredentialsProviderTypeRestrictionDescriptor
java.lang.Object
hudson.model.Descriptor<CredentialsProviderTypeRestriction>
com.cloudbees.plugins.credentials.CredentialsProviderTypeRestrictionDescriptor
- Direct Known Subclasses:
CredentialsProviderTypeRestriction.Excludes.DescriptorImpl,CredentialsProviderTypeRestriction.Includes.DescriptorImpl
public abstract class CredentialsProviderTypeRestrictionDescriptor
extends Descriptor<CredentialsProviderTypeRestriction>
The
Descriptor base class for CredentialsProviderTypeRestriction implementations.- Since:
- 2.0
-
Nested Class Summary
Nested classes/interfaces inherited from class hudson.model.Descriptor
Descriptor.FormException, Descriptor.PropertyType, Descriptor.Self -
Field Summary
Fields inherited from class hudson.model.Descriptor
clazz -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract booleanfilter(List<CredentialsProviderTypeRestriction> restrictions, CredentialsProvider provider, CredentialsDescriptor type) Computes the effectiveCredentialsProviderTypeRestriction.filter(CredentialsProvider, CredentialsDescriptor)result from the sublist of allCredentialsProviderTypeRestrictioninstances that use thisinstance.Methods inherited from class hudson.model.Descriptor
addHelpFileRedirect, bindJSON, bindJSON, calcAutoCompleteSettings, calcFillSettings, configure, configure, configure, doHelp, doHelp, find, find, findByDescribableClassName, findById, getCategory, getCheckMethod, getCheckUrl, getConfigFile, getConfigPage, getCurrentDescriptorByNameUrl, getDescriptorFullUrl, getDescriptorUrl, getDisplayName, getGlobalConfigPage, getGlobalPropertyType, getHelpFile, getHelpFile, getHelpFile, getId, getJsonSafeClassName, getKlass, getPlugin, getPossibleViewNames, getPropertyType, getPropertyType, getPropertyTypeOrDie, getRequiredGlobalConfigPagePermission, getStaticHelpUrl, getStaticHelpUrl, getT, getViewPage, isInstance, isSubTypeOf, load, newInstance, newInstance, newInstance, newInstancesFromHeteroList, newInstancesFromHeteroList, newInstancesFromHeteroList, newInstancesFromHeteroList, save, self, toArray, toList, toMap
-
Constructor Details
-
CredentialsProviderTypeRestrictionDescriptor
public CredentialsProviderTypeRestrictionDescriptor()
-
-
Method Details
-
filter
public abstract boolean filter(List<CredentialsProviderTypeRestriction> restrictions, CredentialsProvider provider, CredentialsDescriptor type) Computes the effectiveCredentialsProviderTypeRestriction.filter(CredentialsProvider, CredentialsDescriptor)result from the sublist of allCredentialsProviderTypeRestrictioninstances that use thisinstance. Each implementation can determine the policy to follow, typically implementations will from two styles:- Require at least one
CredentialsProviderTypeRestriction.filter(CredentialsProvider, CredentialsDescriptor)returningtrue - Require no
CredentialsProviderTypeRestriction.filter(CredentialsProvider, CredentialsDescriptor)returningfalse
- Parameters:
restrictions- the sublist ofCredentialsProviderManager.getRestrictions()that returnthisfromCredentialsProviderTypeRestriction.getDescriptor()provider- theCredentialsProviderto check.type- theCredentialsDescriptorto check.- Returns:
trueif and only if the suppliedCredentialsDescriptoris permitted in the scope of the suppliedCredentialsProvider
- Require at least one
-