Class WithScriptDescribable<T extends WithScriptDescribable<T>>
java.lang.Object
hudson.model.AbstractDescribableImpl<T>
org.jenkinsci.plugins.pipeline.modeldefinition.withscript.WithScriptDescribable<T>
- All Implemented Interfaces:
Describable<T>
,Serializable
- Direct Known Subclasses:
DeclarativeAgent
,DeclarativeStageConditional
public abstract class WithScriptDescribable<T extends WithScriptDescribable<T>>
extends AbstractDescribableImpl<T>
implements Serializable
Implementations for
WithScriptDescriptor
- pluggable script backends for Declarative Pipelines.- Author:
- Andrew Bayer
- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetScript
(org.jenkinsci.plugins.workflow.cps.CpsScript cpsScript) ONLY TO BE RUN FROM WITHIN A CPS THREAD.
-
Constructor Details
-
WithScriptDescribable
public WithScriptDescribable()
-
-
Method Details
-
getScript
public WithScriptScript getScript(org.jenkinsci.plugins.workflow.cps.CpsScript cpsScript) throws Exception ONLY TO BE RUN FROM WITHIN A CPS THREAD. Parses the script source and loads it. TODO: Decide if we want to cache the resulting objects or just *shrug* and re-parse them every time.- Returns:
- The script object for this.
- Throws:
Exception
- if the script source cannot be loaded or we're called from outside a CpsThread.
-
getDescriptor
- Specified by:
getDescriptor
in interfaceDescribable<T extends WithScriptDescribable<T>>
- Overrides:
getDescriptor
in classAbstractDescribableImpl<T extends WithScriptDescribable<T>>
-