All Downloads are FREE. Search and download functionalities are using the official Maven repository.

cd.go.contrib.plugins.configrepo.groovy.dsl.Environment Maven / Gradle / Ivy

Go to download

Groovy DSL for GoCD pipeline definitions, for use with the gocd-groovy-dsl-plugin

There is a newer version: 2.2.0-752
Show newest version
// Generated by delombok at Sat Aug 03 22:05:14 PDT 2024
/*
 * Copyright 2022 Thoughtworks, Inc.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package cd.go.contrib.plugins.configrepo.groovy.dsl;

import com.fasterxml.jackson.annotation.JsonProperty;
import groovy.lang.Closure;
import groovy.lang.DelegatesTo;
import groovy.transform.stc.ClosureParams;
import groovy.transform.stc.SimpleType;
import java.util.List;
import static groovy.lang.Closure.DELEGATE_ONLY;

/**
 * Represents an environment in GoCD.
 * 

* {@includeCode environments-full.groovy} */ public class Environment extends HasEnvironmentVariables { /** * The list of pipelines that should be added into this environment. */ @JsonProperty("pipelines") private List pipelines; /** * The list of agents that should be added into this environment. */ @JsonProperty("agents") private List agents; public Environment() { this(null, null); } public Environment(String name) { this(name, null); } public Environment(String name, @DelegatesTo(value = Environment.class, strategy = DELEGATE_ONLY) @ClosureParams(value = SimpleType.class, options = "cd.go.contrib.plugins.configrepo.groovy.dsl.Environment") Closure cl) { super(name); configure(cl); } /** * The list of pipelines that should be added into this environment. */ @java.lang.SuppressWarnings("all") @lombok.Generated public List getPipelines() { return this.pipelines; } /** * The list of agents that should be added into this environment. */ @java.lang.SuppressWarnings("all") @lombok.Generated public List getAgents() { return this.agents; } /** * The list of pipelines that should be added into this environment. */ @JsonProperty("pipelines") @java.lang.SuppressWarnings("all") @lombok.Generated public void setPipelines(final List pipelines) { this.pipelines = pipelines; } /** * The list of agents that should be added into this environment. */ @JsonProperty("agents") @java.lang.SuppressWarnings("all") @lombok.Generated public void setAgents(final List agents) { this.agents = agents; } @java.lang.Override @java.lang.SuppressWarnings("all") @lombok.Generated public boolean equals(final java.lang.Object o) { if (o == this) return true; if (!(o instanceof Environment)) return false; final Environment other = (Environment) o; if (!other.canEqual((java.lang.Object) this)) return false; if (!super.equals(o)) return false; final java.lang.Object this$pipelines = this.getPipelines(); final java.lang.Object other$pipelines = other.getPipelines(); if (this$pipelines == null ? other$pipelines != null : !this$pipelines.equals(other$pipelines)) return false; final java.lang.Object this$agents = this.getAgents(); final java.lang.Object other$agents = other.getAgents(); if (this$agents == null ? other$agents != null : !this$agents.equals(other$agents)) return false; return true; } @java.lang.SuppressWarnings("all") @lombok.Generated protected boolean canEqual(final java.lang.Object other) { return other instanceof Environment; } @java.lang.Override @java.lang.SuppressWarnings("all") @lombok.Generated public int hashCode() { final int PRIME = 59; int result = super.hashCode(); final java.lang.Object $pipelines = this.getPipelines(); result = result * PRIME + ($pipelines == null ? 43 : $pipelines.hashCode()); final java.lang.Object $agents = this.getAgents(); result = result * PRIME + ($agents == null ? 43 : $agents.hashCode()); return result; } @java.lang.Override @java.lang.SuppressWarnings("all") @lombok.Generated public java.lang.String toString() { return "Environment(super=" + super.toString() + ", pipelines=" + this.getPipelines() + ", agents=" + this.getAgents() + ")"; } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy