Class PlannedNodeBuilder
java.lang.Object
org.csanchez.jenkins.plugins.kubernetes.PlannedNodeBuilder
- Direct Known Subclasses:
StandardPlannedNodeBuilder
A builder of
NodeProvisioner.PlannedNode
implementations for Kubernetes.
Can be subclassed to provide alternative implementations of NodeProvisioner.PlannedNode
.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionabstract NodeProvisioner.PlannedNode
build()
Builds theNodeProvisioner.PlannedNode
instance based on the given inputs.cloud
(KubernetesCloud cloud) getCloud()
Returns theKubernetesCloud
.getLabel()
int
Returns thePodTemplate
.numExecutors
(int numExecutors) template
(PodTemplate template)
-
Constructor Details
-
PlannedNodeBuilder
public PlannedNodeBuilder()
-
-
Method Details
-
getCloud
Returns theKubernetesCloud
.- Returns:
- the
KubernetesCloud
.
-
getTemplate
Returns thePodTemplate
.- Returns:
-
getLabel
-
getNumExecutors
public int getNumExecutors() -
cloud
- Parameters:
cloud
- theKubernetesCloud
instance to use.- Returns:
- the current builder.
-
template
- Parameters:
template
- thePodTemplate
instance to use.- Returns:
- the current builder.
-
label
- Parameters:
label
- theLabel
to use.- Returns:
- the current builder.
-
numExecutors
- Parameters:
numExecutors
- the number of executors.- Returns:
- the current builder.
-
build
Builds theNodeProvisioner.PlannedNode
instance based on the given inputs.- Returns:
- a
NodeProvisioner.PlannedNode
configured from this builder.
-