C - a kind of credentialspublic abstract class MultiBinding<C extends com.cloudbees.plugins.credentials.common.StandardCredentials> extends AbstractDescribableImpl<MultiBinding<C>> implements ExtensionPoint
| Modifier and Type | Class and Description |
|---|---|
static class |
MultiBinding.MultiEnvironment
|
protected static class |
MultiBinding.NullUnbinder
No-op callback.
|
static interface |
MultiBinding.Unbinder
Callback run at the end of a build.
|
ExtensionPoint.LegacyInstancesAreScopedToHudson| Modifier | Constructor and Description |
|---|---|
protected |
MultiBinding(String credentialsId)
For use with
DataBoundConstructor. |
| Modifier and Type | Method and Description |
|---|---|
abstract MultiBinding.MultiEnvironment |
bind(Run<?,?> build,
FilePath workspace,
Launcher launcher,
TaskListener listener)
Sets up bindings for a build.
|
protected C |
getCredentials(Run<?,?> build)
Looks up the actual credentials.
|
String |
getCredentialsId()
Identifier of the credentials to be bound.
|
BindingDescriptor<C> |
getDescriptor() |
protected abstract Class<C> |
type()
Type token.
|
Set<String> |
variables()
Deprecated.
override
variables(Run) |
Set<String> |
variables(Run<?,?> build)
Defines keys expected to be set in
MultiBinding.MultiEnvironment.getSecretValues(), particularly any that might be sensitive. |
protected MultiBinding(String credentialsId)
DataBoundConstructor.public final String getCredentialsId()
public abstract MultiBinding.MultiEnvironment bind(@Nonnull Run<?,?> build, @Nullable FilePath workspace, @Nullable Launcher launcher, @Nonnull TaskListener listener) throws IOException, InterruptedException
build - The build. Cannot be nullworkspace - The workspace - can be null if BindingDescriptor.requiresWorkspace() is false.launcher - The launcher - can be null if BindingDescriptor.requiresWorkspace() is false.listener - The task listener. Cannot be null.MultiBinding.MultiEnvironmentIOExceptionInterruptedExceptionpublic Set<String> variables()
variables(Run)public Set<String> variables(@Nonnull Run<?,?> build) throws CredentialNotFoundException
MultiBinding.MultiEnvironment.getSecretValues(), particularly any that might be sensitive.CredentialNotFoundException@Nonnull protected final C getCredentials(@Nonnull Run<?,?> build) throws CredentialNotFoundException
build - the build.CredentialNotFoundException - if the credentials could not be found (for convenience, rather than returning null)public BindingDescriptor<C> getDescriptor()
getDescriptor in interface Describable<MultiBinding<C extends com.cloudbees.plugins.credentials.common.StandardCredentials>>getDescriptor in class AbstractDescribableImpl<MultiBinding<C extends com.cloudbees.plugins.credentials.common.StandardCredentials>>Copyright © 2016–2021. All rights reserved.