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

net.nemerosa.ontrack.model.structure.BuildRequest Maven / Gradle / Ivy

There is a newer version: 4.4.5
Show newest version
package net.nemerosa.ontrack.model.structure;

import lombok.Data;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import java.beans.ConstructorProperties;
import java.util.Collections;
import java.util.List;

/**
 * 

Request data for the creation of a build.

*

Note that the version without the properties is usually the one which * is proposed to human clients when the one with properties is the one proposed * to automation clients (like CI engines).

*/ @Data public class BuildRequest { @NotNull(message = "The build name is required.") @Pattern(regexp = NameDescription.NAME, message = "The build name " + NameDescription.NAME_MESSAGE_SUFFIX) private final String name; private final String description; private final List properties; @ConstructorProperties({"name", "description", "properties"}) public BuildRequest(String name, String description, List properties) { this.name = name; this.description = description; this.properties = properties != null ? properties : Collections.emptyList(); } public NameDescription asNameDescription() { return new NameDescription(name, description); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy