Class LockableResourcesStruct
java.lang.Object
org.jenkins.plugins.lockableresources.queue.LockableResourcesStruct
- All Implemented Interfaces:
Serializable
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionlong
-
Constructor Summary
ConstructorDescriptionLockableResourcesStruct
(List<String> resources) Light-weight constructor for declaring a resource only.LockableResourcesStruct
(List<String> resources, String label, int quantity) LockableResourcesStruct
(List<String> resources, String label, int quantity, String variable) LockableResourcesStruct
(RequiredResourcesProperty property, EnvVars env) -
Method Summary
Modifier and TypeMethodDescriptionorg.jenkinsci.plugins.scriptsecurity.sandbox.groovy.SecureGroovyScript
Gets a system Groovy script to be executed in order to determine if theLockableResource
matches the condition.boolean
isResourceRequired
(LockableResource resource) Check if the *resource* is required by this struct / queuetoString()
-
Field Details
-
required
-
label
-
requiredVar
-
requiredNumber
-
queuedAt
public long queuedAt
-
-
Constructor Details
-
LockableResourcesStruct
-
LockableResourcesStruct
Light-weight constructor for declaring a resource only.- Parameters:
resources
- Resources to be required
-
LockableResourcesStruct
-
LockableResourcesStruct
-
-
Method Details
-
getResourceMatchScript
@CheckForNull public org.jenkinsci.plugins.scriptsecurity.sandbox.groovy.SecureGroovyScript getResourceMatchScript() throws Descriptor.FormExceptionGets a system Groovy script to be executed in order to determine if theLockableResource
matches the condition.- Returns:
- System Groovy Script if defined
- Throws:
Descriptor.FormException
- Since:
- 2.1
- See Also:
-
getResourceMatchScriptText
-
toString
-
isResourceRequired
@Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class) public boolean isResourceRequired(LockableResource resource) Check if the *resource* is required by this struct / queue
-