diff --git a/clients/google-api-services-artifactregistry/v1/2.0.0/README.md b/clients/google-api-services-artifactregistry/v1/2.0.0/README.md index e385ddc9b25..45d71cceef3 100644 --- a/clients/google-api-services-artifactregistry/v1/2.0.0/README.md +++ b/clients/google-api-services-artifactregistry/v1/2.0.0/README.md @@ -22,7 +22,7 @@ Add the following lines to your `pom.xml` file: com.google.apis google-api-services-artifactregistry - v1-rev20240903-2.0.0 + v1-rev20240923-2.0.0 @@ -35,7 +35,7 @@ repositories { mavenCentral() } dependencies { - implementation 'com.google.apis:google-api-services-artifactregistry:v1-rev20240903-2.0.0' + implementation 'com.google.apis:google-api-services-artifactregistry:v1-rev20240923-2.0.0' } ``` diff --git a/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/ArtifactRegistry.java b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/ArtifactRegistry.java index 582133f3224..ca2c7c6fd84 100644 --- a/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/ArtifactRegistry.java +++ b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/ArtifactRegistry.java @@ -2951,34 +2951,315 @@ public Upload set(String parameterName, Object value) { } /** - * An accessor for creating requests from the DockerImages collection. + * An accessor for creating requests from the Attachments collection. * *

The typical use is:

*
          *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
-         *   {@code ArtifactRegistry.DockerImages.List request = artifactregistry.dockerImages().list(parameters ...)}
+         *   {@code ArtifactRegistry.Attachments.List request = artifactregistry.attachments().list(parameters ...)}
          * 
* * @return the resource collection */ - public DockerImages dockerImages() { - return new DockerImages(); + public Attachments attachments() { + return new Attachments(); } /** - * The "dockerImages" collection of methods. + * The "attachments" collection of methods. */ - public class DockerImages { + public class Attachments { /** - * Gets a docker image. + * Creates an attachment. The returned Operation will finish once the attachment has been created. + * Its response will be the created Attachment. * - * Create a request for the method "dockerImages.get". + * Create a request for the method "attachments.create". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. + * + * @param parent Required. The name of the parent resource where the attachment will be created. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.Attachment} + * @return the request + */ + public Create create(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.Attachment content) throws java.io.IOException { + Create result = new Create(parent, content); + initialize(result); + return result; + } + + public class Create extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+parent}/attachments"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + + /** + * Creates an attachment. The returned Operation will finish once the attachment has been created. + * Its response will be the created Attachment. + * + * Create a request for the method "attachments.create". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. + *

{@link + * Create#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent Required. The name of the parent resource where the attachment will be created. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.Attachment} + * @since 1.13 + */ + protected Create(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.Attachment content) { + super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.Operation.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + } + } + + @Override + public Create set$Xgafv(java.lang.String $Xgafv) { + return (Create) super.set$Xgafv($Xgafv); + } + + @Override + public Create setAccessToken(java.lang.String accessToken) { + return (Create) super.setAccessToken(accessToken); + } + + @Override + public Create setAlt(java.lang.String alt) { + return (Create) super.setAlt(alt); + } + + @Override + public Create setCallback(java.lang.String callback) { + return (Create) super.setCallback(callback); + } + + @Override + public Create setFields(java.lang.String fields) { + return (Create) super.setFields(fields); + } + + @Override + public Create setKey(java.lang.String key) { + return (Create) super.setKey(key); + } + + @Override + public Create setOauthToken(java.lang.String oauthToken) { + return (Create) super.setOauthToken(oauthToken); + } + + @Override + public Create setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Create) super.setPrettyPrint(prettyPrint); + } + + @Override + public Create setQuotaUser(java.lang.String quotaUser) { + return (Create) super.setQuotaUser(quotaUser); + } + + @Override + public Create setUploadType(java.lang.String uploadType) { + return (Create) super.setUploadType(uploadType); + } + + @Override + public Create setUploadProtocol(java.lang.String uploadProtocol) { + return (Create) super.setUploadProtocol(uploadProtocol); + } + + /** Required. The name of the parent resource where the attachment will be created. */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** Required. The name of the parent resource where the attachment will be created. + */ + public java.lang.String getParent() { + return parent; + } + + /** Required. The name of the parent resource where the attachment will be created. */ + public Create setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + } + this.parent = parent; + return this; + } + + /** Required. The attachment id to use for this attachment. */ + @com.google.api.client.util.Key + private java.lang.String attachmentId; + + /** Required. The attachment id to use for this attachment. + */ + public java.lang.String getAttachmentId() { + return attachmentId; + } + + /** Required. The attachment id to use for this attachment. */ + public Create setAttachmentId(java.lang.String attachmentId) { + this.attachmentId = attachmentId; + return this; + } + + @Override + public Create set(String parameterName, Object value) { + return (Create) super.set(parameterName, value); + } + } + /** + * Deletes an attachment. The returned Operation will finish once the attachments has been deleted. + * It will not have any Operation metadata and will return a google.protobuf.Empty response. + * + * Create a request for the method "attachments.delete". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + * + * @param name Required. The name of the attachment to delete. + * @return the request + */ + public Delete delete(java.lang.String name) throws java.io.IOException { + Delete result = new Delete(name); + initialize(result); + return result; + } + + public class Delete extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/attachments/[^/]+$"); + + /** + * Deletes an attachment. The returned Operation will finish once the attachments has been + * deleted. It will not have any Operation metadata and will return a google.protobuf.Empty + * response. + * + * Create a request for the method "attachments.delete". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + *

{@link + * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name Required. The name of the attachment to delete. + * @since 1.13 + */ + protected Delete(java.lang.String name) { + super(ArtifactRegistry.this, "DELETE", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Operation.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/attachments/[^/]+$"); + } + } + + @Override + public Delete set$Xgafv(java.lang.String $Xgafv) { + return (Delete) super.set$Xgafv($Xgafv); + } + + @Override + public Delete setAccessToken(java.lang.String accessToken) { + return (Delete) super.setAccessToken(accessToken); + } + + @Override + public Delete setAlt(java.lang.String alt) { + return (Delete) super.setAlt(alt); + } + + @Override + public Delete setCallback(java.lang.String callback) { + return (Delete) super.setCallback(callback); + } + + @Override + public Delete setFields(java.lang.String fields) { + return (Delete) super.setFields(fields); + } + + @Override + public Delete setKey(java.lang.String key) { + return (Delete) super.setKey(key); + } + + @Override + public Delete setOauthToken(java.lang.String oauthToken) { + return (Delete) super.setOauthToken(oauthToken); + } + + @Override + public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Delete) super.setPrettyPrint(prettyPrint); + } + + @Override + public Delete setQuotaUser(java.lang.String quotaUser) { + return (Delete) super.setQuotaUser(quotaUser); + } + + @Override + public Delete setUploadType(java.lang.String uploadType) { + return (Delete) super.setUploadType(uploadType); + } + + @Override + public Delete setUploadProtocol(java.lang.String uploadProtocol) { + return (Delete) super.setUploadProtocol(uploadProtocol); + } + + /** Required. The name of the attachment to delete. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** Required. The name of the attachment to delete. + */ + public java.lang.String getName() { + return name; + } + + /** Required. The name of the attachment to delete. */ + public Delete setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/attachments/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Delete set(String parameterName, Object value) { + return (Delete) super.set(parameterName, value); + } + } + /** + * Gets an attachment. + * + * Create a request for the method "attachments.get". * * This request holds the parameters needed by the artifactregistry server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. * - * @param name Required. The name of the docker images. + * @param name Required. The name of the attachment to retrieve. * @return the request */ public Get get(java.lang.String name) throws java.io.IOException { @@ -2987,33 +3268,33 @@ public Get get(java.lang.String name) throws java.io.IOException { return result; } - public class Get extends ArtifactRegistryRequest { + public class Get extends ArtifactRegistryRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/dockerImages/[^/]+$"); + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/attachments/[^/]+$"); /** - * Gets a docker image. + * Gets an attachment. * - * Create a request for the method "dockerImages.get". + * Create a request for the method "attachments.get". * * This request holds the parameters needed by the the artifactregistry server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

* {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor.

* - * @param name Required. The name of the docker images. + * @param name Required. The name of the attachment to retrieve. * @since 1.13 */ protected Get(java.lang.String name) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.DockerImage.class); + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Attachment.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/dockerImages/[^/]+$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/attachments/[^/]+$"); } } @@ -3082,22 +3363,22 @@ public Get setUploadProtocol(java.lang.String uploadProtocol) { return (Get) super.setUploadProtocol(uploadProtocol); } - /** Required. The name of the docker images. */ + /** Required. The name of the attachment to retrieve. */ @com.google.api.client.util.Key private java.lang.String name; - /** Required. The name of the docker images. + /** Required. The name of the attachment to retrieve. */ public java.lang.String getName() { return name; } - /** Required. The name of the docker images. */ + /** Required. The name of the attachment to retrieve. */ public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/dockerImages/[^/]+$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/attachments/[^/]+$"); } this.name = name; return this; @@ -3109,14 +3390,14 @@ public Get set(String parameterName, Object value) { } } /** - * Lists docker images. + * Lists repositories. * - * Create a request for the method "dockerImages.list". + * Create a request for the method "attachments.list". * * This request holds the parameters needed by the artifactregistry server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation. * - * @param parent Required. The name of the parent resource whose docker images will be listed. + * @param parent Required. The name of the parent resource whose attachments will be listed. * @return the request */ public List list(java.lang.String parent) throws java.io.IOException { @@ -3125,28 +3406,28 @@ public List list(java.lang.String parent) throws java.io.IOException { return result; } - public class List extends ArtifactRegistryRequest { + public class List extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+parent}/dockerImages"; + private static final String REST_PATH = "v1/{+parent}/attachments"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); /** - * Lists docker images. + * Lists repositories. * - * Create a request for the method "dockerImages.list". + * Create a request for the method "attachments.list". * * This request holds the parameters needed by the the artifactregistry server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

* {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor.

* - * @param parent Required. The name of the parent resource whose docker images will be listed. + * @param parent Required. The name of the parent resource whose attachments will be listed. * @since 1.13 */ protected List(java.lang.String parent) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListDockerImagesResponse.class); + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListAttachmentsResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -3220,17 +3501,17 @@ public List setUploadProtocol(java.lang.String uploadProtocol) { return (List) super.setUploadProtocol(uploadProtocol); } - /** Required. The name of the parent resource whose docker images will be listed. */ + /** Required. The name of the parent resource whose attachments will be listed. */ @com.google.api.client.util.Key private java.lang.String parent; - /** Required. The name of the parent resource whose docker images will be listed. + /** Required. The name of the parent resource whose attachments will be listed. */ public java.lang.String getParent() { return parent; } - /** Required. The name of the parent resource whose docker images will be listed. */ + /** Required. The name of the parent resource whose attachments will be listed. */ public List setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -3241,33 +3522,42 @@ public List setParent(java.lang.String parent) { return this; } - /** The field to order the results by. */ + /** + * Optional. An expression for filtering the results of the request. Filter rules are + * case insensitive. The fields eligible for filtering are: * `target` * `type` * + * `attachment_namespace` + */ @com.google.api.client.util.Key - private java.lang.String orderBy; + private java.lang.String filter; - /** The field to order the results by. + /** Optional. An expression for filtering the results of the request. Filter rules are case + insensitive. The fields eligible for filtering are: * `target` * `type` * `attachment_namespace` */ - public java.lang.String getOrderBy() { - return orderBy; + public java.lang.String getFilter() { + return filter; } - /** The field to order the results by. */ - public List setOrderBy(java.lang.String orderBy) { - this.orderBy = orderBy; + /** + * Optional. An expression for filtering the results of the request. Filter rules are + * case insensitive. The fields eligible for filtering are: * `target` * `type` * + * `attachment_namespace` + */ + public List setFilter(java.lang.String filter) { + this.filter = filter; return this; } - /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + /** The maximum number of attachments to return. Maximum page size is 1,000. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; - /** The maximum number of artifacts to return. Maximum page size is 1,000. + /** The maximum number of attachments to return. Maximum page size is 1,000. */ public java.lang.Integer getPageSize() { return pageSize; } - /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + /** The maximum number of attachments to return. Maximum page size is 1,000. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; @@ -3297,226 +3587,208 @@ public List set(String parameterName, Object value) { } /** - * An accessor for creating requests from the Files collection. + * An accessor for creating requests from the DockerImages collection. * *

The typical use is:

*
          *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
-         *   {@code ArtifactRegistry.Files.List request = artifactregistry.files().list(parameters ...)}
+         *   {@code ArtifactRegistry.DockerImages.List request = artifactregistry.dockerImages().list(parameters ...)}
          * 
* * @return the resource collection */ - public Files files() { - return new Files(); + public DockerImages dockerImages() { + return new DockerImages(); } /** - * The "files" collection of methods. + * The "dockerImages" collection of methods. */ - public class Files { + public class DockerImages { /** - * Deletes a file and all of its content. It is only allowed on generic repositories. The returned - * operation will complete once the file has been deleted. + * Gets a docker image. * - * Create a request for the method "files.delete". + * Create a request for the method "dockerImages.get". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. * - * @param name Required. The name of the file to delete. + * @param name Required. The name of the docker images. * @return the request */ - public Delete delete(java.lang.String name) throws java.io.IOException { - Delete result = new Delete(name); + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); initialize(result); return result; } - public class Delete extends ArtifactRegistryRequest { + public class Get extends ArtifactRegistryRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/dockerImages/[^/]+$"); /** - * Deletes a file and all of its content. It is only allowed on generic repositories. The returned - * operation will complete once the file has been deleted. + * Gets a docker image. * - * Create a request for the method "files.delete". + * Create a request for the method "dockerImages.get". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. - *

{@link - * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must - * be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

* - * @param name Required. The name of the file to delete. + * @param name Required. The name of the docker images. * @since 1.13 */ - protected Delete(java.lang.String name) { - super(ArtifactRegistry.this, "DELETE", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Operation.class); + protected Get(java.lang.String name) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.DockerImage.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/dockerImages/[^/]+$"); } } @Override - public Delete set$Xgafv(java.lang.String $Xgafv) { - return (Delete) super.set$Xgafv($Xgafv); + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); } @Override - public Delete setAccessToken(java.lang.String accessToken) { - return (Delete) super.setAccessToken(accessToken); + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); } @Override - public Delete setAlt(java.lang.String alt) { - return (Delete) super.setAlt(alt); + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); } @Override - public Delete setCallback(java.lang.String callback) { - return (Delete) super.setCallback(callback); + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); } @Override - public Delete setFields(java.lang.String fields) { - return (Delete) super.setFields(fields); + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); } @Override - public Delete setKey(java.lang.String key) { - return (Delete) super.setKey(key); + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); } @Override - public Delete setOauthToken(java.lang.String oauthToken) { - return (Delete) super.setOauthToken(oauthToken); + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); } @Override - public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Delete) super.setPrettyPrint(prettyPrint); + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); } @Override - public Delete setQuotaUser(java.lang.String quotaUser) { - return (Delete) super.setQuotaUser(quotaUser); + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); } @Override - public Delete setUploadType(java.lang.String uploadType) { - return (Delete) super.setUploadType(uploadType); + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); } @Override - public Delete setUploadProtocol(java.lang.String uploadProtocol) { - return (Delete) super.setUploadProtocol(uploadProtocol); + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); } - /** Required. The name of the file to delete. */ + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** Required. The name of the docker images. */ @com.google.api.client.util.Key private java.lang.String name; - /** Required. The name of the file to delete. + /** Required. The name of the docker images. */ public java.lang.String getName() { return name; } - /** Required. The name of the file to delete. */ - public Delete setName(java.lang.String name) { + /** Required. The name of the docker images. */ + public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/dockerImages/[^/]+$"); } this.name = name; return this; } @Override - public Delete set(String parameterName, Object value) { - return (Delete) super.set(parameterName, value); + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); } } /** - * Download a file. + * Lists docker images. * - * Create a request for the method "files.download". + * Create a request for the method "dockerImages.list". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Download#execute()} method to invoke the remote operation. + * optional parameters, call the {@link List#execute()} method to invoke the remote operation. * - * @param name Required. The name of the file to download. + * @param parent Required. The name of the parent resource whose docker images will be listed. * @return the request */ - public Download download(java.lang.String name) throws java.io.IOException { - Download result = new Download(name); + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); initialize(result); return result; } - public class Download extends ArtifactRegistryRequest { + public class List extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+name}:download"; + private static final String REST_PATH = "v1/{+parent}/dockerImages"; - private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); /** - * Download a file. + * Lists docker images. * - * Create a request for the method "files.download". + * Create a request for the method "dockerImages.list". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Download#execute()} method to invoke the remote operation. - *

{@link - * Download#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor.

* - * @param name Required. The name of the file to download. + * @param parent Required. The name of the parent resource whose docker images will be listed. * @since 1.13 */ - protected Download(java.lang.String name) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.DownloadFileResponse.class); - this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + protected List(java.lang.String parent) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListDockerImagesResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); } - initializeMediaDownload(); - } - - @Override - public void executeMediaAndDownloadTo(java.io.OutputStream outputStream) throws java.io.IOException { - super.executeMediaAndDownloadTo(outputStream); - } - - @Override - public java.io.InputStream executeMediaAsInputStream() throws java.io.IOException { - return super.executeMediaAsInputStream(); - } - - @Override - public com.google.api.client.http.HttpResponse executeMedia() throws java.io.IOException { - return super.executeMedia(); - } - - @Override - public com.google.api.client.http.GenericUrl buildHttpRequestUrl() { - java.lang.String baseUrl = ("media".equals(get("alt")) && getMediaHttpUploader() == null) - ? getRootUrl() + "download/" + getServicePath() : getBaseUrl(); - return new com.google.api.client.http.GenericUrl( - com.google.api.client.http.UriTemplate.expand(baseUrl, getUriTemplate(), this, true)); } @Override @@ -3530,814 +3802,629 @@ public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws } @Override - public Download set$Xgafv(java.lang.String $Xgafv) { - return (Download) super.set$Xgafv($Xgafv); + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); } @Override - public Download setAccessToken(java.lang.String accessToken) { - return (Download) super.setAccessToken(accessToken); + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); } @Override - public Download setAlt(java.lang.String alt) { - return (Download) super.setAlt(alt); + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); } @Override - public Download setCallback(java.lang.String callback) { - return (Download) super.setCallback(callback); + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); } @Override - public Download setFields(java.lang.String fields) { - return (Download) super.setFields(fields); + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); } @Override - public Download setKey(java.lang.String key) { - return (Download) super.setKey(key); + public List setKey(java.lang.String key) { + return (List) super.setKey(key); } @Override - public Download setOauthToken(java.lang.String oauthToken) { - return (Download) super.setOauthToken(oauthToken); + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); } @Override - public Download setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Download) super.setPrettyPrint(prettyPrint); + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); } @Override - public Download setQuotaUser(java.lang.String quotaUser) { - return (Download) super.setQuotaUser(quotaUser); + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); } @Override - public Download setUploadType(java.lang.String uploadType) { - return (Download) super.setUploadType(uploadType); + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); } @Override - public Download setUploadProtocol(java.lang.String uploadProtocol) { - return (Download) super.setUploadProtocol(uploadProtocol); + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); } - /** Required. The name of the file to download. */ + /** Required. The name of the parent resource whose docker images will be listed. */ @com.google.api.client.util.Key - private java.lang.String name; + private java.lang.String parent; - /** Required. The name of the file to download. + /** Required. The name of the parent resource whose docker images will be listed. */ - public java.lang.String getName() { - return name; + public java.lang.String getParent() { + return parent; } - /** Required. The name of the file to download. */ - public Download setName(java.lang.String name) { + /** Required. The name of the parent resource whose docker images will be listed. */ + public List setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); } - this.name = name; + this.parent = parent; + return this; + } + + /** The field to order the results by. */ + @com.google.api.client.util.Key + private java.lang.String orderBy; + + /** The field to order the results by. + */ + public java.lang.String getOrderBy() { + return orderBy; + } + + /** The field to order the results by. */ + public List setOrderBy(java.lang.String orderBy) { + this.orderBy = orderBy; + return this; + } + + /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** The maximum number of artifacts to return. Maximum page size is 1,000. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** The next_page_token value returned from a previous list request, if any. */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** The next_page_token value returned from a previous list request, if any. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** The next_page_token value returned from a previous list request, if any. */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; return this; } @Override - public Download set(String parameterName, Object value) { - return (Download) super.set(parameterName, value); + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); } } + + } + /** + * An accessor for creating requests from the Files collection. + * + *

The typical use is:

+ *
+         *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
+         *   {@code ArtifactRegistry.Files.List request = artifactregistry.files().list(parameters ...)}
+         * 
+ * + * @return the resource collection + */ + public Files files() { + return new Files(); + } + + /** + * The "files" collection of methods. + */ + public class Files { + /** - * Gets a file. + * Deletes a file and all of its content. It is only allowed on generic repositories. The returned + * operation will complete once the file has been deleted. * - * Create a request for the method "files.get". + * Create a request for the method "files.delete". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. + * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. * - * @param name Required. The name of the file to retrieve. + * @param name Required. The name of the file to delete. * @return the request */ - public Get get(java.lang.String name) throws java.io.IOException { - Get result = new Get(name); + public Delete delete(java.lang.String name) throws java.io.IOException { + Delete result = new Delete(name); initialize(result); return result; } - public class Get extends ArtifactRegistryRequest { + public class Delete extends ArtifactRegistryRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/.*$"); + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); /** - * Gets a file. + * Deletes a file and all of its content. It is only allowed on generic repositories. The returned + * operation will complete once the file has been deleted. * - * Create a request for the method "files.get". + * Create a request for the method "files.delete". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

- * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} - * must be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + *

{@link + * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

* - * @param name Required. The name of the file to retrieve. + * @param name Required. The name of the file to delete. * @since 1.13 */ - protected Get(java.lang.String name) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1File.class); + protected Delete(java.lang.String name) { + super(ArtifactRegistry.this, "DELETE", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Operation.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/.*$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); } } @Override - public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { - return super.executeUsingHead(); - } - - @Override - public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { - return super.buildHttpRequestUsingHead(); - } - - @Override - public Get set$Xgafv(java.lang.String $Xgafv) { - return (Get) super.set$Xgafv($Xgafv); + public Delete set$Xgafv(java.lang.String $Xgafv) { + return (Delete) super.set$Xgafv($Xgafv); } @Override - public Get setAccessToken(java.lang.String accessToken) { - return (Get) super.setAccessToken(accessToken); + public Delete setAccessToken(java.lang.String accessToken) { + return (Delete) super.setAccessToken(accessToken); } @Override - public Get setAlt(java.lang.String alt) { - return (Get) super.setAlt(alt); + public Delete setAlt(java.lang.String alt) { + return (Delete) super.setAlt(alt); } @Override - public Get setCallback(java.lang.String callback) { - return (Get) super.setCallback(callback); + public Delete setCallback(java.lang.String callback) { + return (Delete) super.setCallback(callback); } @Override - public Get setFields(java.lang.String fields) { - return (Get) super.setFields(fields); + public Delete setFields(java.lang.String fields) { + return (Delete) super.setFields(fields); } @Override - public Get setKey(java.lang.String key) { - return (Get) super.setKey(key); + public Delete setKey(java.lang.String key) { + return (Delete) super.setKey(key); } @Override - public Get setOauthToken(java.lang.String oauthToken) { - return (Get) super.setOauthToken(oauthToken); + public Delete setOauthToken(java.lang.String oauthToken) { + return (Delete) super.setOauthToken(oauthToken); } @Override - public Get setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Get) super.setPrettyPrint(prettyPrint); + public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Delete) super.setPrettyPrint(prettyPrint); } @Override - public Get setQuotaUser(java.lang.String quotaUser) { - return (Get) super.setQuotaUser(quotaUser); + public Delete setQuotaUser(java.lang.String quotaUser) { + return (Delete) super.setQuotaUser(quotaUser); } @Override - public Get setUploadType(java.lang.String uploadType) { - return (Get) super.setUploadType(uploadType); + public Delete setUploadType(java.lang.String uploadType) { + return (Delete) super.setUploadType(uploadType); } @Override - public Get setUploadProtocol(java.lang.String uploadProtocol) { - return (Get) super.setUploadProtocol(uploadProtocol); + public Delete setUploadProtocol(java.lang.String uploadProtocol) { + return (Delete) super.setUploadProtocol(uploadProtocol); } - /** Required. The name of the file to retrieve. */ + /** Required. The name of the file to delete. */ @com.google.api.client.util.Key private java.lang.String name; - /** Required. The name of the file to retrieve. + /** Required. The name of the file to delete. */ public java.lang.String getName() { return name; } - /** Required. The name of the file to retrieve. */ - public Get setName(java.lang.String name) { + /** Required. The name of the file to delete. */ + public Delete setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/.*$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); } this.name = name; return this; } @Override - public Get set(String parameterName, Object value) { - return (Get) super.set(parameterName, value); + public Delete set(String parameterName, Object value) { + return (Delete) super.set(parameterName, value); } } /** - * Lists files. + * Download a file. * - * Create a request for the method "files.list". + * Create a request for the method "files.download". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link List#execute()} method to invoke the remote operation. + * optional parameters, call the {@link Download#execute()} method to invoke the remote operation. * - * @param parent Required. The name of the repository whose files will be listed. For example: - * "projects/p1/locations/us-central1/repositories/repo1 + * @param name Required. The name of the file to download. * @return the request */ - public List list(java.lang.String parent) throws java.io.IOException { - List result = new List(parent); + public Download download(java.lang.String name) throws java.io.IOException { + Download result = new Download(name); initialize(result); return result; } - public class List extends ArtifactRegistryRequest { + public class Download extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+parent}/files"; + private static final String REST_PATH = "v1/{+name}:download"; - private final java.util.regex.Pattern PARENT_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); /** - * Lists files. + * Download a file. * - * Create a request for the method "files.list". + * Create a request for the method "files.download". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

- * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * optional parameters, call the {@link Download#execute()} method to invoke the remote operation. + *

{@link + * Download#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor.

* - * @param parent Required. The name of the repository whose files will be listed. For example: - * "projects/p1/locations/us-central1/repositories/repo1 + * @param name Required. The name of the file to download. * @since 1.13 */ - protected List(java.lang.String parent) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListFilesResponse.class); - this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + protected Download(java.lang.String name) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.DownloadFileResponse.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); } + initializeMediaDownload(); } @Override - public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { - return super.executeUsingHead(); + public void executeMediaAndDownloadTo(java.io.OutputStream outputStream) throws java.io.IOException { + super.executeMediaAndDownloadTo(outputStream); } @Override - public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { - return super.buildHttpRequestUsingHead(); + public java.io.InputStream executeMediaAsInputStream() throws java.io.IOException { + return super.executeMediaAsInputStream(); } @Override - public List set$Xgafv(java.lang.String $Xgafv) { - return (List) super.set$Xgafv($Xgafv); + public com.google.api.client.http.HttpResponse executeMedia() throws java.io.IOException { + return super.executeMedia(); } @Override - public List setAccessToken(java.lang.String accessToken) { - return (List) super.setAccessToken(accessToken); + public com.google.api.client.http.GenericUrl buildHttpRequestUrl() { + java.lang.String baseUrl = ("media".equals(get("alt")) && getMediaHttpUploader() == null) + ? getRootUrl() + "download/" + getServicePath() : getBaseUrl(); + return new com.google.api.client.http.GenericUrl( + com.google.api.client.http.UriTemplate.expand(baseUrl, getUriTemplate(), this, true)); } @Override - public List setAlt(java.lang.String alt) { - return (List) super.setAlt(alt); + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); } @Override - public List setCallback(java.lang.String callback) { - return (List) super.setCallback(callback); + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); } @Override - public List setFields(java.lang.String fields) { - return (List) super.setFields(fields); + public Download set$Xgafv(java.lang.String $Xgafv) { + return (Download) super.set$Xgafv($Xgafv); } @Override - public List setKey(java.lang.String key) { - return (List) super.setKey(key); + public Download setAccessToken(java.lang.String accessToken) { + return (Download) super.setAccessToken(accessToken); } @Override - public List setOauthToken(java.lang.String oauthToken) { - return (List) super.setOauthToken(oauthToken); + public Download setAlt(java.lang.String alt) { + return (Download) super.setAlt(alt); } @Override - public List setPrettyPrint(java.lang.Boolean prettyPrint) { - return (List) super.setPrettyPrint(prettyPrint); + public Download setCallback(java.lang.String callback) { + return (Download) super.setCallback(callback); } @Override - public List setQuotaUser(java.lang.String quotaUser) { - return (List) super.setQuotaUser(quotaUser); + public Download setFields(java.lang.String fields) { + return (Download) super.setFields(fields); } @Override - public List setUploadType(java.lang.String uploadType) { - return (List) super.setUploadType(uploadType); + public Download setKey(java.lang.String key) { + return (Download) super.setKey(key); } @Override - public List setUploadProtocol(java.lang.String uploadProtocol) { - return (List) super.setUploadProtocol(uploadProtocol); - } - - /** - * Required. The name of the repository whose files will be listed. For example: - * "projects/p1/locations/us-central1/repositories/repo1 - */ - @com.google.api.client.util.Key - private java.lang.String parent; - - /** Required. The name of the repository whose files will be listed. For example: - "projects/p1/locations/us-central1/repositories/repo1 - */ - public java.lang.String getParent() { - return parent; - } - - /** - * Required. The name of the repository whose files will be listed. For example: - * "projects/p1/locations/us-central1/repositories/repo1 - */ - public List setParent(java.lang.String parent) { - if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); - } - this.parent = parent; - return this; - } - - /** - * An expression for filtering the results of the request. Filter rules are case - * insensitive. The fields eligible for filtering are: * `name` * `owner` * - * `annotations` Examples of using a filter: To filter the results of your request to - * files with the name `my_file.txt` in project `my-project` in the `us-central` region, - * in repository `my-repo`, append the following filter expression to your request: * - * `name="projects/my-project/locations/us-central1/repositories/my-repo/files/my- - * file.txt"` You can also use wildcards to match any number of characters before or - * after the value: * `name="projects/my-project/locations/us-central1/repositories/my- - * repo/files/my-*"` * `name="projects/my-project/locations/us-central1/repositories/my- - * repo/filesfile.txt"` * `name="projects/my-project/locations/us- - * central1/repositories/my-repo/filesfile*"` To filter the results of your request to - * files owned by the version `1.0` in package `pkg1`, append the following filter - * expression to your request: * `owner="projects/my-project/locations/us- - * central1/repositories/my-repo/packages/my-package/versions/1.0"` To filter the - * results of your request to files with the annotation key-value pair [`external_link`: - * `external_link_value`], append the following filter expression to your request: * - * `"annotations.external_link:external_link_value"` To filter just for a specific - * annotation key `external_link`, append the following filter expression to your - * request: * `"annotations.external_link"` If the annotation key or value contains - * special characters, you can escape them by surrounding the value with backticks. For - * example, to filter the results of your request to files with the annotation key-value - * pair [`external.link`:`https://example.com/my-file`], append the following filter - * expression to your request: * `` - * "annotations.`external.link`:`https://example.com/my-file`" `` You can also filter - * with annotations with a wildcard to match any number of characters before or after - * the value: * `` "annotations.*_link:`*example.com*`" `` - */ - @com.google.api.client.util.Key - private java.lang.String filter; - - /** An expression for filtering the results of the request. Filter rules are case insensitive. The - fields eligible for filtering are: * `name` * `owner` * `annotations` Examples of using a filter: - To filter the results of your request to files with the name `my_file.txt` in project `my-project` - in the `us-central` region, in repository `my-repo`, append the following filter expression to your - request: * `name="projects/my-project/locations/us-central1/repositories/my-repo/files/my- - file.txt"` You can also use wildcards to match any number of characters before or after the value: - * `name="projects/my-project/locations/us-central1/repositories/my-repo/files/my-*"` * - `name="projects/my-project/locations/us-central1/repositories/my-repo/filesfile.txt"` * - `name="projects/my-project/locations/us-central1/repositories/my-repo/filesfile*"` To filter the - results of your request to files owned by the version `1.0` in package `pkg1`, append the following - filter expression to your request: * `owner="projects/my-project/locations/us- - central1/repositories/my-repo/packages/my-package/versions/1.0"` To filter the results of your - request to files with the annotation key-value pair [`external_link`: `external_link_value`], - append the following filter expression to your request: * - `"annotations.external_link:external_link_value"` To filter just for a specific annotation key - `external_link`, append the following filter expression to your request: * - `"annotations.external_link"` If the annotation key or value contains special characters, you can - escape them by surrounding the value with backticks. For example, to filter the results of your - request to files with the annotation key-value pair [`external.link`:`https://example.com/my- - file`], append the following filter expression to your request: * `` - "annotations.`external.link`:`https://example.com/my-file`" `` You can also filter with annotations - with a wildcard to match any number of characters before or after the value: * `` - "annotations.*_link:`*example.com*`" `` - */ - public java.lang.String getFilter() { - return filter; - } - - /** - * An expression for filtering the results of the request. Filter rules are case - * insensitive. The fields eligible for filtering are: * `name` * `owner` * - * `annotations` Examples of using a filter: To filter the results of your request to - * files with the name `my_file.txt` in project `my-project` in the `us-central` region, - * in repository `my-repo`, append the following filter expression to your request: * - * `name="projects/my-project/locations/us-central1/repositories/my-repo/files/my- - * file.txt"` You can also use wildcards to match any number of characters before or - * after the value: * `name="projects/my-project/locations/us-central1/repositories/my- - * repo/files/my-*"` * `name="projects/my-project/locations/us-central1/repositories/my- - * repo/filesfile.txt"` * `name="projects/my-project/locations/us- - * central1/repositories/my-repo/filesfile*"` To filter the results of your request to - * files owned by the version `1.0` in package `pkg1`, append the following filter - * expression to your request: * `owner="projects/my-project/locations/us- - * central1/repositories/my-repo/packages/my-package/versions/1.0"` To filter the - * results of your request to files with the annotation key-value pair [`external_link`: - * `external_link_value`], append the following filter expression to your request: * - * `"annotations.external_link:external_link_value"` To filter just for a specific - * annotation key `external_link`, append the following filter expression to your - * request: * `"annotations.external_link"` If the annotation key or value contains - * special characters, you can escape them by surrounding the value with backticks. For - * example, to filter the results of your request to files with the annotation key-value - * pair [`external.link`:`https://example.com/my-file`], append the following filter - * expression to your request: * `` - * "annotations.`external.link`:`https://example.com/my-file`" `` You can also filter - * with annotations with a wildcard to match any number of characters before or after - * the value: * `` "annotations.*_link:`*example.com*`" `` - */ - public List setFilter(java.lang.String filter) { - this.filter = filter; - return this; + public Download setOauthToken(java.lang.String oauthToken) { + return (Download) super.setOauthToken(oauthToken); } - /** The field to order the results by. */ - @com.google.api.client.util.Key - private java.lang.String orderBy; - - /** The field to order the results by. - */ - public java.lang.String getOrderBy() { - return orderBy; + @Override + public Download setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Download) super.setPrettyPrint(prettyPrint); } - /** The field to order the results by. */ - public List setOrderBy(java.lang.String orderBy) { - this.orderBy = orderBy; - return this; + @Override + public Download setQuotaUser(java.lang.String quotaUser) { + return (Download) super.setQuotaUser(quotaUser); } - /** The maximum number of files to return. Maximum page size is 1,000. */ - @com.google.api.client.util.Key - private java.lang.Integer pageSize; - - /** The maximum number of files to return. Maximum page size is 1,000. - */ - public java.lang.Integer getPageSize() { - return pageSize; + @Override + public Download setUploadType(java.lang.String uploadType) { + return (Download) super.setUploadType(uploadType); } - /** The maximum number of files to return. Maximum page size is 1,000. */ - public List setPageSize(java.lang.Integer pageSize) { - this.pageSize = pageSize; - return this; + @Override + public Download setUploadProtocol(java.lang.String uploadProtocol) { + return (Download) super.setUploadProtocol(uploadProtocol); } - /** The next_page_token value returned from a previous list request, if any. */ + /** Required. The name of the file to download. */ @com.google.api.client.util.Key - private java.lang.String pageToken; + private java.lang.String name; - /** The next_page_token value returned from a previous list request, if any. + /** Required. The name of the file to download. */ - public java.lang.String getPageToken() { - return pageToken; + public java.lang.String getName() { + return name; } - /** The next_page_token value returned from a previous list request, if any. */ - public List setPageToken(java.lang.String pageToken) { - this.pageToken = pageToken; + /** Required. The name of the file to download. */ + public Download setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); + } + this.name = name; return this; } @Override - public List set(String parameterName, Object value) { - return (List) super.set(parameterName, value); + public Download set(String parameterName, Object value) { + return (Download) super.set(parameterName, value); } } - - } - /** - * An accessor for creating requests from the GenericArtifacts collection. - * - *

The typical use is:

- *
-         *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
-         *   {@code ArtifactRegistry.GenericArtifacts.List request = artifactregistry.genericArtifacts().list(parameters ...)}
-         * 
- * - * @return the resource collection - */ - public GenericArtifacts genericArtifacts() { - return new GenericArtifacts(); - } - - /** - * The "genericArtifacts" collection of methods. - */ - public class GenericArtifacts { - /** - * Directly uploads a Generic artifact. The returned operation will complete once the resources are - * uploaded. Package, version, and file resources are created based on the uploaded artifact. - * Uploaded artifacts that conflict with existing resources will raise an `ALREADY_EXISTS` error. + * Gets a file. * - * Create a request for the method "genericArtifacts.upload". + * Create a request for the method "files.get". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. * - * @param parent The resource name of the repository where the generic artifact will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest} + * @param name Required. The name of the file to retrieve. * @return the request */ - public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest content) throws java.io.IOException { - Upload result = new Upload(parent, content); + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); initialize(result); return result; } - /** - * Directly uploads a Generic artifact. The returned operation will complete once the resources are - * uploaded. Package, version, and file resources are created based on the uploaded artifact. - * Uploaded artifacts that conflict with existing resources will raise an `ALREADY_EXISTS` error. - * - * Create a request for the method "genericArtifacts.upload". - * - * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. - * - *

- * This method should be used for uploading media content. - *

- * - * @param parent The resource name of the repository where the generic artifact will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest} media metadata or {@code null} if none - * @param mediaContent The media HTTP content. - * @return the request - * @throws java.io.IOException if the initialization of the request fails - */ - public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws java.io.IOException { - Upload result = new Upload(parent, content, mediaContent); - initialize(result); - return result; - } - - public class Upload extends ArtifactRegistryRequest { + public class Get extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+parent}/genericArtifacts:create"; + private static final String REST_PATH = "v1/{+name}"; - private final java.util.regex.Pattern PARENT_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/.*$"); /** - * Directly uploads a Generic artifact. The returned operation will complete once the resources - * are uploaded. Package, version, and file resources are created based on the uploaded artifact. - * Uploaded artifacts that conflict with existing resources will raise an `ALREADY_EXISTS` error. + * Gets a file. * - * Create a request for the method "genericArtifacts.upload". + * Create a request for the method "files.get". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. - *

{@link - * Upload#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must - * be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

* - * @param parent The resource name of the repository where the generic artifact will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest} + * @param name Required. The name of the file to retrieve. * @since 1.13 */ - protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest content) { - super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactMediaResponse.class); - this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + protected Get(java.lang.String name) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1File.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/.*$"); } } - /** - * Directly uploads a Generic artifact. The returned operation will complete once the resources - * are uploaded. Package, version, and file resources are created based on the uploaded artifact. - * Uploaded artifacts that conflict with existing resources will raise an `ALREADY_EXISTS` error. - * - * Create a request for the method "genericArtifacts.upload". - * - * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. - *

{@link - * Upload#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must - * be called to initialize this instance immediately after invoking the constructor.

- * - *

- * This constructor should be used for uploading media content. - *

- * - * @param parent The resource name of the repository where the generic artifact will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest} media metadata or {@code null} if none - * @param mediaContent The media HTTP content. - * @since 1.13 - */ - protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) { - super(ArtifactRegistry.this, "POST", "/upload/" + getServicePath() + REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactMediaResponse.class); - this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); - com.google.api.client.util.Preconditions.checkNotNull(mediaContent, "Required parameter mediaContent must be specified."); - initializeMediaUpload(mediaContent); + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); } @Override - public Upload set$Xgafv(java.lang.String $Xgafv) { - return (Upload) super.set$Xgafv($Xgafv); + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); } @Override - public Upload setAccessToken(java.lang.String accessToken) { - return (Upload) super.setAccessToken(accessToken); + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); } @Override - public Upload setAlt(java.lang.String alt) { - return (Upload) super.setAlt(alt); + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); } @Override - public Upload setCallback(java.lang.String callback) { - return (Upload) super.setCallback(callback); + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); } @Override - public Upload setFields(java.lang.String fields) { - return (Upload) super.setFields(fields); + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); } @Override - public Upload setKey(java.lang.String key) { - return (Upload) super.setKey(key); + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); } @Override - public Upload setOauthToken(java.lang.String oauthToken) { - return (Upload) super.setOauthToken(oauthToken); + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); } @Override - public Upload setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Upload) super.setPrettyPrint(prettyPrint); + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); } @Override - public Upload setQuotaUser(java.lang.String quotaUser) { - return (Upload) super.setQuotaUser(quotaUser); + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); } @Override - public Upload setUploadType(java.lang.String uploadType) { - return (Upload) super.setUploadType(uploadType); + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); } @Override - public Upload setUploadProtocol(java.lang.String uploadProtocol) { - return (Upload) super.setUploadProtocol(uploadProtocol); + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); } - /** The resource name of the repository where the generic artifact will be uploaded. */ + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** Required. The name of the file to retrieve. */ @com.google.api.client.util.Key - private java.lang.String parent; + private java.lang.String name; - /** The resource name of the repository where the generic artifact will be uploaded. + /** Required. The name of the file to retrieve. */ - public java.lang.String getParent() { - return parent; + public java.lang.String getName() { + return name; } - /** The resource name of the repository where the generic artifact will be uploaded. */ - public Upload setParent(java.lang.String parent) { + /** Required. The name of the file to retrieve. */ + public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/.*$"); } - this.parent = parent; + this.name = name; return this; } @Override - public Upload set(String parameterName, Object value) { - return (Upload) super.set(parameterName, value); + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); } } - - } - /** - * An accessor for creating requests from the GoModules collection. - * - *

The typical use is:

- *
-         *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
-         *   {@code ArtifactRegistry.GoModules.List request = artifactregistry.goModules().list(parameters ...)}
-         * 
- * - * @return the resource collection - */ - public GoModules goModules() { - return new GoModules(); - } - - /** - * The "goModules" collection of methods. - */ - public class GoModules { - /** - * Directly uploads a Go module. The returned Operation will complete once the Go module is - * uploaded. Package, Version, and File resources are created based on the uploaded Go module. + * Lists files. * - * Create a request for the method "goModules.upload". + * Create a request for the method "files.list". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. - * - * @param parent The resource name of the repository where the Go module will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest} - * @return the request - */ - public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest content) throws java.io.IOException { - Upload result = new Upload(parent, content); - initialize(result); - return result; - } - - /** - * Directly uploads a Go module. The returned Operation will complete once the Go module is - * uploaded. Package, Version, and File resources are created based on the uploaded Go module. - * - * Create a request for the method "goModules.upload". - * - * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. - * - *

- * This method should be used for uploading media content. - *

+ * optional parameters, call the {@link List#execute()} method to invoke the remote operation. * - * @param parent The resource name of the repository where the Go module will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest} media metadata or {@code null} if none - * @param mediaContent The media HTTP content. + * @param parent Required. The name of the repository whose files will be listed. For example: + * "projects/p1/locations/us-central1/repositories/repo1 * @return the request - * @throws java.io.IOException if the initialization of the request fails */ - public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws java.io.IOException { - Upload result = new Upload(parent, content, mediaContent); + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); initialize(result); return result; } - public class Upload extends ArtifactRegistryRequest { + public class List extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+parent}/goModules:create"; + private static final String REST_PATH = "v1/{+parent}/files"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); /** - * Directly uploads a Go module. The returned Operation will complete once the Go module is - * uploaded. Package, Version, and File resources are created based on the uploaded Go module. + * Lists files. * - * Create a request for the method "goModules.upload". + * Create a request for the method "files.list". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. - *

{@link - * Upload#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must - * be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

* - * @param parent The resource name of the repository where the Go module will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest} + * @param parent Required. The name of the repository whose files will be listed. For example: + * "projects/p1/locations/us-central1/repositories/repo1 * @since 1.13 */ - protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest content) { - super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadGoModuleMediaResponse.class); + protected List(java.lang.String parent) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListFilesResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -4346,101 +4433,90 @@ protected Upload(java.lang.String parent, com.google.api.services.artifactregist } } - /** - * Directly uploads a Go module. The returned Operation will complete once the Go module is - * uploaded. Package, Version, and File resources are created based on the uploaded Go module. - * - * Create a request for the method "goModules.upload". - * - * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. - *

{@link - * Upload#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must - * be called to initialize this instance immediately after invoking the constructor.

- * - *

- * This constructor should be used for uploading media content. - *

- * - * @param parent The resource name of the repository where the Go module will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest} media metadata or {@code null} if none - * @param mediaContent The media HTTP content. - * @since 1.13 - */ - protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) { - super(ArtifactRegistry.this, "POST", "/upload/" + getServicePath() + REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadGoModuleMediaResponse.class); - this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); - com.google.api.client.util.Preconditions.checkNotNull(mediaContent, "Required parameter mediaContent must be specified."); - initializeMediaUpload(mediaContent); + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); } @Override - public Upload set$Xgafv(java.lang.String $Xgafv) { - return (Upload) super.set$Xgafv($Xgafv); + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); } @Override - public Upload setAccessToken(java.lang.String accessToken) { - return (Upload) super.setAccessToken(accessToken); + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); } @Override - public Upload setAlt(java.lang.String alt) { - return (Upload) super.setAlt(alt); + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); } @Override - public Upload setCallback(java.lang.String callback) { - return (Upload) super.setCallback(callback); + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); } @Override - public Upload setFields(java.lang.String fields) { - return (Upload) super.setFields(fields); + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); } @Override - public Upload setKey(java.lang.String key) { - return (Upload) super.setKey(key); + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); } @Override - public Upload setOauthToken(java.lang.String oauthToken) { - return (Upload) super.setOauthToken(oauthToken); + public List setKey(java.lang.String key) { + return (List) super.setKey(key); } @Override - public Upload setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Upload) super.setPrettyPrint(prettyPrint); + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); } @Override - public Upload setQuotaUser(java.lang.String quotaUser) { - return (Upload) super.setQuotaUser(quotaUser); + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); } @Override - public Upload setUploadType(java.lang.String uploadType) { - return (Upload) super.setUploadType(uploadType); + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); } @Override - public Upload setUploadProtocol(java.lang.String uploadProtocol) { - return (Upload) super.setUploadProtocol(uploadProtocol); + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); } - /** The resource name of the repository where the Go module will be uploaded. */ + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** + * Required. The name of the repository whose files will be listed. For example: + * "projects/p1/locations/us-central1/repositories/repo1 + */ @com.google.api.client.util.Key private java.lang.String parent; - /** The resource name of the repository where the Go module will be uploaded. + /** Required. The name of the repository whose files will be listed. For example: + "projects/p1/locations/us-central1/repositories/repo1 */ public java.lang.String getParent() { return parent; } - /** The resource name of the repository where the Go module will be uploaded. */ - public Upload setParent(java.lang.String parent) { + /** + * Required. The name of the repository whose files will be listed. For example: + * "projects/p1/locations/us-central1/repositories/repo1 + */ + public List setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + @@ -4450,195 +4526,345 @@ public Upload setParent(java.lang.String parent) { return this; } - @Override - public Upload set(String parameterName, Object value) { - return (Upload) super.set(parameterName, value); + /** + * An expression for filtering the results of the request. Filter rules are case + * insensitive. The fields eligible for filtering are: * `name` * `owner` * + * `annotations` Examples of using a filter: To filter the results of your request to + * files with the name `my_file.txt` in project `my-project` in the `us-central` region, + * in repository `my-repo`, append the following filter expression to your request: * + * `name="projects/my-project/locations/us-central1/repositories/my-repo/files/my- + * file.txt"` You can also use wildcards to match any number of characters before or + * after the value: * `name="projects/my-project/locations/us-central1/repositories/my- + * repo/files/my-*"` * `name="projects/my-project/locations/us-central1/repositories/my- + * repo/filesfile.txt"` * `name="projects/my-project/locations/us- + * central1/repositories/my-repo/filesfile*"` To filter the results of your request to + * files owned by the version `1.0` in package `pkg1`, append the following filter + * expression to your request: * `owner="projects/my-project/locations/us- + * central1/repositories/my-repo/packages/my-package/versions/1.0"` To filter the + * results of your request to files with the annotation key-value pair [`external_link`: + * `external_link_value`], append the following filter expression to your request: * + * `"annotations.external_link:external_link_value"` To filter just for a specific + * annotation key `external_link`, append the following filter expression to your + * request: * `"annotations.external_link"` If the annotation key or value contains + * special characters, you can escape them by surrounding the value with backticks. For + * example, to filter the results of your request to files with the annotation key-value + * pair [`external.link`:`https://example.com/my-file`], append the following filter + * expression to your request: * `` + * "annotations.`external.link`:`https://example.com/my-file`" `` You can also filter + * with annotations with a wildcard to match any number of characters before or after + * the value: * `` "annotations.*_link:`*example.com*`" `` + */ + @com.google.api.client.util.Key + private java.lang.String filter; + + /** An expression for filtering the results of the request. Filter rules are case insensitive. The + fields eligible for filtering are: * `name` * `owner` * `annotations` Examples of using a filter: + To filter the results of your request to files with the name `my_file.txt` in project `my-project` + in the `us-central` region, in repository `my-repo`, append the following filter expression to your + request: * `name="projects/my-project/locations/us-central1/repositories/my-repo/files/my- + file.txt"` You can also use wildcards to match any number of characters before or after the value: + * `name="projects/my-project/locations/us-central1/repositories/my-repo/files/my-*"` * + `name="projects/my-project/locations/us-central1/repositories/my-repo/filesfile.txt"` * + `name="projects/my-project/locations/us-central1/repositories/my-repo/filesfile*"` To filter the + results of your request to files owned by the version `1.0` in package `pkg1`, append the following + filter expression to your request: * `owner="projects/my-project/locations/us- + central1/repositories/my-repo/packages/my-package/versions/1.0"` To filter the results of your + request to files with the annotation key-value pair [`external_link`: `external_link_value`], + append the following filter expression to your request: * + `"annotations.external_link:external_link_value"` To filter just for a specific annotation key + `external_link`, append the following filter expression to your request: * + `"annotations.external_link"` If the annotation key or value contains special characters, you can + escape them by surrounding the value with backticks. For example, to filter the results of your + request to files with the annotation key-value pair [`external.link`:`https://example.com/my- + file`], append the following filter expression to your request: * `` + "annotations.`external.link`:`https://example.com/my-file`" `` You can also filter with annotations + with a wildcard to match any number of characters before or after the value: * `` + "annotations.*_link:`*example.com*`" `` + */ + public java.lang.String getFilter() { + return filter; } - } - } - /** - * An accessor for creating requests from the GoogetArtifacts collection. - * - *

The typical use is:

- *
-         *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
-         *   {@code ArtifactRegistry.GoogetArtifacts.List request = artifactregistry.googetArtifacts().list(parameters ...)}
-         * 
- * - * @return the resource collection - */ - public GoogetArtifacts googetArtifacts() { - return new GoogetArtifacts(); - } + /** + * An expression for filtering the results of the request. Filter rules are case + * insensitive. The fields eligible for filtering are: * `name` * `owner` * + * `annotations` Examples of using a filter: To filter the results of your request to + * files with the name `my_file.txt` in project `my-project` in the `us-central` region, + * in repository `my-repo`, append the following filter expression to your request: * + * `name="projects/my-project/locations/us-central1/repositories/my-repo/files/my- + * file.txt"` You can also use wildcards to match any number of characters before or + * after the value: * `name="projects/my-project/locations/us-central1/repositories/my- + * repo/files/my-*"` * `name="projects/my-project/locations/us-central1/repositories/my- + * repo/filesfile.txt"` * `name="projects/my-project/locations/us- + * central1/repositories/my-repo/filesfile*"` To filter the results of your request to + * files owned by the version `1.0` in package `pkg1`, append the following filter + * expression to your request: * `owner="projects/my-project/locations/us- + * central1/repositories/my-repo/packages/my-package/versions/1.0"` To filter the + * results of your request to files with the annotation key-value pair [`external_link`: + * `external_link_value`], append the following filter expression to your request: * + * `"annotations.external_link:external_link_value"` To filter just for a specific + * annotation key `external_link`, append the following filter expression to your + * request: * `"annotations.external_link"` If the annotation key or value contains + * special characters, you can escape them by surrounding the value with backticks. For + * example, to filter the results of your request to files with the annotation key-value + * pair [`external.link`:`https://example.com/my-file`], append the following filter + * expression to your request: * `` + * "annotations.`external.link`:`https://example.com/my-file`" `` You can also filter + * with annotations with a wildcard to match any number of characters before or after + * the value: * `` "annotations.*_link:`*example.com*`" `` + */ + public List setFilter(java.lang.String filter) { + this.filter = filter; + return this; + } - /** - * The "googetArtifacts" collection of methods. - */ - public class GoogetArtifacts { + /** The field to order the results by. */ + @com.google.api.client.util.Key + private java.lang.String orderBy; + + /** The field to order the results by. + */ + public java.lang.String getOrderBy() { + return orderBy; + } + + /** The field to order the results by. */ + public List setOrderBy(java.lang.String orderBy) { + this.orderBy = orderBy; + return this; + } + + /** The maximum number of files to return. Maximum page size is 1,000. */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** The maximum number of files to return. Maximum page size is 1,000. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** The maximum number of files to return. Maximum page size is 1,000. */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** The next_page_token value returned from a previous list request, if any. */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** The next_page_token value returned from a previous list request, if any. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** The next_page_token value returned from a previous list request, if any. */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } /** - * Imports GooGet artifacts. The returned Operation will complete once the resources are imported. - * Package, Version, and File resources are created based on the imported artifacts. Imported - * artifacts that conflict with existing resources are ignored. + * Updates a file. * - * Create a request for the method "googetArtifacts.import". + * Create a request for the method "files.patch". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link ArtifactRegistryImport#execute()} method to invoke the - * remote operation. + * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. * - * @param parent The name of the parent resource where the artifacts will be imported. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.ImportGoogetArtifactsRequest} + * @param name The name of the file, for example: `projects/p1/locations/us- + * central1/repositories/repo1/files/a%2Fb%2Fc.txt`. If the file ID part contains slashes, + * they are escaped. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1File} * @return the request */ - public ArtifactRegistryImport artifactregistryImport(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.ImportGoogetArtifactsRequest content) throws java.io.IOException { - ArtifactRegistryImport result = new ArtifactRegistryImport(parent, content); + public Patch patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1File content) throws java.io.IOException { + Patch result = new Patch(name, content); initialize(result); return result; } - public class ArtifactRegistryImport extends ArtifactRegistryRequest { + public class Patch extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+parent}/googetArtifacts:import"; + private static final String REST_PATH = "v1/{+name}"; - private final java.util.regex.Pattern PARENT_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); /** - * Imports GooGet artifacts. The returned Operation will complete once the resources are imported. - * Package, Version, and File resources are created based on the imported artifacts. Imported - * artifacts that conflict with existing resources are ignored. + * Updates a file. * - * Create a request for the method "googetArtifacts.import". + * Create a request for the method "files.patch". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link ArtifactRegistryImport#execute()} method to invoke the - * remote operation.

{@link ArtifactRegistryImport#initialize(com.google.api.client.googleapis - * .services.AbstractGoogleClientRequest)} must be called to initialize this instance immediately - * after invoking the constructor.

+ * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. + *

{@link + * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

* - * @param parent The name of the parent resource where the artifacts will be imported. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.ImportGoogetArtifactsRequest} + * @param name The name of the file, for example: `projects/p1/locations/us- + * central1/repositories/repo1/files/a%2Fb%2Fc.txt`. If the file ID part contains slashes, + * they are escaped. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1File} * @since 1.13 */ - protected ArtifactRegistryImport(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.ImportGoogetArtifactsRequest content) { - super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.Operation.class); - this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + protected Patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1File content) { + super(ArtifactRegistry.this, "PATCH", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1File.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); } } @Override - public ArtifactRegistryImport set$Xgafv(java.lang.String $Xgafv) { - return (ArtifactRegistryImport) super.set$Xgafv($Xgafv); + public Patch set$Xgafv(java.lang.String $Xgafv) { + return (Patch) super.set$Xgafv($Xgafv); } @Override - public ArtifactRegistryImport setAccessToken(java.lang.String accessToken) { - return (ArtifactRegistryImport) super.setAccessToken(accessToken); + public Patch setAccessToken(java.lang.String accessToken) { + return (Patch) super.setAccessToken(accessToken); } @Override - public ArtifactRegistryImport setAlt(java.lang.String alt) { - return (ArtifactRegistryImport) super.setAlt(alt); + public Patch setAlt(java.lang.String alt) { + return (Patch) super.setAlt(alt); } @Override - public ArtifactRegistryImport setCallback(java.lang.String callback) { - return (ArtifactRegistryImport) super.setCallback(callback); + public Patch setCallback(java.lang.String callback) { + return (Patch) super.setCallback(callback); } @Override - public ArtifactRegistryImport setFields(java.lang.String fields) { - return (ArtifactRegistryImport) super.setFields(fields); + public Patch setFields(java.lang.String fields) { + return (Patch) super.setFields(fields); } @Override - public ArtifactRegistryImport setKey(java.lang.String key) { - return (ArtifactRegistryImport) super.setKey(key); + public Patch setKey(java.lang.String key) { + return (Patch) super.setKey(key); } @Override - public ArtifactRegistryImport setOauthToken(java.lang.String oauthToken) { - return (ArtifactRegistryImport) super.setOauthToken(oauthToken); + public Patch setOauthToken(java.lang.String oauthToken) { + return (Patch) super.setOauthToken(oauthToken); } @Override - public ArtifactRegistryImport setPrettyPrint(java.lang.Boolean prettyPrint) { - return (ArtifactRegistryImport) super.setPrettyPrint(prettyPrint); + public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Patch) super.setPrettyPrint(prettyPrint); } @Override - public ArtifactRegistryImport setQuotaUser(java.lang.String quotaUser) { - return (ArtifactRegistryImport) super.setQuotaUser(quotaUser); + public Patch setQuotaUser(java.lang.String quotaUser) { + return (Patch) super.setQuotaUser(quotaUser); } @Override - public ArtifactRegistryImport setUploadType(java.lang.String uploadType) { - return (ArtifactRegistryImport) super.setUploadType(uploadType); + public Patch setUploadType(java.lang.String uploadType) { + return (Patch) super.setUploadType(uploadType); } @Override - public ArtifactRegistryImport setUploadProtocol(java.lang.String uploadProtocol) { - return (ArtifactRegistryImport) super.setUploadProtocol(uploadProtocol); + public Patch setUploadProtocol(java.lang.String uploadProtocol) { + return (Patch) super.setUploadProtocol(uploadProtocol); } - /** The name of the parent resource where the artifacts will be imported. */ + /** + * The name of the file, for example: `projects/p1/locations/us- + * central1/repositories/repo1/files/a%2Fb%2Fc.txt`. If the file ID part contains + * slashes, they are escaped. + */ @com.google.api.client.util.Key - private java.lang.String parent; + private java.lang.String name; - /** The name of the parent resource where the artifacts will be imported. + /** The name of the file, for example: `projects/p1/locations/us- + central1/repositories/repo1/files/a%2Fb%2Fc.txt`. If the file ID part contains slashes, they are + escaped. */ - public java.lang.String getParent() { - return parent; + public java.lang.String getName() { + return name; } - /** The name of the parent resource where the artifacts will be imported. */ - public ArtifactRegistryImport setParent(java.lang.String parent) { + /** + * The name of the file, for example: `projects/p1/locations/us- + * central1/repositories/repo1/files/a%2Fb%2Fc.txt`. If the file ID part contains + * slashes, they are escaped. + */ + public Patch setName(java.lang.String name) { if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/files/[^/]+$"); } - this.parent = parent; + this.name = name; + return this; + } + + /** + * Required. The update mask applies to the resource. For the `FieldMask` definition, + * see https://developers.google.com/protocol- + * buffers/docs/reference/google.protobuf#fieldmask + */ + @com.google.api.client.util.Key + private String updateMask; + + /** Required. The update mask applies to the resource. For the `FieldMask` definition, see + https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + */ + public String getUpdateMask() { + return updateMask; + } + + /** + * Required. The update mask applies to the resource. For the `FieldMask` definition, + * see https://developers.google.com/protocol- + * buffers/docs/reference/google.protobuf#fieldmask + */ + public Patch setUpdateMask(String updateMask) { + this.updateMask = updateMask; return this; } @Override - public ArtifactRegistryImport set(String parameterName, Object value) { - return (ArtifactRegistryImport) super.set(parameterName, value); + public Patch set(String parameterName, Object value) { + return (Patch) super.set(parameterName, value); } } /** - * Directly uploads a GooGet artifact. The returned Operation will complete once the resources are - * uploaded. Package, Version, and File resources are created based on the imported artifact. - * Imported artifacts that conflict with existing resources are ignored. + * Directly uploads a File to a repository. The returned Operation will complete once the resources + * are uploaded. * - * Create a request for the method "googetArtifacts.upload". + * Create a request for the method "files.upload". * * This request holds the parameters needed by the artifactregistry server. After setting any * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. * - * @param parent The name of the parent resource where the artifacts will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest} + * @param parent Required. The resource name of the repository where the file will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadFileRequest} * @return the request */ - public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest content) throws java.io.IOException { + public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadFileRequest content) throws java.io.IOException { Upload result = new Upload(parent, content); initialize(result); return result; } /** - * Directly uploads a GooGet artifact. The returned Operation will complete once the resources are - * uploaded. Package, Version, and File resources are created based on the imported artifact. - * Imported artifacts that conflict with existing resources are ignored. + * Directly uploads a File to a repository. The returned Operation will complete once the resources + * are uploaded. * - * Create a request for the method "googetArtifacts.upload". + * Create a request for the method "files.upload". * * This request holds the parameters needed by the the artifactregistry server. After setting any * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. @@ -4647,31 +4873,30 @@ public Upload upload(java.lang.String parent, com.google.api.services.artifactre * This method should be used for uploading media content. *

* - * @param parent The name of the parent resource where the artifacts will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest} media metadata or {@code null} if none + * @param parent Required. The resource name of the repository where the file will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadFileRequest} media metadata or {@code null} if none * @param mediaContent The media HTTP content. * @return the request * @throws java.io.IOException if the initialization of the request fails */ - public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws java.io.IOException { + public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadFileRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws java.io.IOException { Upload result = new Upload(parent, content, mediaContent); initialize(result); return result; } - public class Upload extends ArtifactRegistryRequest { + public class Upload extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+parent}/googetArtifacts:create"; + private static final String REST_PATH = "v1/{+parent}/files:upload"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); /** - * Directly uploads a GooGet artifact. The returned Operation will complete once the resources are - * uploaded. Package, Version, and File resources are created based on the imported artifact. - * Imported artifacts that conflict with existing resources are ignored. + * Directly uploads a File to a repository. The returned Operation will complete once the + * resources are uploaded. * - * Create a request for the method "googetArtifacts.upload". + * Create a request for the method "files.upload". * * This request holds the parameters needed by the the artifactregistry server. After setting any * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. @@ -4679,12 +4904,12 @@ public class Upload extends ArtifactRegistryRequest * - * @param parent The name of the parent resource where the artifacts will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest} + * @param parent Required. The resource name of the repository where the file will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadFileRequest} * @since 1.13 */ - protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest content) { - super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactMediaResponse.class); + protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadFileRequest content) { + super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadFileMediaResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -4694,11 +4919,10 @@ protected Upload(java.lang.String parent, com.google.api.services.artifactregist } /** - * Directly uploads a GooGet artifact. The returned Operation will complete once the resources are - * uploaded. Package, Version, and File resources are created based on the imported artifact. - * Imported artifacts that conflict with existing resources are ignored. + * Directly uploads a File to a repository. The returned Operation will complete once the + * resources are uploaded. * - * Create a request for the method "googetArtifacts.upload". + * Create a request for the method "files.upload". * * This request holds the parameters needed by the the artifactregistry server. After setting any * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. @@ -4710,13 +4934,13 @@ protected Upload(java.lang.String parent, com.google.api.services.artifactregist * This constructor should be used for uploading media content. *

* - * @param parent The name of the parent resource where the artifacts will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest} media metadata or {@code null} if none + * @param parent Required. The resource name of the repository where the file will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadFileRequest} media metadata or {@code null} if none * @param mediaContent The media HTTP content. * @since 1.13 */ - protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) { - super(ArtifactRegistry.this, "POST", "/upload/" + getServicePath() + REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactMediaResponse.class); + protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadFileRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) { + super(ArtifactRegistry.this, "POST", "/upload/" + getServicePath() + REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadFileMediaResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); com.google.api.client.util.Preconditions.checkNotNull(mediaContent, "Required parameter mediaContent must be specified."); initializeMediaUpload(mediaContent); @@ -4777,17 +5001,17 @@ public Upload setUploadProtocol(java.lang.String uploadProtocol) { return (Upload) super.setUploadProtocol(uploadProtocol); } - /** The name of the parent resource where the artifacts will be uploaded. */ + /** Required. The resource name of the repository where the file will be uploaded. */ @com.google.api.client.util.Key private java.lang.String parent; - /** The name of the parent resource where the artifacts will be uploaded. + /** Required. The resource name of the repository where the file will be uploaded. */ public java.lang.String getParent() { return parent; } - /** The name of the parent resource where the artifacts will be uploaded. */ + /** Required. The resource name of the repository where the file will be uploaded. */ public Upload setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -4806,51 +5030,51 @@ public Upload set(String parameterName, Object value) { } /** - * An accessor for creating requests from the KfpArtifacts collection. + * An accessor for creating requests from the GenericArtifacts collection. * *

The typical use is:

*
          *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
-         *   {@code ArtifactRegistry.KfpArtifacts.List request = artifactregistry.kfpArtifacts().list(parameters ...)}
+         *   {@code ArtifactRegistry.GenericArtifacts.List request = artifactregistry.genericArtifacts().list(parameters ...)}
          * 
* * @return the resource collection */ - public KfpArtifacts kfpArtifacts() { - return new KfpArtifacts(); + public GenericArtifacts genericArtifacts() { + return new GenericArtifacts(); } /** - * The "kfpArtifacts" collection of methods. + * The "genericArtifacts" collection of methods. */ - public class KfpArtifacts { + public class GenericArtifacts { /** - * Directly uploads a KFP artifact. The returned Operation will complete once the resource is - * uploaded. Package, Version, and File resources will be created based on the uploaded artifact. - * Uploaded artifacts that conflict with existing resources will be overwritten. + * Directly uploads a Generic artifact. The returned operation will complete once the resources are + * uploaded. Package, version, and file resources are created based on the uploaded artifact. + * Uploaded artifacts that conflict with existing resources will raise an `ALREADY_EXISTS` error. * - * Create a request for the method "kfpArtifacts.upload". + * Create a request for the method "genericArtifacts.upload". * * This request holds the parameters needed by the artifactregistry server. After setting any * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. * - * @param parent The resource name of the repository where the KFP artifact will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest} + * @param parent The resource name of the repository where the generic artifact will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest} * @return the request */ - public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest content) throws java.io.IOException { + public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest content) throws java.io.IOException { Upload result = new Upload(parent, content); initialize(result); return result; } /** - * Directly uploads a KFP artifact. The returned Operation will complete once the resource is - * uploaded. Package, Version, and File resources will be created based on the uploaded artifact. - * Uploaded artifacts that conflict with existing resources will be overwritten. + * Directly uploads a Generic artifact. The returned operation will complete once the resources are + * uploaded. Package, version, and file resources are created based on the uploaded artifact. + * Uploaded artifacts that conflict with existing resources will raise an `ALREADY_EXISTS` error. * - * Create a request for the method "kfpArtifacts.upload". + * Create a request for the method "genericArtifacts.upload". * * This request holds the parameters needed by the the artifactregistry server. After setting any * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. @@ -4859,31 +5083,31 @@ public Upload upload(java.lang.String parent, com.google.api.services.artifactre * This method should be used for uploading media content. *

* - * @param parent The resource name of the repository where the KFP artifact will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest} media metadata or {@code null} if none + * @param parent The resource name of the repository where the generic artifact will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest} media metadata or {@code null} if none * @param mediaContent The media HTTP content. * @return the request * @throws java.io.IOException if the initialization of the request fails */ - public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws java.io.IOException { + public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws java.io.IOException { Upload result = new Upload(parent, content, mediaContent); initialize(result); return result; } - public class Upload extends ArtifactRegistryRequest { + public class Upload extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+parent}/kfpArtifacts:create"; + private static final String REST_PATH = "v1/{+parent}/genericArtifacts:create"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); /** - * Directly uploads a KFP artifact. The returned Operation will complete once the resource is - * uploaded. Package, Version, and File resources will be created based on the uploaded artifact. - * Uploaded artifacts that conflict with existing resources will be overwritten. + * Directly uploads a Generic artifact. The returned operation will complete once the resources + * are uploaded. Package, version, and file resources are created based on the uploaded artifact. + * Uploaded artifacts that conflict with existing resources will raise an `ALREADY_EXISTS` error. * - * Create a request for the method "kfpArtifacts.upload". + * Create a request for the method "genericArtifacts.upload". * * This request holds the parameters needed by the the artifactregistry server. After setting any * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. @@ -4891,12 +5115,12 @@ public class Upload extends ArtifactRegistryRequest * - * @param parent The resource name of the repository where the KFP artifact will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest} + * @param parent The resource name of the repository where the generic artifact will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest} * @since 1.13 */ - protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest content) { - super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactMediaResponse.class); + protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest content) { + super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactMediaResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -4906,11 +5130,11 @@ protected Upload(java.lang.String parent, com.google.api.services.artifactregist } /** - * Directly uploads a KFP artifact. The returned Operation will complete once the resource is - * uploaded. Package, Version, and File resources will be created based on the uploaded artifact. - * Uploaded artifacts that conflict with existing resources will be overwritten. + * Directly uploads a Generic artifact. The returned operation will complete once the resources + * are uploaded. Package, version, and file resources are created based on the uploaded artifact. + * Uploaded artifacts that conflict with existing resources will raise an `ALREADY_EXISTS` error. * - * Create a request for the method "kfpArtifacts.upload". + * Create a request for the method "genericArtifacts.upload". * * This request holds the parameters needed by the the artifactregistry server. After setting any * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. @@ -4922,13 +5146,13 @@ protected Upload(java.lang.String parent, com.google.api.services.artifactregist * This constructor should be used for uploading media content. *

* - * @param parent The resource name of the repository where the KFP artifact will be uploaded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest} media metadata or {@code null} if none + * @param parent The resource name of the repository where the generic artifact will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest} media metadata or {@code null} if none * @param mediaContent The media HTTP content. * @since 1.13 */ - protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) { - super(ArtifactRegistry.this, "POST", "/upload/" + getServicePath() + REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactMediaResponse.class); + protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) { + super(ArtifactRegistry.this, "POST", "/upload/" + getServicePath() + REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadGenericArtifactMediaResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); com.google.api.client.util.Preconditions.checkNotNull(mediaContent, "Required parameter mediaContent must be specified."); initializeMediaUpload(mediaContent); @@ -4989,17 +5213,17 @@ public Upload setUploadProtocol(java.lang.String uploadProtocol) { return (Upload) super.setUploadProtocol(uploadProtocol); } - /** The resource name of the repository where the KFP artifact will be uploaded. */ + /** The resource name of the repository where the generic artifact will be uploaded. */ @com.google.api.client.util.Key private java.lang.String parent; - /** The resource name of the repository where the KFP artifact will be uploaded. + /** The resource name of the repository where the generic artifact will be uploaded. */ public java.lang.String getParent() { return parent; } - /** The resource name of the repository where the KFP artifact will be uploaded. */ + /** The resource name of the repository where the generic artifact will be uploaded. */ public Upload setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -5018,202 +5242,280 @@ public Upload set(String parameterName, Object value) { } /** - * An accessor for creating requests from the MavenArtifacts collection. + * An accessor for creating requests from the GoModules collection. * *

The typical use is:

*
          *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
-         *   {@code ArtifactRegistry.MavenArtifacts.List request = artifactregistry.mavenArtifacts().list(parameters ...)}
+         *   {@code ArtifactRegistry.GoModules.List request = artifactregistry.goModules().list(parameters ...)}
          * 
* * @return the resource collection */ - public MavenArtifacts mavenArtifacts() { - return new MavenArtifacts(); + public GoModules goModules() { + return new GoModules(); } /** - * The "mavenArtifacts" collection of methods. + * The "goModules" collection of methods. */ - public class MavenArtifacts { + public class GoModules { /** - * Gets a maven artifact. + * Directly uploads a Go module. The returned Operation will complete once the Go module is + * uploaded. Package, Version, and File resources are created based on the uploaded Go module. * - * Create a request for the method "mavenArtifacts.get". + * Create a request for the method "goModules.upload". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. + * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. * - * @param name Required. The name of the maven artifact. + * @param parent The resource name of the repository where the Go module will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest} * @return the request */ - public Get get(java.lang.String name) throws java.io.IOException { - Get result = new Get(name); + public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest content) throws java.io.IOException { + Upload result = new Upload(parent, content); initialize(result); return result; } - public class Get extends ArtifactRegistryRequest { + /** + * Directly uploads a Go module. The returned Operation will complete once the Go module is + * uploaded. Package, Version, and File resources are created based on the uploaded Go module. + * + * Create a request for the method "goModules.upload". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. + * + *

+ * This method should be used for uploading media content. + *

+ * + * @param parent The resource name of the repository where the Go module will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest} media metadata or {@code null} if none + * @param mediaContent The media HTTP content. + * @return the request + * @throws java.io.IOException if the initialization of the request fails + */ + public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws java.io.IOException { + Upload result = new Upload(parent, content, mediaContent); + initialize(result); + return result; + } - private static final String REST_PATH = "v1/{+name}"; + public class Upload extends ArtifactRegistryRequest { - private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/mavenArtifacts/[^/]+$"); + private static final String REST_PATH = "v1/{+parent}/goModules:create"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); /** - * Gets a maven artifact. + * Directly uploads a Go module. The returned Operation will complete once the Go module is + * uploaded. Package, Version, and File resources are created based on the uploaded Go module. * - * Create a request for the method "mavenArtifacts.get". + * Create a request for the method "goModules.upload". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

- * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} - * must be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. + *

{@link + * Upload#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

* - * @param name Required. The name of the maven artifact. + * @param parent The resource name of the repository where the Go module will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest} * @since 1.13 */ - protected Get(java.lang.String name) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.MavenArtifact.class); - this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest content) { + super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadGoModuleMediaResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/mavenArtifacts/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); } } - @Override - public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { - return super.executeUsingHead(); - } - - @Override - public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { - return super.buildHttpRequestUsingHead(); + /** + * Directly uploads a Go module. The returned Operation will complete once the Go module is + * uploaded. Package, Version, and File resources are created based on the uploaded Go module. + * + * Create a request for the method "goModules.upload". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. + *

{@link + * Upload#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + *

+ * This constructor should be used for uploading media content. + *

+ * + * @param parent The resource name of the repository where the Go module will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest} media metadata or {@code null} if none + * @param mediaContent The media HTTP content. + * @since 1.13 + */ + protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoModuleRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) { + super(ArtifactRegistry.this, "POST", "/upload/" + getServicePath() + REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadGoModuleMediaResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + com.google.api.client.util.Preconditions.checkNotNull(mediaContent, "Required parameter mediaContent must be specified."); + initializeMediaUpload(mediaContent); } @Override - public Get set$Xgafv(java.lang.String $Xgafv) { - return (Get) super.set$Xgafv($Xgafv); + public Upload set$Xgafv(java.lang.String $Xgafv) { + return (Upload) super.set$Xgafv($Xgafv); } @Override - public Get setAccessToken(java.lang.String accessToken) { - return (Get) super.setAccessToken(accessToken); + public Upload setAccessToken(java.lang.String accessToken) { + return (Upload) super.setAccessToken(accessToken); } @Override - public Get setAlt(java.lang.String alt) { - return (Get) super.setAlt(alt); + public Upload setAlt(java.lang.String alt) { + return (Upload) super.setAlt(alt); } @Override - public Get setCallback(java.lang.String callback) { - return (Get) super.setCallback(callback); + public Upload setCallback(java.lang.String callback) { + return (Upload) super.setCallback(callback); } @Override - public Get setFields(java.lang.String fields) { - return (Get) super.setFields(fields); + public Upload setFields(java.lang.String fields) { + return (Upload) super.setFields(fields); } @Override - public Get setKey(java.lang.String key) { - return (Get) super.setKey(key); + public Upload setKey(java.lang.String key) { + return (Upload) super.setKey(key); } @Override - public Get setOauthToken(java.lang.String oauthToken) { - return (Get) super.setOauthToken(oauthToken); + public Upload setOauthToken(java.lang.String oauthToken) { + return (Upload) super.setOauthToken(oauthToken); } @Override - public Get setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Get) super.setPrettyPrint(prettyPrint); + public Upload setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Upload) super.setPrettyPrint(prettyPrint); } @Override - public Get setQuotaUser(java.lang.String quotaUser) { - return (Get) super.setQuotaUser(quotaUser); + public Upload setQuotaUser(java.lang.String quotaUser) { + return (Upload) super.setQuotaUser(quotaUser); } @Override - public Get setUploadType(java.lang.String uploadType) { - return (Get) super.setUploadType(uploadType); + public Upload setUploadType(java.lang.String uploadType) { + return (Upload) super.setUploadType(uploadType); } @Override - public Get setUploadProtocol(java.lang.String uploadProtocol) { - return (Get) super.setUploadProtocol(uploadProtocol); + public Upload setUploadProtocol(java.lang.String uploadProtocol) { + return (Upload) super.setUploadProtocol(uploadProtocol); } - /** Required. The name of the maven artifact. */ + /** The resource name of the repository where the Go module will be uploaded. */ @com.google.api.client.util.Key - private java.lang.String name; + private java.lang.String parent; - /** Required. The name of the maven artifact. + /** The resource name of the repository where the Go module will be uploaded. */ - public java.lang.String getName() { - return name; + public java.lang.String getParent() { + return parent; } - /** Required. The name of the maven artifact. */ - public Get setName(java.lang.String name) { + /** The resource name of the repository where the Go module will be uploaded. */ + public Upload setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/mavenArtifacts/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); } - this.name = name; + this.parent = parent; return this; } @Override - public Get set(String parameterName, Object value) { - return (Get) super.set(parameterName, value); + public Upload set(String parameterName, Object value) { + return (Upload) super.set(parameterName, value); } } + + } + /** + * An accessor for creating requests from the GoogetArtifacts collection. + * + *

The typical use is:

+ *
+         *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
+         *   {@code ArtifactRegistry.GoogetArtifacts.List request = artifactregistry.googetArtifacts().list(parameters ...)}
+         * 
+ * + * @return the resource collection + */ + public GoogetArtifacts googetArtifacts() { + return new GoogetArtifacts(); + } + + /** + * The "googetArtifacts" collection of methods. + */ + public class GoogetArtifacts { + /** - * Lists maven artifacts. + * Imports GooGet artifacts. The returned Operation will complete once the resources are imported. + * Package, Version, and File resources are created based on the imported artifacts. Imported + * artifacts that conflict with existing resources are ignored. * - * Create a request for the method "mavenArtifacts.list". + * Create a request for the method "googetArtifacts.import". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link List#execute()} method to invoke the remote operation. + * optional parameters, call the {@link ArtifactRegistryImport#execute()} method to invoke the + * remote operation. * - * @param parent Required. The name of the parent resource whose maven artifacts will be listed. + * @param parent The name of the parent resource where the artifacts will be imported. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.ImportGoogetArtifactsRequest} * @return the request */ - public List list(java.lang.String parent) throws java.io.IOException { - List result = new List(parent); + public ArtifactRegistryImport artifactregistryImport(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.ImportGoogetArtifactsRequest content) throws java.io.IOException { + ArtifactRegistryImport result = new ArtifactRegistryImport(parent, content); initialize(result); return result; } - public class List extends ArtifactRegistryRequest { + public class ArtifactRegistryImport extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+parent}/mavenArtifacts"; + private static final String REST_PATH = "v1/{+parent}/googetArtifacts:import"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); /** - * Lists maven artifacts. + * Imports GooGet artifacts. The returned Operation will complete once the resources are imported. + * Package, Version, and File resources are created based on the imported artifacts. Imported + * artifacts that conflict with existing resources are ignored. * - * Create a request for the method "mavenArtifacts.list". + * Create a request for the method "googetArtifacts.import". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

- * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} - * must be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link ArtifactRegistryImport#execute()} method to invoke the + * remote operation.

{@link ArtifactRegistryImport#initialize(com.google.api.client.googleapis + * .services.AbstractGoogleClientRequest)} must be called to initialize this instance immediately + * after invoking the constructor.

* - * @param parent Required. The name of the parent resource whose maven artifacts will be listed. + * @param parent The name of the parent resource where the artifacts will be imported. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.ImportGoogetArtifactsRequest} * @since 1.13 */ - protected List(java.lang.String parent) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListMavenArtifactsResponse.class); + protected ArtifactRegistryImport(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.ImportGoogetArtifactsRequest content) { + super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.Operation.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -5223,82 +5525,72 @@ protected List(java.lang.String parent) { } @Override - public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { - return super.executeUsingHead(); + public ArtifactRegistryImport set$Xgafv(java.lang.String $Xgafv) { + return (ArtifactRegistryImport) super.set$Xgafv($Xgafv); } @Override - public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { - return super.buildHttpRequestUsingHead(); + public ArtifactRegistryImport setAccessToken(java.lang.String accessToken) { + return (ArtifactRegistryImport) super.setAccessToken(accessToken); } @Override - public List set$Xgafv(java.lang.String $Xgafv) { - return (List) super.set$Xgafv($Xgafv); + public ArtifactRegistryImport setAlt(java.lang.String alt) { + return (ArtifactRegistryImport) super.setAlt(alt); } @Override - public List setAccessToken(java.lang.String accessToken) { - return (List) super.setAccessToken(accessToken); + public ArtifactRegistryImport setCallback(java.lang.String callback) { + return (ArtifactRegistryImport) super.setCallback(callback); } @Override - public List setAlt(java.lang.String alt) { - return (List) super.setAlt(alt); - } - - @Override - public List setCallback(java.lang.String callback) { - return (List) super.setCallback(callback); - } - - @Override - public List setFields(java.lang.String fields) { - return (List) super.setFields(fields); + public ArtifactRegistryImport setFields(java.lang.String fields) { + return (ArtifactRegistryImport) super.setFields(fields); } @Override - public List setKey(java.lang.String key) { - return (List) super.setKey(key); + public ArtifactRegistryImport setKey(java.lang.String key) { + return (ArtifactRegistryImport) super.setKey(key); } @Override - public List setOauthToken(java.lang.String oauthToken) { - return (List) super.setOauthToken(oauthToken); + public ArtifactRegistryImport setOauthToken(java.lang.String oauthToken) { + return (ArtifactRegistryImport) super.setOauthToken(oauthToken); } @Override - public List setPrettyPrint(java.lang.Boolean prettyPrint) { - return (List) super.setPrettyPrint(prettyPrint); + public ArtifactRegistryImport setPrettyPrint(java.lang.Boolean prettyPrint) { + return (ArtifactRegistryImport) super.setPrettyPrint(prettyPrint); } @Override - public List setQuotaUser(java.lang.String quotaUser) { - return (List) super.setQuotaUser(quotaUser); + public ArtifactRegistryImport setQuotaUser(java.lang.String quotaUser) { + return (ArtifactRegistryImport) super.setQuotaUser(quotaUser); } @Override - public List setUploadType(java.lang.String uploadType) { - return (List) super.setUploadType(uploadType); + public ArtifactRegistryImport setUploadType(java.lang.String uploadType) { + return (ArtifactRegistryImport) super.setUploadType(uploadType); } @Override - public List setUploadProtocol(java.lang.String uploadProtocol) { - return (List) super.setUploadProtocol(uploadProtocol); + public ArtifactRegistryImport setUploadProtocol(java.lang.String uploadProtocol) { + return (ArtifactRegistryImport) super.setUploadProtocol(uploadProtocol); } - /** Required. The name of the parent resource whose maven artifacts will be listed. */ + /** The name of the parent resource where the artifacts will be imported. */ @com.google.api.client.util.Key private java.lang.String parent; - /** Required. The name of the parent resource whose maven artifacts will be listed. + /** The name of the parent resource where the artifacts will be imported. */ public java.lang.String getParent() { return parent; } - /** Required. The name of the parent resource whose maven artifacts will be listed. */ - public List setParent(java.lang.String parent) { + /** The name of the parent resource where the artifacts will be imported. */ + public ArtifactRegistryImport setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + @@ -5308,242 +5600,295 @@ public List setParent(java.lang.String parent) { return this; } - /** The maximum number of artifacts to return. Maximum page size is 1,000. */ - @com.google.api.client.util.Key - private java.lang.Integer pageSize; - - /** The maximum number of artifacts to return. Maximum page size is 1,000. - */ - public java.lang.Integer getPageSize() { - return pageSize; - } - - /** The maximum number of artifacts to return. Maximum page size is 1,000. */ - public List setPageSize(java.lang.Integer pageSize) { - this.pageSize = pageSize; - return this; - } - - /** The next_page_token value returned from a previous list request, if any. */ - @com.google.api.client.util.Key - private java.lang.String pageToken; - - /** The next_page_token value returned from a previous list request, if any. - */ - public java.lang.String getPageToken() { - return pageToken; - } - - /** The next_page_token value returned from a previous list request, if any. */ - public List setPageToken(java.lang.String pageToken) { - this.pageToken = pageToken; - return this; - } - @Override - public List set(String parameterName, Object value) { - return (List) super.set(parameterName, value); + public ArtifactRegistryImport set(String parameterName, Object value) { + return (ArtifactRegistryImport) super.set(parameterName, value); } } - - } - /** - * An accessor for creating requests from the NpmPackages collection. - * - *

The typical use is:

- *
-         *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
-         *   {@code ArtifactRegistry.NpmPackages.List request = artifactregistry.npmPackages().list(parameters ...)}
-         * 
- * - * @return the resource collection - */ - public NpmPackages npmPackages() { - return new NpmPackages(); - } - - /** - * The "npmPackages" collection of methods. - */ - public class NpmPackages { - /** - * Gets a npm package. + * Directly uploads a GooGet artifact. The returned Operation will complete once the resources are + * uploaded. Package, Version, and File resources are created based on the imported artifact. + * Imported artifacts that conflict with existing resources are ignored. * - * Create a request for the method "npmPackages.get". + * Create a request for the method "googetArtifacts.upload". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. + * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. * - * @param name Required. The name of the npm package. + * @param parent The name of the parent resource where the artifacts will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest} * @return the request */ - public Get get(java.lang.String name) throws java.io.IOException { - Get result = new Get(name); + public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest content) throws java.io.IOException { + Upload result = new Upload(parent, content); initialize(result); return result; } - public class Get extends ArtifactRegistryRequest { + /** + * Directly uploads a GooGet artifact. The returned Operation will complete once the resources are + * uploaded. Package, Version, and File resources are created based on the imported artifact. + * Imported artifacts that conflict with existing resources are ignored. + * + * Create a request for the method "googetArtifacts.upload". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. + * + *

+ * This method should be used for uploading media content. + *

+ * + * @param parent The name of the parent resource where the artifacts will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest} media metadata or {@code null} if none + * @param mediaContent The media HTTP content. + * @return the request + * @throws java.io.IOException if the initialization of the request fails + */ + public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws java.io.IOException { + Upload result = new Upload(parent, content, mediaContent); + initialize(result); + return result; + } - private static final String REST_PATH = "v1/{+name}"; + public class Upload extends ArtifactRegistryRequest { - private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/npmPackages/[^/]+$"); + private static final String REST_PATH = "v1/{+parent}/googetArtifacts:create"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); /** - * Gets a npm package. + * Directly uploads a GooGet artifact. The returned Operation will complete once the resources are + * uploaded. Package, Version, and File resources are created based on the imported artifact. + * Imported artifacts that conflict with existing resources are ignored. * - * Create a request for the method "npmPackages.get". + * Create a request for the method "googetArtifacts.upload". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

- * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} - * must be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. + *

{@link + * Upload#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

* - * @param name Required. The name of the npm package. + * @param parent The name of the parent resource where the artifacts will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest} * @since 1.13 */ - protected Get(java.lang.String name) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.NpmPackage.class); - this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest content) { + super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactMediaResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/npmPackages/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); } } - @Override - public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { - return super.executeUsingHead(); + /** + * Directly uploads a GooGet artifact. The returned Operation will complete once the resources are + * uploaded. Package, Version, and File resources are created based on the imported artifact. + * Imported artifacts that conflict with existing resources are ignored. + * + * Create a request for the method "googetArtifacts.upload". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. + *

{@link + * Upload#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + *

+ * This constructor should be used for uploading media content. + *

+ * + * @param parent The name of the parent resource where the artifacts will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest} media metadata or {@code null} if none + * @param mediaContent The media HTTP content. + * @since 1.13 + */ + protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) { + super(ArtifactRegistry.this, "POST", "/upload/" + getServicePath() + REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadGoogetArtifactMediaResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + com.google.api.client.util.Preconditions.checkNotNull(mediaContent, "Required parameter mediaContent must be specified."); + initializeMediaUpload(mediaContent); } @Override - public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { - return super.buildHttpRequestUsingHead(); + public Upload set$Xgafv(java.lang.String $Xgafv) { + return (Upload) super.set$Xgafv($Xgafv); } @Override - public Get set$Xgafv(java.lang.String $Xgafv) { - return (Get) super.set$Xgafv($Xgafv); + public Upload setAccessToken(java.lang.String accessToken) { + return (Upload) super.setAccessToken(accessToken); } @Override - public Get setAccessToken(java.lang.String accessToken) { - return (Get) super.setAccessToken(accessToken); + public Upload setAlt(java.lang.String alt) { + return (Upload) super.setAlt(alt); } @Override - public Get setAlt(java.lang.String alt) { - return (Get) super.setAlt(alt); + public Upload setCallback(java.lang.String callback) { + return (Upload) super.setCallback(callback); } @Override - public Get setCallback(java.lang.String callback) { - return (Get) super.setCallback(callback); + public Upload setFields(java.lang.String fields) { + return (Upload) super.setFields(fields); } @Override - public Get setFields(java.lang.String fields) { - return (Get) super.setFields(fields); + public Upload setKey(java.lang.String key) { + return (Upload) super.setKey(key); } @Override - public Get setKey(java.lang.String key) { - return (Get) super.setKey(key); + public Upload setOauthToken(java.lang.String oauthToken) { + return (Upload) super.setOauthToken(oauthToken); } @Override - public Get setOauthToken(java.lang.String oauthToken) { - return (Get) super.setOauthToken(oauthToken); + public Upload setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Upload) super.setPrettyPrint(prettyPrint); } @Override - public Get setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Get) super.setPrettyPrint(prettyPrint); + public Upload setQuotaUser(java.lang.String quotaUser) { + return (Upload) super.setQuotaUser(quotaUser); } @Override - public Get setQuotaUser(java.lang.String quotaUser) { - return (Get) super.setQuotaUser(quotaUser); + public Upload setUploadType(java.lang.String uploadType) { + return (Upload) super.setUploadType(uploadType); } @Override - public Get setUploadType(java.lang.String uploadType) { - return (Get) super.setUploadType(uploadType); + public Upload setUploadProtocol(java.lang.String uploadProtocol) { + return (Upload) super.setUploadProtocol(uploadProtocol); } - @Override - public Get setUploadProtocol(java.lang.String uploadProtocol) { - return (Get) super.setUploadProtocol(uploadProtocol); - } - - /** Required. The name of the npm package. */ + /** The name of the parent resource where the artifacts will be uploaded. */ @com.google.api.client.util.Key - private java.lang.String name; + private java.lang.String parent; - /** Required. The name of the npm package. + /** The name of the parent resource where the artifacts will be uploaded. */ - public java.lang.String getName() { - return name; + public java.lang.String getParent() { + return parent; } - /** Required. The name of the npm package. */ - public Get setName(java.lang.String name) { + /** The name of the parent resource where the artifacts will be uploaded. */ + public Upload setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/npmPackages/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); } - this.name = name; + this.parent = parent; return this; } @Override - public Get set(String parameterName, Object value) { - return (Get) super.set(parameterName, value); + public Upload set(String parameterName, Object value) { + return (Upload) super.set(parameterName, value); } } + + } + /** + * An accessor for creating requests from the KfpArtifacts collection. + * + *

The typical use is:

+ *
+         *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
+         *   {@code ArtifactRegistry.KfpArtifacts.List request = artifactregistry.kfpArtifacts().list(parameters ...)}
+         * 
+ * + * @return the resource collection + */ + public KfpArtifacts kfpArtifacts() { + return new KfpArtifacts(); + } + + /** + * The "kfpArtifacts" collection of methods. + */ + public class KfpArtifacts { + /** - * Lists npm packages. + * Directly uploads a KFP artifact. The returned Operation will complete once the resource is + * uploaded. Package, Version, and File resources will be created based on the uploaded artifact. + * Uploaded artifacts that conflict with existing resources will be overwritten. * - * Create a request for the method "npmPackages.list". + * Create a request for the method "kfpArtifacts.upload". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link List#execute()} method to invoke the remote operation. + * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. * - * @param parent Required. The name of the parent resource whose npm packages will be listed. + * @param parent The resource name of the repository where the KFP artifact will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest} * @return the request */ - public List list(java.lang.String parent) throws java.io.IOException { - List result = new List(parent); + public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest content) throws java.io.IOException { + Upload result = new Upload(parent, content); initialize(result); return result; } - public class List extends ArtifactRegistryRequest { + /** + * Directly uploads a KFP artifact. The returned Operation will complete once the resource is + * uploaded. Package, Version, and File resources will be created based on the uploaded artifact. + * Uploaded artifacts that conflict with existing resources will be overwritten. + * + * Create a request for the method "kfpArtifacts.upload". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. + * + *

+ * This method should be used for uploading media content. + *

+ * + * @param parent The resource name of the repository where the KFP artifact will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest} media metadata or {@code null} if none + * @param mediaContent The media HTTP content. + * @return the request + * @throws java.io.IOException if the initialization of the request fails + */ + public Upload upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) throws java.io.IOException { + Upload result = new Upload(parent, content, mediaContent); + initialize(result); + return result; + } - private static final String REST_PATH = "v1/{+parent}/npmPackages"; + public class Upload extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+parent}/kfpArtifacts:create"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); /** - * Lists npm packages. + * Directly uploads a KFP artifact. The returned Operation will complete once the resource is + * uploaded. Package, Version, and File resources will be created based on the uploaded artifact. + * Uploaded artifacts that conflict with existing resources will be overwritten. * - * Create a request for the method "npmPackages.list". + * Create a request for the method "kfpArtifacts.upload". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

- * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} - * must be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. + *

{@link + * Upload#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

* - * @param parent Required. The name of the parent resource whose npm packages will be listed. + * @param parent The resource name of the repository where the KFP artifact will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest} * @since 1.13 */ - protected List(java.lang.String parent) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListNpmPackagesResponse.class); + protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest content) { + super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactMediaResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -5552,83 +5897,102 @@ protected List(java.lang.String parent) { } } - @Override - public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { - return super.executeUsingHead(); - } - - @Override - public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { - return super.buildHttpRequestUsingHead(); + /** + * Directly uploads a KFP artifact. The returned Operation will complete once the resource is + * uploaded. Package, Version, and File resources will be created based on the uploaded artifact. + * Uploaded artifacts that conflict with existing resources will be overwritten. + * + * Create a request for the method "kfpArtifacts.upload". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Upload#execute()} method to invoke the remote operation. + *

{@link + * Upload#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + *

+ * This constructor should be used for uploading media content. + *

+ * + * @param parent The resource name of the repository where the KFP artifact will be uploaded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest} media metadata or {@code null} if none + * @param mediaContent The media HTTP content. + * @since 1.13 + */ + protected Upload(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactRequest content, com.google.api.client.http.AbstractInputStreamContent mediaContent) { + super(ArtifactRegistry.this, "POST", "/upload/" + getServicePath() + REST_PATH, content, com.google.api.services.artifactregistry.v1.model.UploadKfpArtifactMediaResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + com.google.api.client.util.Preconditions.checkNotNull(mediaContent, "Required parameter mediaContent must be specified."); + initializeMediaUpload(mediaContent); } @Override - public List set$Xgafv(java.lang.String $Xgafv) { - return (List) super.set$Xgafv($Xgafv); + public Upload set$Xgafv(java.lang.String $Xgafv) { + return (Upload) super.set$Xgafv($Xgafv); } @Override - public List setAccessToken(java.lang.String accessToken) { - return (List) super.setAccessToken(accessToken); + public Upload setAccessToken(java.lang.String accessToken) { + return (Upload) super.setAccessToken(accessToken); } @Override - public List setAlt(java.lang.String alt) { - return (List) super.setAlt(alt); + public Upload setAlt(java.lang.String alt) { + return (Upload) super.setAlt(alt); } @Override - public List setCallback(java.lang.String callback) { - return (List) super.setCallback(callback); + public Upload setCallback(java.lang.String callback) { + return (Upload) super.setCallback(callback); } @Override - public List setFields(java.lang.String fields) { - return (List) super.setFields(fields); + public Upload setFields(java.lang.String fields) { + return (Upload) super.setFields(fields); } @Override - public List setKey(java.lang.String key) { - return (List) super.setKey(key); + public Upload setKey(java.lang.String key) { + return (Upload) super.setKey(key); } @Override - public List setOauthToken(java.lang.String oauthToken) { - return (List) super.setOauthToken(oauthToken); + public Upload setOauthToken(java.lang.String oauthToken) { + return (Upload) super.setOauthToken(oauthToken); } @Override - public List setPrettyPrint(java.lang.Boolean prettyPrint) { - return (List) super.setPrettyPrint(prettyPrint); + public Upload setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Upload) super.setPrettyPrint(prettyPrint); } @Override - public List setQuotaUser(java.lang.String quotaUser) { - return (List) super.setQuotaUser(quotaUser); + public Upload setQuotaUser(java.lang.String quotaUser) { + return (Upload) super.setQuotaUser(quotaUser); } @Override - public List setUploadType(java.lang.String uploadType) { - return (List) super.setUploadType(uploadType); + public Upload setUploadType(java.lang.String uploadType) { + return (Upload) super.setUploadType(uploadType); } @Override - public List setUploadProtocol(java.lang.String uploadProtocol) { - return (List) super.setUploadProtocol(uploadProtocol); + public Upload setUploadProtocol(java.lang.String uploadProtocol) { + return (Upload) super.setUploadProtocol(uploadProtocol); } - /** Required. The name of the parent resource whose npm packages will be listed. */ + /** The resource name of the repository where the KFP artifact will be uploaded. */ @com.google.api.client.util.Key private java.lang.String parent; - /** Required. The name of the parent resource whose npm packages will be listed. + /** The resource name of the repository where the KFP artifact will be uploaded. */ public java.lang.String getParent() { return parent; } - /** Required. The name of the parent resource whose npm packages will be listed. */ - public List setParent(java.lang.String parent) { + /** The resource name of the repository where the KFP artifact will be uploaded. */ + public Upload setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), "Parameter parent must conform to the pattern " + @@ -5638,205 +6002,42 @@ public List setParent(java.lang.String parent) { return this; } - /** The maximum number of artifacts to return. Maximum page size is 1,000. */ - @com.google.api.client.util.Key - private java.lang.Integer pageSize; - - /** The maximum number of artifacts to return. Maximum page size is 1,000. - */ - public java.lang.Integer getPageSize() { - return pageSize; - } - - /** The maximum number of artifacts to return. Maximum page size is 1,000. */ - public List setPageSize(java.lang.Integer pageSize) { - this.pageSize = pageSize; - return this; - } - - /** The next_page_token value returned from a previous list request, if any. */ - @com.google.api.client.util.Key - private java.lang.String pageToken; - - /** The next_page_token value returned from a previous list request, if any. - */ - public java.lang.String getPageToken() { - return pageToken; - } - - /** The next_page_token value returned from a previous list request, if any. */ - public List setPageToken(java.lang.String pageToken) { - this.pageToken = pageToken; - return this; - } - @Override - public List set(String parameterName, Object value) { - return (List) super.set(parameterName, value); + public Upload set(String parameterName, Object value) { + return (Upload) super.set(parameterName, value); } } } /** - * An accessor for creating requests from the Packages collection. + * An accessor for creating requests from the MavenArtifacts collection. * *

The typical use is:

*
          *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
-         *   {@code ArtifactRegistry.Packages.List request = artifactregistry.packages().list(parameters ...)}
+         *   {@code ArtifactRegistry.MavenArtifacts.List request = artifactregistry.mavenArtifacts().list(parameters ...)}
          * 
* * @return the resource collection */ - public Packages packages() { - return new Packages(); + public MavenArtifacts mavenArtifacts() { + return new MavenArtifacts(); } /** - * The "packages" collection of methods. + * The "mavenArtifacts" collection of methods. */ - public class Packages { + public class MavenArtifacts { /** - * Deletes a package and all of its versions and tags. The returned operation will complete once the - * package has been deleted. + * Gets a maven artifact. * - * Create a request for the method "packages.delete". - * - * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. - * - * @param name Required. The name of the package to delete. - * @return the request - */ - public Delete delete(java.lang.String name) throws java.io.IOException { - Delete result = new Delete(name); - initialize(result); - return result; - } - - public class Delete extends ArtifactRegistryRequest { - - private static final String REST_PATH = "v1/{+name}"; - - private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); - - /** - * Deletes a package and all of its versions and tags. The returned operation will complete once - * the package has been deleted. - * - * Create a request for the method "packages.delete". - * - * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. - *

{@link - * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must - * be called to initialize this instance immediately after invoking the constructor.

- * - * @param name Required. The name of the package to delete. - * @since 1.13 - */ - protected Delete(java.lang.String name) { - super(ArtifactRegistry.this, "DELETE", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Operation.class); - this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); - if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); - } - } - - @Override - public Delete set$Xgafv(java.lang.String $Xgafv) { - return (Delete) super.set$Xgafv($Xgafv); - } - - @Override - public Delete setAccessToken(java.lang.String accessToken) { - return (Delete) super.setAccessToken(accessToken); - } - - @Override - public Delete setAlt(java.lang.String alt) { - return (Delete) super.setAlt(alt); - } - - @Override - public Delete setCallback(java.lang.String callback) { - return (Delete) super.setCallback(callback); - } - - @Override - public Delete setFields(java.lang.String fields) { - return (Delete) super.setFields(fields); - } - - @Override - public Delete setKey(java.lang.String key) { - return (Delete) super.setKey(key); - } - - @Override - public Delete setOauthToken(java.lang.String oauthToken) { - return (Delete) super.setOauthToken(oauthToken); - } - - @Override - public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Delete) super.setPrettyPrint(prettyPrint); - } - - @Override - public Delete setQuotaUser(java.lang.String quotaUser) { - return (Delete) super.setQuotaUser(quotaUser); - } - - @Override - public Delete setUploadType(java.lang.String uploadType) { - return (Delete) super.setUploadType(uploadType); - } - - @Override - public Delete setUploadProtocol(java.lang.String uploadProtocol) { - return (Delete) super.setUploadProtocol(uploadProtocol); - } - - /** Required. The name of the package to delete. */ - @com.google.api.client.util.Key - private java.lang.String name; - - /** Required. The name of the package to delete. - */ - public java.lang.String getName() { - return name; - } - - /** Required. The name of the package to delete. */ - public Delete setName(java.lang.String name) { - if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); - } - this.name = name; - return this; - } - - @Override - public Delete set(String parameterName, Object value) { - return (Delete) super.set(parameterName, value); - } - } - /** - * Gets a package. - * - * Create a request for the method "packages.get". + * Create a request for the method "mavenArtifacts.get". * * This request holds the parameters needed by the artifactregistry server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. * - * @param name Required. The name of the package to retrieve. + * @param name Required. The name of the maven artifact. * @return the request */ public Get get(java.lang.String name) throws java.io.IOException { @@ -5845,33 +6046,33 @@ public Get get(java.lang.String name) throws java.io.IOException { return result; } - public class Get extends ArtifactRegistryRequest { + public class Get extends ArtifactRegistryRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/mavenArtifacts/[^/]+$"); /** - * Gets a package. + * Gets a maven artifact. * - * Create a request for the method "packages.get". + * Create a request for the method "mavenArtifacts.get". * * This request holds the parameters needed by the the artifactregistry server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

* {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor.

* - * @param name Required. The name of the package to retrieve. + * @param name Required. The name of the maven artifact. * @since 1.13 */ protected Get(java.lang.String name) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ArtifactRegistryPackage.class); + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.MavenArtifact.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/mavenArtifacts/[^/]+$"); } } @@ -5940,22 +6141,22 @@ public Get setUploadProtocol(java.lang.String uploadProtocol) { return (Get) super.setUploadProtocol(uploadProtocol); } - /** Required. The name of the package to retrieve. */ + /** Required. The name of the maven artifact. */ @com.google.api.client.util.Key private java.lang.String name; - /** Required. The name of the package to retrieve. + /** Required. The name of the maven artifact. */ public java.lang.String getName() { return name; } - /** Required. The name of the package to retrieve. */ + /** Required. The name of the maven artifact. */ public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/mavenArtifacts/[^/]+$"); } this.name = name; return this; @@ -5967,14 +6168,14 @@ public Get set(String parameterName, Object value) { } } /** - * Lists packages. + * Lists maven artifacts. * - * Create a request for the method "packages.list". + * Create a request for the method "mavenArtifacts.list". * * This request holds the parameters needed by the artifactregistry server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation. * - * @param parent Required. The name of the parent resource whose packages will be listed. + * @param parent Required. The name of the parent resource whose maven artifacts will be listed. * @return the request */ public List list(java.lang.String parent) throws java.io.IOException { @@ -5983,28 +6184,28 @@ public List list(java.lang.String parent) throws java.io.IOException { return result; } - public class List extends ArtifactRegistryRequest { + public class List extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+parent}/packages"; + private static final String REST_PATH = "v1/{+parent}/mavenArtifacts"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); /** - * Lists packages. + * Lists maven artifacts. * - * Create a request for the method "packages.list". + * Create a request for the method "mavenArtifacts.list". * * This request holds the parameters needed by the the artifactregistry server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

* {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor.

* - * @param parent Required. The name of the parent resource whose packages will be listed. + * @param parent Required. The name of the parent resource whose maven artifacts will be listed. * @since 1.13 */ protected List(java.lang.String parent) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListPackagesResponse.class); + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListMavenArtifactsResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -6078,17 +6279,17 @@ public List setUploadProtocol(java.lang.String uploadProtocol) { return (List) super.setUploadProtocol(uploadProtocol); } - /** Required. The name of the parent resource whose packages will be listed. */ + /** Required. The name of the parent resource whose maven artifacts will be listed. */ @com.google.api.client.util.Key private java.lang.String parent; - /** Required. The name of the parent resource whose packages will be listed. + /** Required. The name of the parent resource whose maven artifacts will be listed. */ public java.lang.String getParent() { return parent; } - /** Required. The name of the parent resource whose packages will be listed. */ + /** Required. The name of the parent resource whose maven artifacts will be listed. */ public List setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -6099,129 +6300,30 @@ public List setParent(java.lang.String parent) { return this; } - /** - * Optional. An expression for filtering the results of the request. Filter rules are - * case insensitive. The fields eligible for filtering are: * `name` * `annotations` - * Examples of using a filter: To filter the results of your request to packages with - * the name `my-package` in project `my-project` in the `us-central` region, in - * repository `my-repo`, append the following filter expression to your request: * - * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - * package"` You can also use wildcards to match any number of characters before or - * after the value: * `name="projects/my-project/locations/us-central1/repositories/my- - * repo/packages/my-*"` * `name="projects/my-project/locations/us- - * central1/repositories/my-repo/packagespackage"` * `name="projects/my- - * project/locations/us-central1/repositories/my-repo/packagespack*"` To filter the - * results of your request to packages with the annotation key-value pair - * [`external_link`: `external_link_value`], append the following filter expression to - * your request": * `"annotations.external_link:external_link_value"` To filter the - * results just for a specific annotation key `external_link`, append the following - * filter expression to your request: * `"annotations.external_link"` If the annotation - * key or value contains special characters, you can escape them by surrounding the - * value with backticks. For example, to filter the results of your request to packages - * with the annotation key-value pair [`external.link`:`https://example.com/my- - * package`], append the following filter expression to your request: * `` - * "annotations.`external.link`:`https://example.com/my-package`" `` You can also filter - * with annotations with a wildcard to match any number of characters before or after - * the value: * `` "annotations.*_link:`*example.com*`" `` + /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** The next_page_token value returned from a previous list request, if any. */ @com.google.api.client.util.Key - private java.lang.String filter; + private java.lang.String pageToken; - /** Optional. An expression for filtering the results of the request. Filter rules are case - insensitive. The fields eligible for filtering are: * `name` * `annotations` Examples of using a - filter: To filter the results of your request to packages with the name `my-package` in project - `my-project` in the `us-central` region, in repository `my-repo`, append the following filter - expression to your request: * `name="projects/my-project/locations/us-central1/repositories/my- - repo/packages/my-package"` You can also use wildcards to match any number of characters before or - after the value: * `name="projects/my-project/locations/us-central1/repositories/my- - repo/packages/my-*"` * `name="projects/my-project/locations/us-central1/repositories/my- - repo/packagespackage"` * `name="projects/my-project/locations/us-central1/repositories/my- - repo/packagespack*"` To filter the results of your request to packages with the annotation key- - value pair [`external_link`: `external_link_value`], append the following filter expression to your - request": * `"annotations.external_link:external_link_value"` To filter the results just for a - specific annotation key `external_link`, append the following filter expression to your request: * - `"annotations.external_link"` If the annotation key or value contains special characters, you can - escape them by surrounding the value with backticks. For example, to filter the results of your - request to packages with the annotation key-value pair [`external.link`:`https://example.com/my- - package`], append the following filter expression to your request: * `` - "annotations.`external.link`:`https://example.com/my-package`" `` You can also filter with - annotations with a wildcard to match any number of characters before or after the value: * `` - "annotations.*_link:`*example.com*`" `` + /** The next_page_token value returned from a previous list request, if any. */ - public java.lang.String getFilter() { - return filter; - } - - /** - * Optional. An expression for filtering the results of the request. Filter rules are - * case insensitive. The fields eligible for filtering are: * `name` * `annotations` - * Examples of using a filter: To filter the results of your request to packages with - * the name `my-package` in project `my-project` in the `us-central` region, in - * repository `my-repo`, append the following filter expression to your request: * - * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - * package"` You can also use wildcards to match any number of characters before or - * after the value: * `name="projects/my-project/locations/us-central1/repositories/my- - * repo/packages/my-*"` * `name="projects/my-project/locations/us- - * central1/repositories/my-repo/packagespackage"` * `name="projects/my- - * project/locations/us-central1/repositories/my-repo/packagespack*"` To filter the - * results of your request to packages with the annotation key-value pair - * [`external_link`: `external_link_value`], append the following filter expression to - * your request": * `"annotations.external_link:external_link_value"` To filter the - * results just for a specific annotation key `external_link`, append the following - * filter expression to your request: * `"annotations.external_link"` If the annotation - * key or value contains special characters, you can escape them by surrounding the - * value with backticks. For example, to filter the results of your request to packages - * with the annotation key-value pair [`external.link`:`https://example.com/my- - * package`], append the following filter expression to your request: * `` - * "annotations.`external.link`:`https://example.com/my-package`" `` You can also filter - * with annotations with a wildcard to match any number of characters before or after - * the value: * `` "annotations.*_link:`*example.com*`" `` - */ - public List setFilter(java.lang.String filter) { - this.filter = filter; - return this; - } - - /** Optional. The field to order the results by. */ - @com.google.api.client.util.Key - private java.lang.String orderBy; - - /** Optional. The field to order the results by. - */ - public java.lang.String getOrderBy() { - return orderBy; - } - - /** Optional. The field to order the results by. */ - public List setOrderBy(java.lang.String orderBy) { - this.orderBy = orderBy; - return this; - } - - /** The maximum number of packages to return. Maximum page size is 1,000. */ - @com.google.api.client.util.Key - private java.lang.Integer pageSize; - - /** The maximum number of packages to return. Maximum page size is 1,000. - */ - public java.lang.Integer getPageSize() { - return pageSize; - } - - /** The maximum number of packages to return. Maximum page size is 1,000. */ - public List setPageSize(java.lang.Integer pageSize) { - this.pageSize = pageSize; - return this; - } - - /** The next_page_token value returned from a previous list request, if any. */ - @com.google.api.client.util.Key - private java.lang.String pageToken; - - /** The next_page_token value returned from a previous list request, if any. - */ - public java.lang.String getPageToken() { - return pageToken; + public java.lang.String getPageToken() { + return pageToken; } /** The next_page_token value returned from a previous list request, if any. */ @@ -6235,657 +6337,2269 @@ public List set(String parameterName, Object value) { return (List) super.set(parameterName, value); } } + + } + /** + * An accessor for creating requests from the NpmPackages collection. + * + *

The typical use is:

+ *
+         *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
+         *   {@code ArtifactRegistry.NpmPackages.List request = artifactregistry.npmPackages().list(parameters ...)}
+         * 
+ * + * @return the resource collection + */ + public NpmPackages npmPackages() { + return new NpmPackages(); + } + + /** + * The "npmPackages" collection of methods. + */ + public class NpmPackages { + /** - * Updates a package. + * Gets a npm package. * - * Create a request for the method "packages.patch". + * Create a request for the method "npmPackages.get". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. * - * @param name The name of the package, for example: `projects/p1/locations/us- - * central1/repositories/repo1/packages/pkg1`. If the package ID part contains slashes, the - * slashes are escaped. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.ArtifactRegistryPackage} + * @param name Required. The name of the npm package. * @return the request */ - public Patch patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.ArtifactRegistryPackage content) throws java.io.IOException { - Patch result = new Patch(name, content); + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); initialize(result); return result; } - public class Patch extends ArtifactRegistryRequest { + public class Get extends ArtifactRegistryRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/npmPackages/[^/]+$"); /** - * Updates a package. + * Gets a npm package. * - * Create a request for the method "packages.patch". + * Create a request for the method "npmPackages.get". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. - *

{@link - * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must - * be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

* - * @param name The name of the package, for example: `projects/p1/locations/us- - * central1/repositories/repo1/packages/pkg1`. If the package ID part contains slashes, the - * slashes are escaped. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.ArtifactRegistryPackage} + * @param name Required. The name of the npm package. * @since 1.13 */ - protected Patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.ArtifactRegistryPackage content) { - super(ArtifactRegistry.this, "PATCH", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.ArtifactRegistryPackage.class); + protected Get(java.lang.String name) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.NpmPackage.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/npmPackages/[^/]+$"); } } @Override - public Patch set$Xgafv(java.lang.String $Xgafv) { - return (Patch) super.set$Xgafv($Xgafv); + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); } @Override - public Patch setAccessToken(java.lang.String accessToken) { - return (Patch) super.setAccessToken(accessToken); + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); } @Override - public Patch setAlt(java.lang.String alt) { - return (Patch) super.setAlt(alt); + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); } @Override - public Patch setCallback(java.lang.String callback) { - return (Patch) super.setCallback(callback); + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); } @Override - public Patch setFields(java.lang.String fields) { - return (Patch) super.setFields(fields); + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); } @Override - public Patch setKey(java.lang.String key) { - return (Patch) super.setKey(key); + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); } @Override - public Patch setOauthToken(java.lang.String oauthToken) { - return (Patch) super.setOauthToken(oauthToken); + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); } @Override - public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Patch) super.setPrettyPrint(prettyPrint); + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); } @Override - public Patch setQuotaUser(java.lang.String quotaUser) { - return (Patch) super.setQuotaUser(quotaUser); + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); } @Override - public Patch setUploadType(java.lang.String uploadType) { - return (Patch) super.setUploadType(uploadType); + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); } @Override - public Patch setUploadProtocol(java.lang.String uploadProtocol) { - return (Patch) super.setUploadProtocol(uploadProtocol); + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); } - /** - * The name of the package, for example: `projects/p1/locations/us- - * central1/repositories/repo1/packages/pkg1`. If the package ID part contains slashes, - * the slashes are escaped. - */ + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** Required. The name of the npm package. */ @com.google.api.client.util.Key private java.lang.String name; - /** The name of the package, for example: `projects/p1/locations/us- - central1/repositories/repo1/packages/pkg1`. If the package ID part contains slashes, the slashes - are escaped. + /** Required. The name of the npm package. */ public java.lang.String getName() { return name; } - /** - * The name of the package, for example: `projects/p1/locations/us- - * central1/repositories/repo1/packages/pkg1`. If the package ID part contains slashes, - * the slashes are escaped. - */ - public Patch setName(java.lang.String name) { + /** Required. The name of the npm package. */ + public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/npmPackages/[^/]+$"); } this.name = name; return this; } - /** - * The update mask applies to the resource. For the `FieldMask` definition, see - * https://developers.google.com/protocol- - * buffers/docs/reference/google.protobuf#fieldmask - */ - @com.google.api.client.util.Key - private String updateMask; - - /** The update mask applies to the resource. For the `FieldMask` definition, see - https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask - */ - public String getUpdateMask() { - return updateMask; - } - - /** - * The update mask applies to the resource. For the `FieldMask` definition, see - * https://developers.google.com/protocol- - * buffers/docs/reference/google.protobuf#fieldmask - */ - public Patch setUpdateMask(String updateMask) { - this.updateMask = updateMask; - return this; - } - @Override - public Patch set(String parameterName, Object value) { - return (Patch) super.set(parameterName, value); + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); } } - /** - * An accessor for creating requests from the Tags collection. + * Lists npm packages. * - *

The typical use is:

- *
-           *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
-           *   {@code ArtifactRegistry.Tags.List request = artifactregistry.tags().list(parameters ...)}
-           * 
+ * Create a request for the method "npmPackages.list". * - * @return the resource collection + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param parent Required. The name of the parent resource whose npm packages will be listed. + * @return the request */ - public Tags tags() { - return new Tags(); + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); + initialize(result); + return result; } - /** - * The "tags" collection of methods. - */ - public class Tags { + public class List extends ArtifactRegistryRequest { - /** - * Creates a tag. - * - * Create a request for the method "tags.create". + private static final String REST_PATH = "v1/{+parent}/npmPackages"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + + /** + * Lists npm packages. * - * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. + * Create a request for the method "npmPackages.list". * - * @param parent The name of the parent resource where the tag will be created. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.Tag} - * @return the request + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent Required. The name of the parent resource whose npm packages will be listed. + * @since 1.13 */ - public Create create(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.Tag content) throws java.io.IOException { - Create result = new Create(parent, content); - initialize(result); - return result; + protected List(java.lang.String parent) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListNpmPackagesResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + } } - public class Create extends ArtifactRegistryRequest { - - private static final String REST_PATH = "v1/{+parent}/tags"; + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } - private final java.util.regex.Pattern PARENT_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } - /** - * Creates a tag. - * - * Create a request for the method "tags.create". - * - * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. - *

{@link - * Create#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must - * be called to initialize this instance immediately after invoking the constructor.

- * - * @param parent The name of the parent resource where the tag will be created. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.Tag} - * @since 1.13 - */ - protected Create(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.Tag content) { - super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.Tag.class); - this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); - if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); - } - } + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } - @Override - public Create set$Xgafv(java.lang.String $Xgafv) { - return (Create) super.set$Xgafv($Xgafv); - } + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } - @Override - public Create setAccessToken(java.lang.String accessToken) { - return (Create) super.setAccessToken(accessToken); - } + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } - @Override - public Create setAlt(java.lang.String alt) { - return (Create) super.setAlt(alt); - } + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } - @Override - public Create setCallback(java.lang.String callback) { - return (Create) super.setCallback(callback); - } + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } - @Override - public Create setFields(java.lang.String fields) { - return (Create) super.setFields(fields); - } + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } - @Override - public Create setKey(java.lang.String key) { - return (Create) super.setKey(key); - } + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } - @Override - public Create setOauthToken(java.lang.String oauthToken) { - return (Create) super.setOauthToken(oauthToken); - } + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } - @Override - public Create setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Create) super.setPrettyPrint(prettyPrint); - } + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } - @Override - public Create setQuotaUser(java.lang.String quotaUser) { - return (Create) super.setQuotaUser(quotaUser); - } + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } - @Override - public Create setUploadType(java.lang.String uploadType) { - return (Create) super.setUploadType(uploadType); - } + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } - @Override - public Create setUploadProtocol(java.lang.String uploadProtocol) { - return (Create) super.setUploadProtocol(uploadProtocol); - } + /** Required. The name of the parent resource whose npm packages will be listed. */ + @com.google.api.client.util.Key + private java.lang.String parent; - /** The name of the parent resource where the tag will be created. */ - @com.google.api.client.util.Key - private java.lang.String parent; + /** Required. The name of the parent resource whose npm packages will be listed. + */ + public java.lang.String getParent() { + return parent; + } - /** The name of the parent resource where the tag will be created. - */ - public java.lang.String getParent() { - return parent; + /** Required. The name of the parent resource whose npm packages will be listed. */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); } + this.parent = parent; + return this; + } - /** The name of the parent resource where the tag will be created. */ - public Create setParent(java.lang.String parent) { - if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); - } - this.parent = parent; - return this; - } + /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; - /** The tag id to use for this repository. */ - @com.google.api.client.util.Key - private java.lang.String tagId; + /** The maximum number of artifacts to return. Maximum page size is 1,000. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } - /** The tag id to use for this repository. - */ - public java.lang.String getTagId() { - return tagId; - } + /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } - /** The tag id to use for this repository. */ - public Create setTagId(java.lang.String tagId) { - this.tagId = tagId; - return this; - } + /** The next_page_token value returned from a previous list request, if any. */ + @com.google.api.client.util.Key + private java.lang.String pageToken; - @Override - public Create set(String parameterName, Object value) { - return (Create) super.set(parameterName, value); - } - } - /** - * Deletes a tag. - * - * Create a request for the method "tags.delete". - * - * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. - * - * @param name The name of the tag to delete. - * @return the request + /** The next_page_token value returned from a previous list request, if any. */ - public Delete delete(java.lang.String name) throws java.io.IOException { - Delete result = new Delete(name); - initialize(result); - return result; + public java.lang.String getPageToken() { + return pageToken; } - public class Delete extends ArtifactRegistryRequest { + /** The next_page_token value returned from a previous list request, if any. */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } - private static final String REST_PATH = "v1/{+name}"; + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } - private final java.util.regex.Pattern NAME_PATTERN = + } + /** + * An accessor for creating requests from the Packages collection. + * + *

The typical use is:

+ *
+         *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
+         *   {@code ArtifactRegistry.Packages.List request = artifactregistry.packages().list(parameters ...)}
+         * 
+ * + * @return the resource collection + */ + public Packages packages() { + return new Packages(); + } + + /** + * The "packages" collection of methods. + */ + public class Packages { + + /** + * Deletes a package and all of its versions and tags. The returned operation will complete once the + * package has been deleted. + * + * Create a request for the method "packages.delete". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + * + * @param name Required. The name of the package to delete. + * @return the request + */ + public Delete delete(java.lang.String name) throws java.io.IOException { + Delete result = new Delete(name); + initialize(result); + return result; + } + + public class Delete extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + + /** + * Deletes a package and all of its versions and tags. The returned operation will complete once + * the package has been deleted. + * + * Create a request for the method "packages.delete". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + *

{@link + * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name Required. The name of the package to delete. + * @since 1.13 + */ + protected Delete(java.lang.String name) { + super(ArtifactRegistry.this, "DELETE", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Operation.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + } + } + + @Override + public Delete set$Xgafv(java.lang.String $Xgafv) { + return (Delete) super.set$Xgafv($Xgafv); + } + + @Override + public Delete setAccessToken(java.lang.String accessToken) { + return (Delete) super.setAccessToken(accessToken); + } + + @Override + public Delete setAlt(java.lang.String alt) { + return (Delete) super.setAlt(alt); + } + + @Override + public Delete setCallback(java.lang.String callback) { + return (Delete) super.setCallback(callback); + } + + @Override + public Delete setFields(java.lang.String fields) { + return (Delete) super.setFields(fields); + } + + @Override + public Delete setKey(java.lang.String key) { + return (Delete) super.setKey(key); + } + + @Override + public Delete setOauthToken(java.lang.String oauthToken) { + return (Delete) super.setOauthToken(oauthToken); + } + + @Override + public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Delete) super.setPrettyPrint(prettyPrint); + } + + @Override + public Delete setQuotaUser(java.lang.String quotaUser) { + return (Delete) super.setQuotaUser(quotaUser); + } + + @Override + public Delete setUploadType(java.lang.String uploadType) { + return (Delete) super.setUploadType(uploadType); + } + + @Override + public Delete setUploadProtocol(java.lang.String uploadProtocol) { + return (Delete) super.setUploadProtocol(uploadProtocol); + } + + /** Required. The name of the package to delete. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** Required. The name of the package to delete. + */ + public java.lang.String getName() { + return name; + } + + /** Required. The name of the package to delete. */ + public Delete setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Delete set(String parameterName, Object value) { + return (Delete) super.set(parameterName, value); + } + } + /** + * Gets a package. + * + * Create a request for the method "packages.get". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name Required. The name of the package to retrieve. + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + + /** + * Gets a package. + * + * Create a request for the method "packages.get". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name Required. The name of the package to retrieve. + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ArtifactRegistryPackage.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** Required. The name of the package to retrieve. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** Required. The name of the package to retrieve. + */ + public java.lang.String getName() { + return name; + } + + /** Required. The name of the package to retrieve. */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + /** + * Lists packages. + * + * Create a request for the method "packages.list". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param parent Required. The name of the parent resource whose packages will be listed. + * @return the request + */ + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); + initialize(result); + return result; + } + + public class List extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+parent}/packages"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + + /** + * Lists packages. + * + * Create a request for the method "packages.list". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent Required. The name of the parent resource whose packages will be listed. + * @since 1.13 + */ + protected List(java.lang.String parent) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListPackagesResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** Required. The name of the parent resource whose packages will be listed. */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** Required. The name of the parent resource whose packages will be listed. + */ + public java.lang.String getParent() { + return parent; + } + + /** Required. The name of the parent resource whose packages will be listed. */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + } + this.parent = parent; + return this; + } + + /** + * Optional. An expression for filtering the results of the request. Filter rules are + * case insensitive. The fields eligible for filtering are: * `name` * `annotations` + * Examples of using a filter: To filter the results of your request to packages with + * the name `my-package` in project `my-project` in the `us-central` region, in + * repository `my-repo`, append the following filter expression to your request: * + * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + * package"` You can also use wildcards to match any number of characters before or + * after the value: * `name="projects/my-project/locations/us-central1/repositories/my- + * repo/packages/my-*"` * `name="projects/my-project/locations/us- + * central1/repositories/my-repo/packagespackage"` * `name="projects/my- + * project/locations/us-central1/repositories/my-repo/packagespack*"` To filter the + * results of your request to packages with the annotation key-value pair + * [`external_link`: `external_link_value`], append the following filter expression to + * your request": * `"annotations.external_link:external_link_value"` To filter the + * results just for a specific annotation key `external_link`, append the following + * filter expression to your request: * `"annotations.external_link"` If the annotation + * key or value contains special characters, you can escape them by surrounding the + * value with backticks. For example, to filter the results of your request to packages + * with the annotation key-value pair [`external.link`:`https://example.com/my- + * package`], append the following filter expression to your request: * `` + * "annotations.`external.link`:`https://example.com/my-package`" `` You can also filter + * with annotations with a wildcard to match any number of characters before or after + * the value: * `` "annotations.*_link:`*example.com*`" `` + */ + @com.google.api.client.util.Key + private java.lang.String filter; + + /** Optional. An expression for filtering the results of the request. Filter rules are case + insensitive. The fields eligible for filtering are: * `name` * `annotations` Examples of using a + filter: To filter the results of your request to packages with the name `my-package` in project + `my-project` in the `us-central` region, in repository `my-repo`, append the following filter + expression to your request: * `name="projects/my-project/locations/us-central1/repositories/my- + repo/packages/my-package"` You can also use wildcards to match any number of characters before or + after the value: * `name="projects/my-project/locations/us-central1/repositories/my- + repo/packages/my-*"` * `name="projects/my-project/locations/us-central1/repositories/my- + repo/packagespackage"` * `name="projects/my-project/locations/us-central1/repositories/my- + repo/packagespack*"` To filter the results of your request to packages with the annotation key- + value pair [`external_link`: `external_link_value`], append the following filter expression to your + request": * `"annotations.external_link:external_link_value"` To filter the results just for a + specific annotation key `external_link`, append the following filter expression to your request: * + `"annotations.external_link"` If the annotation key or value contains special characters, you can + escape them by surrounding the value with backticks. For example, to filter the results of your + request to packages with the annotation key-value pair [`external.link`:`https://example.com/my- + package`], append the following filter expression to your request: * `` + "annotations.`external.link`:`https://example.com/my-package`" `` You can also filter with + annotations with a wildcard to match any number of characters before or after the value: * `` + "annotations.*_link:`*example.com*`" `` + */ + public java.lang.String getFilter() { + return filter; + } + + /** + * Optional. An expression for filtering the results of the request. Filter rules are + * case insensitive. The fields eligible for filtering are: * `name` * `annotations` + * Examples of using a filter: To filter the results of your request to packages with + * the name `my-package` in project `my-project` in the `us-central` region, in + * repository `my-repo`, append the following filter expression to your request: * + * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + * package"` You can also use wildcards to match any number of characters before or + * after the value: * `name="projects/my-project/locations/us-central1/repositories/my- + * repo/packages/my-*"` * `name="projects/my-project/locations/us- + * central1/repositories/my-repo/packagespackage"` * `name="projects/my- + * project/locations/us-central1/repositories/my-repo/packagespack*"` To filter the + * results of your request to packages with the annotation key-value pair + * [`external_link`: `external_link_value`], append the following filter expression to + * your request": * `"annotations.external_link:external_link_value"` To filter the + * results just for a specific annotation key `external_link`, append the following + * filter expression to your request: * `"annotations.external_link"` If the annotation + * key or value contains special characters, you can escape them by surrounding the + * value with backticks. For example, to filter the results of your request to packages + * with the annotation key-value pair [`external.link`:`https://example.com/my- + * package`], append the following filter expression to your request: * `` + * "annotations.`external.link`:`https://example.com/my-package`" `` You can also filter + * with annotations with a wildcard to match any number of characters before or after + * the value: * `` "annotations.*_link:`*example.com*`" `` + */ + public List setFilter(java.lang.String filter) { + this.filter = filter; + return this; + } + + /** Optional. The field to order the results by. */ + @com.google.api.client.util.Key + private java.lang.String orderBy; + + /** Optional. The field to order the results by. + */ + public java.lang.String getOrderBy() { + return orderBy; + } + + /** Optional. The field to order the results by. */ + public List setOrderBy(java.lang.String orderBy) { + this.orderBy = orderBy; + return this; + } + + /** The maximum number of packages to return. Maximum page size is 1,000. */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** The maximum number of packages to return. Maximum page size is 1,000. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** The maximum number of packages to return. Maximum page size is 1,000. */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** The next_page_token value returned from a previous list request, if any. */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** The next_page_token value returned from a previous list request, if any. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** The next_page_token value returned from a previous list request, if any. */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + /** + * Updates a package. + * + * Create a request for the method "packages.patch". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. + * + * @param name The name of the package, for example: `projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1`. If the package ID part contains slashes, the + * slashes are escaped. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.ArtifactRegistryPackage} + * @return the request + */ + public Patch patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.ArtifactRegistryPackage content) throws java.io.IOException { + Patch result = new Patch(name, content); + initialize(result); + return result; + } + + public class Patch extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + + /** + * Updates a package. + * + * Create a request for the method "packages.patch". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. + *

{@link + * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the package, for example: `projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1`. If the package ID part contains slashes, the + * slashes are escaped. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.ArtifactRegistryPackage} + * @since 1.13 + */ + protected Patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.ArtifactRegistryPackage content) { + super(ArtifactRegistry.this, "PATCH", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.ArtifactRegistryPackage.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + } + } + + @Override + public Patch set$Xgafv(java.lang.String $Xgafv) { + return (Patch) super.set$Xgafv($Xgafv); + } + + @Override + public Patch setAccessToken(java.lang.String accessToken) { + return (Patch) super.setAccessToken(accessToken); + } + + @Override + public Patch setAlt(java.lang.String alt) { + return (Patch) super.setAlt(alt); + } + + @Override + public Patch setCallback(java.lang.String callback) { + return (Patch) super.setCallback(callback); + } + + @Override + public Patch setFields(java.lang.String fields) { + return (Patch) super.setFields(fields); + } + + @Override + public Patch setKey(java.lang.String key) { + return (Patch) super.setKey(key); + } + + @Override + public Patch setOauthToken(java.lang.String oauthToken) { + return (Patch) super.setOauthToken(oauthToken); + } + + @Override + public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Patch) super.setPrettyPrint(prettyPrint); + } + + @Override + public Patch setQuotaUser(java.lang.String quotaUser) { + return (Patch) super.setQuotaUser(quotaUser); + } + + @Override + public Patch setUploadType(java.lang.String uploadType) { + return (Patch) super.setUploadType(uploadType); + } + + @Override + public Patch setUploadProtocol(java.lang.String uploadProtocol) { + return (Patch) super.setUploadProtocol(uploadProtocol); + } + + /** + * The name of the package, for example: `projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1`. If the package ID part contains slashes, + * the slashes are escaped. + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the package, for example: `projects/p1/locations/us- + central1/repositories/repo1/packages/pkg1`. If the package ID part contains slashes, the slashes + are escaped. + */ + public java.lang.String getName() { + return name; + } + + /** + * The name of the package, for example: `projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1`. If the package ID part contains slashes, + * the slashes are escaped. + */ + public Patch setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + } + this.name = name; + return this; + } + + /** + * The update mask applies to the resource. For the `FieldMask` definition, see + * https://developers.google.com/protocol- + * buffers/docs/reference/google.protobuf#fieldmask + */ + @com.google.api.client.util.Key + private String updateMask; + + /** The update mask applies to the resource. For the `FieldMask` definition, see + https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + */ + public String getUpdateMask() { + return updateMask; + } + + /** + * The update mask applies to the resource. For the `FieldMask` definition, see + * https://developers.google.com/protocol- + * buffers/docs/reference/google.protobuf#fieldmask + */ + public Patch setUpdateMask(String updateMask) { + this.updateMask = updateMask; + return this; + } + + @Override + public Patch set(String parameterName, Object value) { + return (Patch) super.set(parameterName, value); + } + } + + /** + * An accessor for creating requests from the Tags collection. + * + *

The typical use is:

+ *
+           *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
+           *   {@code ArtifactRegistry.Tags.List request = artifactregistry.tags().list(parameters ...)}
+           * 
+ * + * @return the resource collection + */ + public Tags tags() { + return new Tags(); + } + + /** + * The "tags" collection of methods. + */ + public class Tags { + + /** + * Creates a tag. + * + * Create a request for the method "tags.create". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. + * + * @param parent The name of the parent resource where the tag will be created. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.Tag} + * @return the request + */ + public Create create(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.Tag content) throws java.io.IOException { + Create result = new Create(parent, content); + initialize(result); + return result; + } + + public class Create extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+parent}/tags"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + + /** + * Creates a tag. + * + * Create a request for the method "tags.create". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. + *

{@link + * Create#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent The name of the parent resource where the tag will be created. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.Tag} + * @since 1.13 + */ + protected Create(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.Tag content) { + super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.Tag.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + } + } + + @Override + public Create set$Xgafv(java.lang.String $Xgafv) { + return (Create) super.set$Xgafv($Xgafv); + } + + @Override + public Create setAccessToken(java.lang.String accessToken) { + return (Create) super.setAccessToken(accessToken); + } + + @Override + public Create setAlt(java.lang.String alt) { + return (Create) super.setAlt(alt); + } + + @Override + public Create setCallback(java.lang.String callback) { + return (Create) super.setCallback(callback); + } + + @Override + public Create setFields(java.lang.String fields) { + return (Create) super.setFields(fields); + } + + @Override + public Create setKey(java.lang.String key) { + return (Create) super.setKey(key); + } + + @Override + public Create setOauthToken(java.lang.String oauthToken) { + return (Create) super.setOauthToken(oauthToken); + } + + @Override + public Create setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Create) super.setPrettyPrint(prettyPrint); + } + + @Override + public Create setQuotaUser(java.lang.String quotaUser) { + return (Create) super.setQuotaUser(quotaUser); + } + + @Override + public Create setUploadType(java.lang.String uploadType) { + return (Create) super.setUploadType(uploadType); + } + + @Override + public Create setUploadProtocol(java.lang.String uploadProtocol) { + return (Create) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the parent resource where the tag will be created. */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** The name of the parent resource where the tag will be created. + */ + public java.lang.String getParent() { + return parent; + } + + /** The name of the parent resource where the tag will be created. */ + public Create setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + } + this.parent = parent; + return this; + } + + /** The tag id to use for this repository. */ + @com.google.api.client.util.Key + private java.lang.String tagId; + + /** The tag id to use for this repository. + */ + public java.lang.String getTagId() { + return tagId; + } + + /** The tag id to use for this repository. */ + public Create setTagId(java.lang.String tagId) { + this.tagId = tagId; + return this; + } + + @Override + public Create set(String parameterName, Object value) { + return (Create) super.set(parameterName, value); + } + } + /** + * Deletes a tag. + * + * Create a request for the method "tags.delete". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + * + * @param name The name of the tag to delete. + * @return the request + */ + public Delete delete(java.lang.String name) throws java.io.IOException { + Delete result = new Delete(name); + initialize(result); + return result; + } + + public class Delete extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + + /** + * Deletes a tag. + * + * Create a request for the method "tags.delete". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + *

{@link + * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the tag to delete. + * @since 1.13 + */ + protected Delete(java.lang.String name) { + super(ArtifactRegistry.this, "DELETE", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Empty.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + } + } + + @Override + public Delete set$Xgafv(java.lang.String $Xgafv) { + return (Delete) super.set$Xgafv($Xgafv); + } + + @Override + public Delete setAccessToken(java.lang.String accessToken) { + return (Delete) super.setAccessToken(accessToken); + } + + @Override + public Delete setAlt(java.lang.String alt) { + return (Delete) super.setAlt(alt); + } + + @Override + public Delete setCallback(java.lang.String callback) { + return (Delete) super.setCallback(callback); + } + + @Override + public Delete setFields(java.lang.String fields) { + return (Delete) super.setFields(fields); + } + + @Override + public Delete setKey(java.lang.String key) { + return (Delete) super.setKey(key); + } + + @Override + public Delete setOauthToken(java.lang.String oauthToken) { + return (Delete) super.setOauthToken(oauthToken); + } + + @Override + public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Delete) super.setPrettyPrint(prettyPrint); + } + + @Override + public Delete setQuotaUser(java.lang.String quotaUser) { + return (Delete) super.setQuotaUser(quotaUser); + } + + @Override + public Delete setUploadType(java.lang.String uploadType) { + return (Delete) super.setUploadType(uploadType); + } + + @Override + public Delete setUploadProtocol(java.lang.String uploadProtocol) { + return (Delete) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the tag to delete. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the tag to delete. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the tag to delete. */ + public Delete setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Delete set(String parameterName, Object value) { + return (Delete) super.set(parameterName, value); + } + } + /** + * Gets a tag. + * + * Create a request for the method "tags.get". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name The name of the tag to retrieve. + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + + /** + * Gets a tag. + * + * Create a request for the method "tags.get". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the tag to retrieve. + * @since 1.13 + */ + protected Get(java.lang.String name) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Tag.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } + + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } + + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } + + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } + + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } + + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } + + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } + + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } + + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } + + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } + + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } + + /** The name of the tag to retrieve. */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the tag to retrieve. + */ + public java.lang.String getName() { + return name; + } + + /** The name of the tag to retrieve. */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + } + this.name = name; + return this; + } + + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + /** + * Lists tags. + * + * Create a request for the method "tags.list". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param parent The name of the parent package whose tags will be listed. For example: `projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1`. + * @return the request + */ + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); + initialize(result); + return result; + } + + public class List extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+parent}/tags"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + + /** + * Lists tags. + * + * Create a request for the method "tags.list". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

+ * + * @param parent The name of the parent package whose tags will be listed. For example: `projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1`. + * @since 1.13 + */ + protected List(java.lang.String parent) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListTagsResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + } + } + + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } + + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } + + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } + + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } + + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } + + /** + * The name of the parent package whose tags will be listed. For example: + * `projects/p1/locations/us-central1/repositories/repo1/packages/pkg1`. + */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** The name of the parent package whose tags will be listed. For example: `projects/p1/locations/us- + central1/repositories/repo1/packages/pkg1`. + */ + public java.lang.String getParent() { + return parent; + } + + /** + * The name of the parent package whose tags will be listed. For example: + * `projects/p1/locations/us-central1/repositories/repo1/packages/pkg1`. + */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + } + this.parent = parent; + return this; + } + + /** + * An expression for filtering the results of the request. Filter rules are case + * insensitive. The fields eligible for filtering are: * `name` * `version` Examples + * of using a filter: To filter the results of your request to tags with the name `my- + * tag` in package `my-package` in repository `my-repo` in project "`y-project` in the + * us-central region, append the following filter expression to your request: * + * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + * package/tags/my-tag"` You can also use wildcards to match any number of characters + * before or after the value: * `name="projects/my-project/locations/us- + * central1/repositories/my-repo/packages/my-package/tags/my*"` * `name="projects/my- + * project/locations/us-central1/repositories/my-repo/packages/my-package/tagstag"` * + * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + * package/tagstag*"` To filter the results of your request to tags applied to the + * version `1.0` in package `my-package`, append the following filter expression to + * your request: * `version="projects/my-project/locations/us- + * central1/repositories/my-repo/packages/my-package/versions/1.0"` + */ + @com.google.api.client.util.Key + private java.lang.String filter; + + /** An expression for filtering the results of the request. Filter rules are case insensitive. The + fields eligible for filtering are: * `name` * `version` Examples of using a filter: To filter the + results of your request to tags with the name `my-tag` in package `my-package` in repository `my- + repo` in project "`y-project` in the us-central region, append the following filter expression to + your request: * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + package/tags/my-tag"` You can also use wildcards to match any number of characters before or after + the value: * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + package/tags/my*"` * `name="projects/my-project/locations/us-central1/repositories/my- + repo/packages/my-package/tagstag"` * `name="projects/my-project/locations/us- + central1/repositories/my-repo/packages/my-package/tagstag*"` To filter the results of your request + to tags applied to the version `1.0` in package `my-package`, append the following filter + expression to your request: * `version="projects/my-project/locations/us-central1/repositories/my- + repo/packages/my-package/versions/1.0"` + */ + public java.lang.String getFilter() { + return filter; + } + + /** + * An expression for filtering the results of the request. Filter rules are case + * insensitive. The fields eligible for filtering are: * `name` * `version` Examples + * of using a filter: To filter the results of your request to tags with the name `my- + * tag` in package `my-package` in repository `my-repo` in project "`y-project` in the + * us-central region, append the following filter expression to your request: * + * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + * package/tags/my-tag"` You can also use wildcards to match any number of characters + * before or after the value: * `name="projects/my-project/locations/us- + * central1/repositories/my-repo/packages/my-package/tags/my*"` * `name="projects/my- + * project/locations/us-central1/repositories/my-repo/packages/my-package/tagstag"` * + * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + * package/tagstag*"` To filter the results of your request to tags applied to the + * version `1.0` in package `my-package`, append the following filter expression to + * your request: * `version="projects/my-project/locations/us- + * central1/repositories/my-repo/packages/my-package/versions/1.0"` + */ + public List setFilter(java.lang.String filter) { + this.filter = filter; + return this; + } + + /** The maximum number of tags to return. Maximum page size is 1,000. */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** The maximum number of tags to return. Maximum page size is 1,000. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** The maximum number of tags to return. Maximum page size is 1,000. */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } + + /** The next_page_token value returned from a previous list request, if any. */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** The next_page_token value returned from a previous list request, if any. + */ + public java.lang.String getPageToken() { + return pageToken; + } + + /** The next_page_token value returned from a previous list request, if any. */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + /** + * Updates a tag. + * + * Create a request for the method "tags.patch". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. + * + * @param name The name of the tag, for example: "projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1/tags/tag1". If the package part contains + * slashes, the slashes are escaped. The tag part can only have characters in + * [a-zA-Z0-9\-._~:@], anything else must be URL encoded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.Tag} + * @return the request + */ + public Patch patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.Tag content) throws java.io.IOException { + Patch result = new Patch(name, content); + initialize(result); + return result; + } + + public class Patch extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); /** - * Deletes a tag. + * Updates a tag. + * + * Create a request for the method "tags.patch". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. + *

{@link + * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the tag, for example: "projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1/tags/tag1". If the package part contains + * slashes, the slashes are escaped. The tag part can only have characters in + * [a-zA-Z0-9\-._~:@], anything else must be URL encoded. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.Tag} + * @since 1.13 + */ + protected Patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.Tag content) { + super(ArtifactRegistry.this, "PATCH", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.Tag.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + } + } + + @Override + public Patch set$Xgafv(java.lang.String $Xgafv) { + return (Patch) super.set$Xgafv($Xgafv); + } + + @Override + public Patch setAccessToken(java.lang.String accessToken) { + return (Patch) super.setAccessToken(accessToken); + } + + @Override + public Patch setAlt(java.lang.String alt) { + return (Patch) super.setAlt(alt); + } + + @Override + public Patch setCallback(java.lang.String callback) { + return (Patch) super.setCallback(callback); + } + + @Override + public Patch setFields(java.lang.String fields) { + return (Patch) super.setFields(fields); + } + + @Override + public Patch setKey(java.lang.String key) { + return (Patch) super.setKey(key); + } + + @Override + public Patch setOauthToken(java.lang.String oauthToken) { + return (Patch) super.setOauthToken(oauthToken); + } + + @Override + public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Patch) super.setPrettyPrint(prettyPrint); + } + + @Override + public Patch setQuotaUser(java.lang.String quotaUser) { + return (Patch) super.setQuotaUser(quotaUser); + } + + @Override + public Patch setUploadType(java.lang.String uploadType) { + return (Patch) super.setUploadType(uploadType); + } + + @Override + public Patch setUploadProtocol(java.lang.String uploadProtocol) { + return (Patch) super.setUploadProtocol(uploadProtocol); + } + + /** + * The name of the tag, for example: "projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1/tags/tag1". If the package part contains + * slashes, the slashes are escaped. The tag part can only have characters in + * [a-zA-Z0-9\-._~:@], anything else must be URL encoded. + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the tag, for example: "projects/p1/locations/us- + central1/repositories/repo1/packages/pkg1/tags/tag1". If the package part contains slashes, the + slashes are escaped. The tag part can only have characters in [a-zA-Z0-9\-._~:@], anything else + must be URL encoded. + */ + public java.lang.String getName() { + return name; + } + + /** + * The name of the tag, for example: "projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1/tags/tag1". If the package part contains + * slashes, the slashes are escaped. The tag part can only have characters in + * [a-zA-Z0-9\-._~:@], anything else must be URL encoded. + */ + public Patch setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + } + this.name = name; + return this; + } + + /** + * The update mask applies to the resource. For the `FieldMask` definition, see + * https://developers.google.com/protocol- + * buffers/docs/reference/google.protobuf#fieldmask + */ + @com.google.api.client.util.Key + private String updateMask; + + /** The update mask applies to the resource. For the `FieldMask` definition, see + https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + */ + public String getUpdateMask() { + return updateMask; + } + + /** + * The update mask applies to the resource. For the `FieldMask` definition, see + * https://developers.google.com/protocol- + * buffers/docs/reference/google.protobuf#fieldmask + */ + public Patch setUpdateMask(String updateMask) { + this.updateMask = updateMask; + return this; + } + + @Override + public Patch set(String parameterName, Object value) { + return (Patch) super.set(parameterName, value); + } + } + + } + /** + * An accessor for creating requests from the Versions collection. + * + *

The typical use is:

+ *
+           *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
+           *   {@code ArtifactRegistry.Versions.List request = artifactregistry.versions().list(parameters ...)}
+           * 
+ * + * @return the resource collection + */ + public Versions versions() { + return new Versions(); + } + + /** + * The "versions" collection of methods. + */ + public class Versions { + + /** + * Deletes multiple versions across a repository. The returned operation will complete once the + * versions have been deleted. + * + * Create a request for the method "versions.batchDelete". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link BatchDelete#execute()} method to invoke the remote + * operation. + * + * @param parent The name of the repository holding all requested versions. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.BatchDeleteVersionsRequest} + * @return the request + */ + public BatchDelete batchDelete(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.BatchDeleteVersionsRequest content) throws java.io.IOException { + BatchDelete result = new BatchDelete(parent, content); + initialize(result); + return result; + } + + public class BatchDelete extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+parent}/versions:batchDelete"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + + /** + * Deletes multiple versions across a repository. The returned operation will complete once the + * versions have been deleted. * - * Create a request for the method "tags.delete". + * Create a request for the method "versions.batchDelete". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. - *

{@link - * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must - * be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link BatchDelete#execute()} method to invoke the remote + * operation.

{@link + * BatchDelete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

* - * @param name The name of the tag to delete. + * @param parent The name of the repository holding all requested versions. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.BatchDeleteVersionsRequest} * @since 1.13 */ - protected Delete(java.lang.String name) { - super(ArtifactRegistry.this, "DELETE", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Empty.class); - this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + protected BatchDelete(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.BatchDeleteVersionsRequest content) { + super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.Operation.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); } } @Override - public Delete set$Xgafv(java.lang.String $Xgafv) { - return (Delete) super.set$Xgafv($Xgafv); + public BatchDelete set$Xgafv(java.lang.String $Xgafv) { + return (BatchDelete) super.set$Xgafv($Xgafv); } @Override - public Delete setAccessToken(java.lang.String accessToken) { - return (Delete) super.setAccessToken(accessToken); + public BatchDelete setAccessToken(java.lang.String accessToken) { + return (BatchDelete) super.setAccessToken(accessToken); } @Override - public Delete setAlt(java.lang.String alt) { - return (Delete) super.setAlt(alt); + public BatchDelete setAlt(java.lang.String alt) { + return (BatchDelete) super.setAlt(alt); } @Override - public Delete setCallback(java.lang.String callback) { - return (Delete) super.setCallback(callback); + public BatchDelete setCallback(java.lang.String callback) { + return (BatchDelete) super.setCallback(callback); } @Override - public Delete setFields(java.lang.String fields) { - return (Delete) super.setFields(fields); + public BatchDelete setFields(java.lang.String fields) { + return (BatchDelete) super.setFields(fields); } @Override - public Delete setKey(java.lang.String key) { - return (Delete) super.setKey(key); + public BatchDelete setKey(java.lang.String key) { + return (BatchDelete) super.setKey(key); } @Override - public Delete setOauthToken(java.lang.String oauthToken) { - return (Delete) super.setOauthToken(oauthToken); + public BatchDelete setOauthToken(java.lang.String oauthToken) { + return (BatchDelete) super.setOauthToken(oauthToken); } @Override - public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Delete) super.setPrettyPrint(prettyPrint); + public BatchDelete setPrettyPrint(java.lang.Boolean prettyPrint) { + return (BatchDelete) super.setPrettyPrint(prettyPrint); } @Override - public Delete setQuotaUser(java.lang.String quotaUser) { - return (Delete) super.setQuotaUser(quotaUser); + public BatchDelete setQuotaUser(java.lang.String quotaUser) { + return (BatchDelete) super.setQuotaUser(quotaUser); } @Override - public Delete setUploadType(java.lang.String uploadType) { - return (Delete) super.setUploadType(uploadType); + public BatchDelete setUploadType(java.lang.String uploadType) { + return (BatchDelete) super.setUploadType(uploadType); } @Override - public Delete setUploadProtocol(java.lang.String uploadProtocol) { - return (Delete) super.setUploadProtocol(uploadProtocol); + public BatchDelete setUploadProtocol(java.lang.String uploadProtocol) { + return (BatchDelete) super.setUploadProtocol(uploadProtocol); } - /** The name of the tag to delete. */ + /** The name of the repository holding all requested versions. */ @com.google.api.client.util.Key - private java.lang.String name; + private java.lang.String parent; - /** The name of the tag to delete. + /** The name of the repository holding all requested versions. */ - public java.lang.String getName() { - return name; + public java.lang.String getParent() { + return parent; } - /** The name of the tag to delete. */ - public Delete setName(java.lang.String name) { + /** The name of the repository holding all requested versions. */ + public BatchDelete setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); } - this.name = name; + this.parent = parent; return this; } @Override - public Delete set(String parameterName, Object value) { - return (Delete) super.set(parameterName, value); + public BatchDelete set(String parameterName, Object value) { + return (BatchDelete) super.set(parameterName, value); } } /** - * Gets a tag. + * Deletes a version and all of its content. The returned operation will complete once the version + * has been deleted. * - * Create a request for the method "tags.get". + * Create a request for the method "versions.delete". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. + * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. * - * @param name The name of the tag to retrieve. + * @param name The name of the version to delete. * @return the request */ - public Get get(java.lang.String name) throws java.io.IOException { - Get result = new Get(name); + public Delete delete(java.lang.String name) throws java.io.IOException { + Delete result = new Delete(name); initialize(result); return result; } - public class Get extends ArtifactRegistryRequest { + public class Delete extends ArtifactRegistryRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); /** - * Gets a tag. + * Deletes a version and all of its content. The returned operation will complete once the version + * has been deleted. * - * Create a request for the method "tags.get". + * Create a request for the method "versions.delete". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

- * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} - * must be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + *

{@link + * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

* - * @param name The name of the tag to retrieve. + * @param name The name of the version to delete. * @since 1.13 */ - protected Get(java.lang.String name) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Tag.class); + protected Delete(java.lang.String name) { + super(ArtifactRegistry.this, "DELETE", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Operation.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); } } @Override - public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { - return super.executeUsingHead(); - } - - @Override - public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { - return super.buildHttpRequestUsingHead(); - } - - @Override - public Get set$Xgafv(java.lang.String $Xgafv) { - return (Get) super.set$Xgafv($Xgafv); + public Delete set$Xgafv(java.lang.String $Xgafv) { + return (Delete) super.set$Xgafv($Xgafv); } @Override - public Get setAccessToken(java.lang.String accessToken) { - return (Get) super.setAccessToken(accessToken); + public Delete setAccessToken(java.lang.String accessToken) { + return (Delete) super.setAccessToken(accessToken); } @Override - public Get setAlt(java.lang.String alt) { - return (Get) super.setAlt(alt); + public Delete setAlt(java.lang.String alt) { + return (Delete) super.setAlt(alt); } @Override - public Get setCallback(java.lang.String callback) { - return (Get) super.setCallback(callback); + public Delete setCallback(java.lang.String callback) { + return (Delete) super.setCallback(callback); } @Override - public Get setFields(java.lang.String fields) { - return (Get) super.setFields(fields); + public Delete setFields(java.lang.String fields) { + return (Delete) super.setFields(fields); } @Override - public Get setKey(java.lang.String key) { - return (Get) super.setKey(key); + public Delete setKey(java.lang.String key) { + return (Delete) super.setKey(key); } @Override - public Get setOauthToken(java.lang.String oauthToken) { - return (Get) super.setOauthToken(oauthToken); + public Delete setOauthToken(java.lang.String oauthToken) { + return (Delete) super.setOauthToken(oauthToken); } @Override - public Get setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Get) super.setPrettyPrint(prettyPrint); + public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Delete) super.setPrettyPrint(prettyPrint); } @Override - public Get setQuotaUser(java.lang.String quotaUser) { - return (Get) super.setQuotaUser(quotaUser); + public Delete setQuotaUser(java.lang.String quotaUser) { + return (Delete) super.setQuotaUser(quotaUser); } @Override - public Get setUploadType(java.lang.String uploadType) { - return (Get) super.setUploadType(uploadType); + public Delete setUploadType(java.lang.String uploadType) { + return (Delete) super.setUploadType(uploadType); } @Override - public Get setUploadProtocol(java.lang.String uploadProtocol) { - return (Get) super.setUploadProtocol(uploadProtocol); + public Delete setUploadProtocol(java.lang.String uploadProtocol) { + return (Delete) super.setUploadProtocol(uploadProtocol); } - /** The name of the tag to retrieve. */ + /** The name of the version to delete. */ @com.google.api.client.util.Key private java.lang.String name; - /** The name of the tag to retrieve. + /** The name of the version to delete. */ public java.lang.String getName() { return name; } - /** The name of the tag to retrieve. */ - public Get setName(java.lang.String name) { + /** The name of the version to delete. */ + public Delete setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); } this.name = name; return this; } + /** + * By default, a version that is tagged may not be deleted. If force=true, the version + * and any tags pointing to the version are deleted. + */ + @com.google.api.client.util.Key + private java.lang.Boolean force; + + /** By default, a version that is tagged may not be deleted. If force=true, the version and any tags + pointing to the version are deleted. + */ + public java.lang.Boolean getForce() { + return force; + } + + /** + * By default, a version that is tagged may not be deleted. If force=true, the version + * and any tags pointing to the version are deleted. + */ + public Delete setForce(java.lang.Boolean force) { + this.force = force; + return this; + } + @Override - public Get set(String parameterName, Object value) { - return (Get) super.set(parameterName, value); + public Delete set(String parameterName, Object value) { + return (Delete) super.set(parameterName, value); } } /** - * Lists tags. + * Gets a version * - * Create a request for the method "tags.list". + * Create a request for the method "versions.get". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link List#execute()} method to invoke the remote operation. + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. * - * @param parent The name of the parent package whose tags will be listed. For example: `projects/p1/locations/us- - * central1/repositories/repo1/packages/pkg1`. + * @param name The name of the version to retrieve. * @return the request */ - public List list(java.lang.String parent) throws java.io.IOException { - List result = new List(parent); + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); initialize(result); return result; } - public class List extends ArtifactRegistryRequest { + public class Get extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+parent}/tags"; + private static final String REST_PATH = "v1/{+name}"; - private final java.util.regex.Pattern PARENT_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); /** - * Lists tags. + * Gets a version * - * Create a request for the method "tags.list". + * Create a request for the method "versions.get". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

- * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor.

* - * @param parent The name of the parent package whose tags will be listed. For example: `projects/p1/locations/us- - * central1/repositories/repo1/packages/pkg1`. + * @param name The name of the version to retrieve. * @since 1.13 */ - protected List(java.lang.String parent) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListTagsResponse.class); - this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + protected Get(java.lang.String name) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Version.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); } } @@ -6900,1144 +8614,1198 @@ public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws } @Override - public List set$Xgafv(java.lang.String $Xgafv) { - return (List) super.set$Xgafv($Xgafv); + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); } @Override - public List setAccessToken(java.lang.String accessToken) { - return (List) super.setAccessToken(accessToken); + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); } @Override - public List setAlt(java.lang.String alt) { - return (List) super.setAlt(alt); + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); } @Override - public List setCallback(java.lang.String callback) { - return (List) super.setCallback(callback); + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); } @Override - public List setFields(java.lang.String fields) { - return (List) super.setFields(fields); + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); } @Override - public List setKey(java.lang.String key) { - return (List) super.setKey(key); + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); } @Override - public List setOauthToken(java.lang.String oauthToken) { - return (List) super.setOauthToken(oauthToken); + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); } @Override - public List setPrettyPrint(java.lang.Boolean prettyPrint) { - return (List) super.setPrettyPrint(prettyPrint); + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); } @Override - public List setQuotaUser(java.lang.String quotaUser) { - return (List) super.setQuotaUser(quotaUser); + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); } @Override - public List setUploadType(java.lang.String uploadType) { - return (List) super.setUploadType(uploadType); + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); } @Override - public List setUploadProtocol(java.lang.String uploadProtocol) { - return (List) super.setUploadProtocol(uploadProtocol); + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); } - /** - * The name of the parent package whose tags will be listed. For example: - * `projects/p1/locations/us-central1/repositories/repo1/packages/pkg1`. - */ + /** The name of the version to retrieve. */ @com.google.api.client.util.Key - private java.lang.String parent; + private java.lang.String name; - /** The name of the parent package whose tags will be listed. For example: `projects/p1/locations/us- - central1/repositories/repo1/packages/pkg1`. + /** The name of the version to retrieve. */ - public java.lang.String getParent() { - return parent; + public java.lang.String getName() { + return name; } - /** - * The name of the parent package whose tags will be listed. For example: - * `projects/p1/locations/us-central1/repositories/repo1/packages/pkg1`. - */ - public List setParent(java.lang.String parent) { + /** The name of the version to retrieve. */ + public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); } - this.parent = parent; - return this; - } - - /** - * An expression for filtering the results of the request. Filter rules are case - * insensitive. The fields eligible for filtering are: * `name` * `version` Examples - * of using a filter: To filter the results of your request to tags with the name `my- - * tag` in package `my-package` in repository `my-repo` in project "`y-project` in the - * us-central region, append the following filter expression to your request: * - * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - * package/tags/my-tag"` You can also use wildcards to match any number of characters - * before or after the value: * `name="projects/my-project/locations/us- - * central1/repositories/my-repo/packages/my-package/tags/my*"` * `name="projects/my- - * project/locations/us-central1/repositories/my-repo/packages/my-package/tagstag"` * - * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - * package/tagstag*"` To filter the results of your request to tags applied to the - * version `1.0` in package `my-package`, append the following filter expression to - * your request: * `version="projects/my-project/locations/us- - * central1/repositories/my-repo/packages/my-package/versions/1.0"` - */ - @com.google.api.client.util.Key - private java.lang.String filter; - - /** An expression for filtering the results of the request. Filter rules are case insensitive. The - fields eligible for filtering are: * `name` * `version` Examples of using a filter: To filter the - results of your request to tags with the name `my-tag` in package `my-package` in repository `my- - repo` in project "`y-project` in the us-central region, append the following filter expression to - your request: * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - package/tags/my-tag"` You can also use wildcards to match any number of characters before or after - the value: * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - package/tags/my*"` * `name="projects/my-project/locations/us-central1/repositories/my- - repo/packages/my-package/tagstag"` * `name="projects/my-project/locations/us- - central1/repositories/my-repo/packages/my-package/tagstag*"` To filter the results of your request - to tags applied to the version `1.0` in package `my-package`, append the following filter - expression to your request: * `version="projects/my-project/locations/us-central1/repositories/my- - repo/packages/my-package/versions/1.0"` - */ - public java.lang.String getFilter() { - return filter; - } - - /** - * An expression for filtering the results of the request. Filter rules are case - * insensitive. The fields eligible for filtering are: * `name` * `version` Examples - * of using a filter: To filter the results of your request to tags with the name `my- - * tag` in package `my-package` in repository `my-repo` in project "`y-project` in the - * us-central region, append the following filter expression to your request: * - * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - * package/tags/my-tag"` You can also use wildcards to match any number of characters - * before or after the value: * `name="projects/my-project/locations/us- - * central1/repositories/my-repo/packages/my-package/tags/my*"` * `name="projects/my- - * project/locations/us-central1/repositories/my-repo/packages/my-package/tagstag"` * - * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - * package/tagstag*"` To filter the results of your request to tags applied to the - * version `1.0` in package `my-package`, append the following filter expression to - * your request: * `version="projects/my-project/locations/us- - * central1/repositories/my-repo/packages/my-package/versions/1.0"` - */ - public List setFilter(java.lang.String filter) { - this.filter = filter; - return this; - } - - /** The maximum number of tags to return. Maximum page size is 1,000. */ - @com.google.api.client.util.Key - private java.lang.Integer pageSize; - - /** The maximum number of tags to return. Maximum page size is 1,000. - */ - public java.lang.Integer getPageSize() { - return pageSize; - } - - /** The maximum number of tags to return. Maximum page size is 1,000. */ - public List setPageSize(java.lang.Integer pageSize) { - this.pageSize = pageSize; + this.name = name; return this; } - /** The next_page_token value returned from a previous list request, if any. */ + /** The view that should be returned in the response. */ @com.google.api.client.util.Key - private java.lang.String pageToken; + private java.lang.String view; - /** The next_page_token value returned from a previous list request, if any. + /** The view that should be returned in the response. */ - public java.lang.String getPageToken() { - return pageToken; + public java.lang.String getView() { + return view; } - /** The next_page_token value returned from a previous list request, if any. */ - public List setPageToken(java.lang.String pageToken) { - this.pageToken = pageToken; + /** The view that should be returned in the response. */ + public Get setView(java.lang.String view) { + this.view = view; return this; } @Override - public List set(String parameterName, Object value) { - return (List) super.set(parameterName, value); + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); } } /** - * Updates a tag. + * Lists versions. * - * Create a request for the method "tags.patch". + * Create a request for the method "versions.list". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. + * optional parameters, call the {@link List#execute()} method to invoke the remote operation. * - * @param name The name of the tag, for example: "projects/p1/locations/us- - * central1/repositories/repo1/packages/pkg1/tags/tag1". If the package part contains - * slashes, the slashes are escaped. The tag part can only have characters in - * [a-zA-Z0-9\-._~:@], anything else must be URL encoded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.Tag} + * @param parent The name of the parent resource whose versions will be listed. * @return the request */ - public Patch patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.Tag content) throws java.io.IOException { - Patch result = new Patch(name, content); + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); initialize(result); return result; } - public class Patch extends ArtifactRegistryRequest { + public class List extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+name}"; + private static final String REST_PATH = "v1/{+parent}/versions"; - private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); /** - * Updates a tag. + * Lists versions. * - * Create a request for the method "tags.patch". + * Create a request for the method "versions.list". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. - *

{@link - * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must - * be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

* - * @param name The name of the tag, for example: "projects/p1/locations/us- - * central1/repositories/repo1/packages/pkg1/tags/tag1". If the package part contains - * slashes, the slashes are escaped. The tag part can only have characters in - * [a-zA-Z0-9\-._~:@], anything else must be URL encoded. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.Tag} + * @param parent The name of the parent resource whose versions will be listed. * @since 1.13 */ - protected Patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.Tag content) { - super(ArtifactRegistry.this, "PATCH", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.Tag.class); - this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + protected List(java.lang.String parent) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListVersionsResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); } } @Override - public Patch set$Xgafv(java.lang.String $Xgafv) { - return (Patch) super.set$Xgafv($Xgafv); + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } + + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } + + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } + + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); } @Override - public Patch setAccessToken(java.lang.String accessToken) { - return (Patch) super.setAccessToken(accessToken); + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); } @Override - public Patch setAlt(java.lang.String alt) { - return (Patch) super.setAlt(alt); + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); } @Override - public Patch setCallback(java.lang.String callback) { - return (Patch) super.setCallback(callback); + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); } @Override - public Patch setFields(java.lang.String fields) { - return (Patch) super.setFields(fields); + public List setKey(java.lang.String key) { + return (List) super.setKey(key); } @Override - public Patch setKey(java.lang.String key) { - return (Patch) super.setKey(key); + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); } @Override - public Patch setOauthToken(java.lang.String oauthToken) { - return (Patch) super.setOauthToken(oauthToken); + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); } @Override - public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Patch) super.setPrettyPrint(prettyPrint); + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); } @Override - public Patch setQuotaUser(java.lang.String quotaUser) { - return (Patch) super.setQuotaUser(quotaUser); + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); } @Override - public Patch setUploadType(java.lang.String uploadType) { - return (Patch) super.setUploadType(uploadType); + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); } - @Override - public Patch setUploadProtocol(java.lang.String uploadProtocol) { - return (Patch) super.setUploadProtocol(uploadProtocol); + /** The name of the parent resource whose versions will be listed. */ + @com.google.api.client.util.Key + private java.lang.String parent; + + /** The name of the parent resource whose versions will be listed. + */ + public java.lang.String getParent() { + return parent; + } + + /** The name of the parent resource whose versions will be listed. */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + } + this.parent = parent; + return this; } /** - * The name of the tag, for example: "projects/p1/locations/us- - * central1/repositories/repo1/packages/pkg1/tags/tag1". If the package part contains - * slashes, the slashes are escaped. The tag part can only have characters in - * [a-zA-Z0-9\-._~:@], anything else must be URL encoded. + * Optional. An expression for filtering the results of the request. Filter rules are + * case insensitive. The fields eligible for filtering are: * `name` * `annotations` + * Examples of using a filter: To filter the results of your request to versions with + * the name `my-version` in project `my-project` in the `us-central` region, in + * repository `my-repo`, append the following filter expression to your request: * + * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + * package/versions/my-version"` You can also use wildcards to match any number of + * characters before or after the value: * `name="projects/my-project/locations/us- + * central1/repositories/my-repo/packages/my-package/versionsversion"` * + * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + * package/versions/my*"` * `name="projects/my-project/locations/us- + * central1/repositories/my-repo/packages/my-package/versionsversion*"` To filter the + * results of your request to versions with the annotation key-value pair + * [`external_link`: `external_link_value`], append the following filter expression to + * your request: * `"annotations.external_link:external_link_value"` To filter just + * for a specific annotation key `external_link`, append the following filter + * expression to your request: * `"annotations.external_link"` If the annotation key + * or value contains special characters, you can escape them by surrounding the value + * with backticks. For example, to filter the results of your request to versions with + * the annotation key-value pair [`external.link`:`https://example.com/my-version`], + * append the following filter expression to your request: * `` + * "annotations.`external.link`:`https://example.com/my-version`" `` You can also + * filter with annotations with a wildcard to match any number of characters before or + * after the value: * `` "annotations.*_link:`*example.com*`" `` */ @com.google.api.client.util.Key - private java.lang.String name; + private java.lang.String filter; - /** The name of the tag, for example: "projects/p1/locations/us- - central1/repositories/repo1/packages/pkg1/tags/tag1". If the package part contains slashes, the - slashes are escaped. The tag part can only have characters in [a-zA-Z0-9\-._~:@], anything else - must be URL encoded. + /** Optional. An expression for filtering the results of the request. Filter rules are case + insensitive. The fields eligible for filtering are: * `name` * `annotations` Examples of using a + filter: To filter the results of your request to versions with the name `my-version` in project + `my-project` in the `us-central` region, in repository `my-repo`, append the following filter + expression to your request: * `name="projects/my-project/locations/us-central1/repositories/my- + repo/packages/my-package/versions/my-version"` You can also use wildcards to match any number of + characters before or after the value: * `name="projects/my-project/locations/us- + central1/repositories/my-repo/packages/my-package/versionsversion"` * `name="projects/my- + project/locations/us-central1/repositories/my-repo/packages/my-package/versions/my*"` * + `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + package/versionsversion*"` To filter the results of your request to versions with the annotation + key-value pair [`external_link`: `external_link_value`], append the following filter expression to + your request: * `"annotations.external_link:external_link_value"` To filter just for a specific + annotation key `external_link`, append the following filter expression to your request: * + `"annotations.external_link"` If the annotation key or value contains special characters, you can + escape them by surrounding the value with backticks. For example, to filter the results of your + request to versions with the annotation key-value pair [`external.link`:`https://example.com/my- + version`], append the following filter expression to your request: * `` + "annotations.`external.link`:`https://example.com/my-version`" `` You can also filter with + annotations with a wildcard to match any number of characters before or after the value: * `` + "annotations.*_link:`*example.com*`" `` */ - public java.lang.String getName() { - return name; + public java.lang.String getFilter() { + return filter; } /** - * The name of the tag, for example: "projects/p1/locations/us- - * central1/repositories/repo1/packages/pkg1/tags/tag1". If the package part contains - * slashes, the slashes are escaped. The tag part can only have characters in - * [a-zA-Z0-9\-._~:@], anything else must be URL encoded. + * Optional. An expression for filtering the results of the request. Filter rules are + * case insensitive. The fields eligible for filtering are: * `name` * `annotations` + * Examples of using a filter: To filter the results of your request to versions with + * the name `my-version` in project `my-project` in the `us-central` region, in + * repository `my-repo`, append the following filter expression to your request: * + * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + * package/versions/my-version"` You can also use wildcards to match any number of + * characters before or after the value: * `name="projects/my-project/locations/us- + * central1/repositories/my-repo/packages/my-package/versionsversion"` * + * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- + * package/versions/my*"` * `name="projects/my-project/locations/us- + * central1/repositories/my-repo/packages/my-package/versionsversion*"` To filter the + * results of your request to versions with the annotation key-value pair + * [`external_link`: `external_link_value`], append the following filter expression to + * your request: * `"annotations.external_link:external_link_value"` To filter just + * for a specific annotation key `external_link`, append the following filter + * expression to your request: * `"annotations.external_link"` If the annotation key + * or value contains special characters, you can escape them by surrounding the value + * with backticks. For example, to filter the results of your request to versions with + * the annotation key-value pair [`external.link`:`https://example.com/my-version`], + * append the following filter expression to your request: * `` + * "annotations.`external.link`:`https://example.com/my-version`" `` You can also + * filter with annotations with a wildcard to match any number of characters before or + * after the value: * `` "annotations.*_link:`*example.com*`" `` */ - public Patch setName(java.lang.String name) { - if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/tags/[^/]+$"); - } - this.name = name; + public List setFilter(java.lang.String filter) { + this.filter = filter; return this; } - /** - * The update mask applies to the resource. For the `FieldMask` definition, see - * https://developers.google.com/protocol- - * buffers/docs/reference/google.protobuf#fieldmask - */ + /** Optional. The field to order the results by. */ @com.google.api.client.util.Key - private String updateMask; + private java.lang.String orderBy; - /** The update mask applies to the resource. For the `FieldMask` definition, see - https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + /** Optional. The field to order the results by. */ - public String getUpdateMask() { - return updateMask; + public java.lang.String getOrderBy() { + return orderBy; } - /** - * The update mask applies to the resource. For the `FieldMask` definition, see - * https://developers.google.com/protocol- - * buffers/docs/reference/google.protobuf#fieldmask + /** Optional. The field to order the results by. */ + public List setOrderBy(java.lang.String orderBy) { + this.orderBy = orderBy; + return this; + } + + /** The maximum number of versions to return. Maximum page size is 1,000. */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; + + /** The maximum number of versions to return. Maximum page size is 1,000. */ - public Patch setUpdateMask(String updateMask) { - this.updateMask = updateMask; + public java.lang.Integer getPageSize() { + return pageSize; + } + + /** The maximum number of versions to return. Maximum page size is 1,000. */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; return this; } - @Override - public Patch set(String parameterName, Object value) { - return (Patch) super.set(parameterName, value); + /** The next_page_token value returned from a previous list request, if any. */ + @com.google.api.client.util.Key + private java.lang.String pageToken; + + /** The next_page_token value returned from a previous list request, if any. + */ + public java.lang.String getPageToken() { + return pageToken; } - } - } - /** - * An accessor for creating requests from the Versions collection. - * - *

The typical use is:

- *
-           *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
-           *   {@code ArtifactRegistry.Versions.List request = artifactregistry.versions().list(parameters ...)}
-           * 
- * - * @return the resource collection - */ - public Versions versions() { - return new Versions(); - } + /** The next_page_token value returned from a previous list request, if any. */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } - /** - * The "versions" collection of methods. - */ - public class Versions { + /** The view that should be returned in the response. */ + @com.google.api.client.util.Key + private java.lang.String view; - /** - * Deletes multiple versions across a repository. The returned operation will complete once the - * versions have been deleted. + /** The view that should be returned in the response. + */ + public java.lang.String getView() { + return view; + } + + /** The view that should be returned in the response. */ + public List setView(java.lang.String view) { + this.view = view; + return this; + } + + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } + /** + * Updates a version. * - * Create a request for the method "versions.batchDelete". + * Create a request for the method "versions.patch". * * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link BatchDelete#execute()} method to invoke the remote - * operation. + * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. * - * @param parent The name of the repository holding all requested versions. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.BatchDeleteVersionsRequest} + * @param name The name of the version, for example: "projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1/versions/art1". If the package or version ID + * parts contain slashes, the slashes are escaped. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.Version} * @return the request */ - public BatchDelete batchDelete(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.BatchDeleteVersionsRequest content) throws java.io.IOException { - BatchDelete result = new BatchDelete(parent, content); + public Patch patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.Version content) throws java.io.IOException { + Patch result = new Patch(name, content); initialize(result); return result; } - public class BatchDelete extends ArtifactRegistryRequest { + public class Patch extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+parent}/versions:batchDelete"; + private static final String REST_PATH = "v1/{+name}"; - private final java.util.regex.Pattern PARENT_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); /** - * Deletes multiple versions across a repository. The returned operation will complete once the - * versions have been deleted. + * Updates a version. * - * Create a request for the method "versions.batchDelete". + * Create a request for the method "versions.patch". * * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link BatchDelete#execute()} method to invoke the remote - * operation.

{@link - * BatchDelete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} - * must be called to initialize this instance immediately after invoking the constructor.

+ * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. + *

{@link + * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

* - * @param parent The name of the repository holding all requested versions. - * @param content the {@link com.google.api.services.artifactregistry.v1.model.BatchDeleteVersionsRequest} + * @param name The name of the version, for example: "projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1/versions/art1". If the package or version ID + * parts contain slashes, the slashes are escaped. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.Version} * @since 1.13 */ - protected BatchDelete(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.BatchDeleteVersionsRequest content) { - super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.Operation.class); - this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + protected Patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.Version content) { + super(ArtifactRegistry.this, "PATCH", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.Version.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); } } @Override - public BatchDelete set$Xgafv(java.lang.String $Xgafv) { - return (BatchDelete) super.set$Xgafv($Xgafv); + public Patch set$Xgafv(java.lang.String $Xgafv) { + return (Patch) super.set$Xgafv($Xgafv); } @Override - public BatchDelete setAccessToken(java.lang.String accessToken) { - return (BatchDelete) super.setAccessToken(accessToken); + public Patch setAccessToken(java.lang.String accessToken) { + return (Patch) super.setAccessToken(accessToken); } @Override - public BatchDelete setAlt(java.lang.String alt) { - return (BatchDelete) super.setAlt(alt); + public Patch setAlt(java.lang.String alt) { + return (Patch) super.setAlt(alt); } @Override - public BatchDelete setCallback(java.lang.String callback) { - return (BatchDelete) super.setCallback(callback); + public Patch setCallback(java.lang.String callback) { + return (Patch) super.setCallback(callback); } @Override - public BatchDelete setFields(java.lang.String fields) { - return (BatchDelete) super.setFields(fields); + public Patch setFields(java.lang.String fields) { + return (Patch) super.setFields(fields); } @Override - public BatchDelete setKey(java.lang.String key) { - return (BatchDelete) super.setKey(key); + public Patch setKey(java.lang.String key) { + return (Patch) super.setKey(key); } @Override - public BatchDelete setOauthToken(java.lang.String oauthToken) { - return (BatchDelete) super.setOauthToken(oauthToken); + public Patch setOauthToken(java.lang.String oauthToken) { + return (Patch) super.setOauthToken(oauthToken); } @Override - public BatchDelete setPrettyPrint(java.lang.Boolean prettyPrint) { - return (BatchDelete) super.setPrettyPrint(prettyPrint); + public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Patch) super.setPrettyPrint(prettyPrint); } @Override - public BatchDelete setQuotaUser(java.lang.String quotaUser) { - return (BatchDelete) super.setQuotaUser(quotaUser); + public Patch setQuotaUser(java.lang.String quotaUser) { + return (Patch) super.setQuotaUser(quotaUser); } @Override - public BatchDelete setUploadType(java.lang.String uploadType) { - return (BatchDelete) super.setUploadType(uploadType); + public Patch setUploadType(java.lang.String uploadType) { + return (Patch) super.setUploadType(uploadType); } @Override - public BatchDelete setUploadProtocol(java.lang.String uploadProtocol) { - return (BatchDelete) super.setUploadProtocol(uploadProtocol); + public Patch setUploadProtocol(java.lang.String uploadProtocol) { + return (Patch) super.setUploadProtocol(uploadProtocol); } - /** The name of the repository holding all requested versions. */ + /** + * The name of the version, for example: "projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1/versions/art1". If the package or version + * ID parts contain slashes, the slashes are escaped. + */ @com.google.api.client.util.Key - private java.lang.String parent; + private java.lang.String name; - /** The name of the repository holding all requested versions. + /** The name of the version, for example: "projects/p1/locations/us- + central1/repositories/repo1/packages/pkg1/versions/art1". If the package or version ID parts + contain slashes, the slashes are escaped. */ - public java.lang.String getParent() { - return parent; + public java.lang.String getName() { + return name; } - /** The name of the repository holding all requested versions. */ - public BatchDelete setParent(java.lang.String parent) { + /** + * The name of the version, for example: "projects/p1/locations/us- + * central1/repositories/repo1/packages/pkg1/versions/art1". If the package or version + * ID parts contain slashes, the slashes are escaped. + */ + public Patch setName(java.lang.String name) { if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); } - this.parent = parent; + this.name = name; + return this; + } + + /** + * The update mask applies to the resource. For the `FieldMask` definition, see + * https://developers.google.com/protocol- + * buffers/docs/reference/google.protobuf#fieldmask + */ + @com.google.api.client.util.Key + private String updateMask; + + /** The update mask applies to the resource. For the `FieldMask` definition, see + https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + */ + public String getUpdateMask() { + return updateMask; + } + + /** + * The update mask applies to the resource. For the `FieldMask` definition, see + * https://developers.google.com/protocol- + * buffers/docs/reference/google.protobuf#fieldmask + */ + public Patch setUpdateMask(String updateMask) { + this.updateMask = updateMask; return this; } @Override - public BatchDelete set(String parameterName, Object value) { - return (BatchDelete) super.set(parameterName, value); + public Patch set(String parameterName, Object value) { + return (Patch) super.set(parameterName, value); } } + + } + } + /** + * An accessor for creating requests from the PythonPackages collection. + * + *

The typical use is:

+ *
+         *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
+         *   {@code ArtifactRegistry.PythonPackages.List request = artifactregistry.pythonPackages().list(parameters ...)}
+         * 
+ * + * @return the resource collection + */ + public PythonPackages pythonPackages() { + return new PythonPackages(); + } + + /** + * The "pythonPackages" collection of methods. + */ + public class PythonPackages { + + /** + * Gets a python package. + * + * Create a request for the method "pythonPackages.get". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. + * + * @param name Required. The name of the python package. + * @return the request + */ + public Get get(java.lang.String name) throws java.io.IOException { + Get result = new Get(name); + initialize(result); + return result; + } + + public class Get extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/pythonPackages/[^/]+$"); + /** - * Deletes a version and all of its content. The returned operation will complete once the version - * has been deleted. + * Gets a python package. * - * Create a request for the method "versions.delete". + * Create a request for the method "pythonPackages.get". * - * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

+ * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

* - * @param name The name of the version to delete. - * @return the request + * @param name Required. The name of the python package. + * @since 1.13 */ - public Delete delete(java.lang.String name) throws java.io.IOException { - Delete result = new Delete(name); - initialize(result); - return result; + protected Get(java.lang.String name) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.PythonPackage.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/pythonPackages/[^/]+$"); + } } - public class Delete extends ArtifactRegistryRequest { - - private static final String REST_PATH = "v1/{+name}"; - - private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } - /** - * Deletes a version and all of its content. The returned operation will complete once the version - * has been deleted. - * - * Create a request for the method "versions.delete". - * - * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. - *

{@link - * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must - * be called to initialize this instance immediately after invoking the constructor.

- * - * @param name The name of the version to delete. - * @since 1.13 - */ - protected Delete(java.lang.String name) { - super(ArtifactRegistry.this, "DELETE", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Operation.class); - this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); - if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); - } - } + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } - @Override - public Delete set$Xgafv(java.lang.String $Xgafv) { - return (Delete) super.set$Xgafv($Xgafv); - } + @Override + public Get set$Xgafv(java.lang.String $Xgafv) { + return (Get) super.set$Xgafv($Xgafv); + } - @Override - public Delete setAccessToken(java.lang.String accessToken) { - return (Delete) super.setAccessToken(accessToken); - } + @Override + public Get setAccessToken(java.lang.String accessToken) { + return (Get) super.setAccessToken(accessToken); + } - @Override - public Delete setAlt(java.lang.String alt) { - return (Delete) super.setAlt(alt); - } + @Override + public Get setAlt(java.lang.String alt) { + return (Get) super.setAlt(alt); + } - @Override - public Delete setCallback(java.lang.String callback) { - return (Delete) super.setCallback(callback); - } + @Override + public Get setCallback(java.lang.String callback) { + return (Get) super.setCallback(callback); + } - @Override - public Delete setFields(java.lang.String fields) { - return (Delete) super.setFields(fields); - } + @Override + public Get setFields(java.lang.String fields) { + return (Get) super.setFields(fields); + } - @Override - public Delete setKey(java.lang.String key) { - return (Delete) super.setKey(key); - } + @Override + public Get setKey(java.lang.String key) { + return (Get) super.setKey(key); + } - @Override - public Delete setOauthToken(java.lang.String oauthToken) { - return (Delete) super.setOauthToken(oauthToken); - } + @Override + public Get setOauthToken(java.lang.String oauthToken) { + return (Get) super.setOauthToken(oauthToken); + } - @Override - public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Delete) super.setPrettyPrint(prettyPrint); - } + @Override + public Get setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Get) super.setPrettyPrint(prettyPrint); + } - @Override - public Delete setQuotaUser(java.lang.String quotaUser) { - return (Delete) super.setQuotaUser(quotaUser); - } + @Override + public Get setQuotaUser(java.lang.String quotaUser) { + return (Get) super.setQuotaUser(quotaUser); + } - @Override - public Delete setUploadType(java.lang.String uploadType) { - return (Delete) super.setUploadType(uploadType); - } + @Override + public Get setUploadType(java.lang.String uploadType) { + return (Get) super.setUploadType(uploadType); + } - @Override - public Delete setUploadProtocol(java.lang.String uploadProtocol) { - return (Delete) super.setUploadProtocol(uploadProtocol); - } + @Override + public Get setUploadProtocol(java.lang.String uploadProtocol) { + return (Get) super.setUploadProtocol(uploadProtocol); + } - /** The name of the version to delete. */ - @com.google.api.client.util.Key - private java.lang.String name; + /** Required. The name of the python package. */ + @com.google.api.client.util.Key + private java.lang.String name; - /** The name of the version to delete. - */ - public java.lang.String getName() { - return name; - } + /** Required. The name of the python package. + */ + public java.lang.String getName() { + return name; + } - /** The name of the version to delete. */ - public Delete setName(java.lang.String name) { - if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); - } - this.name = name; - return this; + /** Required. The name of the python package. */ + public Get setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/pythonPackages/[^/]+$"); } + this.name = name; + return this; + } - /** - * By default, a version that is tagged may not be deleted. If force=true, the version - * and any tags pointing to the version are deleted. - */ - @com.google.api.client.util.Key - private java.lang.Boolean force; + @Override + public Get set(String parameterName, Object value) { + return (Get) super.set(parameterName, value); + } + } + /** + * Lists python packages. + * + * Create a request for the method "pythonPackages.list". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation. + * + * @param parent Required. The name of the parent resource whose python packages will be listed. + * @return the request + */ + public List list(java.lang.String parent) throws java.io.IOException { + List result = new List(parent); + initialize(result); + return result; + } - /** By default, a version that is tagged may not be deleted. If force=true, the version and any tags - pointing to the version are deleted. - */ - public java.lang.Boolean getForce() { - return force; - } + public class List extends ArtifactRegistryRequest { - /** - * By default, a version that is tagged may not be deleted. If force=true, the version - * and any tags pointing to the version are deleted. - */ - public Delete setForce(java.lang.Boolean force) { - this.force = force; - return this; - } + private static final String REST_PATH = "v1/{+parent}/pythonPackages"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); - @Override - public Delete set(String parameterName, Object value) { - return (Delete) super.set(parameterName, value); - } - } /** - * Gets a version + * Lists python packages. * - * Create a request for the method "versions.get". + * Create a request for the method "pythonPackages.list". * - * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

+ * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} + * must be called to initialize this instance immediately after invoking the constructor.

* - * @param name The name of the version to retrieve. - * @return the request + * @param parent Required. The name of the parent resource whose python packages will be listed. + * @since 1.13 */ - public Get get(java.lang.String name) throws java.io.IOException { - Get result = new Get(name); - initialize(result); - return result; + protected List(java.lang.String parent) { + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListPythonPackagesResponse.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + } } - public class Get extends ArtifactRegistryRequest { + @Override + public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { + return super.executeUsingHead(); + } - private static final String REST_PATH = "v1/{+name}"; + @Override + public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { + return super.buildHttpRequestUsingHead(); + } - private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); + @Override + public List set$Xgafv(java.lang.String $Xgafv) { + return (List) super.set$Xgafv($Xgafv); + } - /** - * Gets a version - * - * Create a request for the method "versions.get". - * - * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

- * {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} - * must be called to initialize this instance immediately after invoking the constructor.

- * - * @param name The name of the version to retrieve. - * @since 1.13 - */ - protected Get(java.lang.String name) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Version.class); - this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); - if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); - } - } + @Override + public List setAccessToken(java.lang.String accessToken) { + return (List) super.setAccessToken(accessToken); + } + + @Override + public List setAlt(java.lang.String alt) { + return (List) super.setAlt(alt); + } + + @Override + public List setCallback(java.lang.String callback) { + return (List) super.setCallback(callback); + } + + @Override + public List setFields(java.lang.String fields) { + return (List) super.setFields(fields); + } + + @Override + public List setKey(java.lang.String key) { + return (List) super.setKey(key); + } + + @Override + public List setOauthToken(java.lang.String oauthToken) { + return (List) super.setOauthToken(oauthToken); + } - @Override - public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { - return super.executeUsingHead(); - } + @Override + public List setPrettyPrint(java.lang.Boolean prettyPrint) { + return (List) super.setPrettyPrint(prettyPrint); + } - @Override - public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { - return super.buildHttpRequestUsingHead(); - } + @Override + public List setQuotaUser(java.lang.String quotaUser) { + return (List) super.setQuotaUser(quotaUser); + } - @Override - public Get set$Xgafv(java.lang.String $Xgafv) { - return (Get) super.set$Xgafv($Xgafv); - } + @Override + public List setUploadType(java.lang.String uploadType) { + return (List) super.setUploadType(uploadType); + } - @Override - public Get setAccessToken(java.lang.String accessToken) { - return (Get) super.setAccessToken(accessToken); - } + @Override + public List setUploadProtocol(java.lang.String uploadProtocol) { + return (List) super.setUploadProtocol(uploadProtocol); + } - @Override - public Get setAlt(java.lang.String alt) { - return (Get) super.setAlt(alt); - } + /** Required. The name of the parent resource whose python packages will be listed. */ + @com.google.api.client.util.Key + private java.lang.String parent; - @Override - public Get setCallback(java.lang.String callback) { - return (Get) super.setCallback(callback); - } + /** Required. The name of the parent resource whose python packages will be listed. + */ + public java.lang.String getParent() { + return parent; + } - @Override - public Get setFields(java.lang.String fields) { - return (Get) super.setFields(fields); + /** Required. The name of the parent resource whose python packages will be listed. */ + public List setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); } + this.parent = parent; + return this; + } - @Override - public Get setKey(java.lang.String key) { - return (Get) super.setKey(key); - } + /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + @com.google.api.client.util.Key + private java.lang.Integer pageSize; - @Override - public Get setOauthToken(java.lang.String oauthToken) { - return (Get) super.setOauthToken(oauthToken); - } + /** The maximum number of artifacts to return. Maximum page size is 1,000. + */ + public java.lang.Integer getPageSize() { + return pageSize; + } - @Override - public Get setPrettyPrint(java.lang.Boolean prettyPrint) { - return (Get) super.setPrettyPrint(prettyPrint); - } + /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + public List setPageSize(java.lang.Integer pageSize) { + this.pageSize = pageSize; + return this; + } - @Override - public Get setQuotaUser(java.lang.String quotaUser) { - return (Get) super.setQuotaUser(quotaUser); - } + /** The next_page_token value returned from a previous list request, if any. */ + @com.google.api.client.util.Key + private java.lang.String pageToken; - @Override - public Get setUploadType(java.lang.String uploadType) { - return (Get) super.setUploadType(uploadType); - } + /** The next_page_token value returned from a previous list request, if any. + */ + public java.lang.String getPageToken() { + return pageToken; + } - @Override - public Get setUploadProtocol(java.lang.String uploadProtocol) { - return (Get) super.setUploadProtocol(uploadProtocol); - } + /** The next_page_token value returned from a previous list request, if any. */ + public List setPageToken(java.lang.String pageToken) { + this.pageToken = pageToken; + return this; + } - /** The name of the version to retrieve. */ - @com.google.api.client.util.Key - private java.lang.String name; + @Override + public List set(String parameterName, Object value) { + return (List) super.set(parameterName, value); + } + } - /** The name of the version to retrieve. - */ - public java.lang.String getName() { - return name; - } + } + /** + * An accessor for creating requests from the Rules collection. + * + *

The typical use is:

+ *
+         *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
+         *   {@code ArtifactRegistry.Rules.List request = artifactregistry.rules().list(parameters ...)}
+         * 
+ * + * @return the resource collection + */ + public Rules rules() { + return new Rules(); + } - /** The name of the version to retrieve. */ - public Get setName(java.lang.String name) { - if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), - "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+/versions/[^/]+$"); - } - this.name = name; - return this; - } + /** + * The "rules" collection of methods. + */ + public class Rules { - /** The view that should be returned in the response. */ - @com.google.api.client.util.Key - private java.lang.String view; + /** + * Creates a rule. + * + * Create a request for the method "rules.create". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. + * + * @param parent Required. The name of the parent resource where the rule will be created. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1Rule} + * @return the request + */ + public Create create(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1Rule content) throws java.io.IOException { + Create result = new Create(parent, content); + initialize(result); + return result; + } - /** The view that should be returned in the response. - */ - public java.lang.String getView() { - return view; - } + public class Create extends ArtifactRegistryRequest { - /** The view that should be returned in the response. */ - public Get setView(java.lang.String view) { - this.view = view; - return this; - } + private static final String REST_PATH = "v1/{+parent}/rules"; + + private final java.util.regex.Pattern PARENT_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); - @Override - public Get set(String parameterName, Object value) { - return (Get) super.set(parameterName, value); - } - } /** - * Lists versions. + * Creates a rule. * - * Create a request for the method "versions.list". + * Create a request for the method "rules.create". * - * This request holds the parameters needed by the artifactregistry server. After setting any - * optional parameters, call the {@link List#execute()} method to invoke the remote operation. + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Create#execute()} method to invoke the remote operation. + *

{@link + * Create#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

* - * @param parent The name of the parent resource whose versions will be listed. - * @return the request + * @param parent Required. The name of the parent resource where the rule will be created. + * @param content the {@link com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1Rule} + * @since 1.13 */ - public List list(java.lang.String parent) throws java.io.IOException { - List result = new List(parent); - initialize(result); - return result; + protected Create(java.lang.String parent, com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1Rule content) { + super(ArtifactRegistry.this, "POST", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1Rule.class); + this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); + } } - public class List extends ArtifactRegistryRequest { - - private static final String REST_PATH = "v1/{+parent}/versions"; - - private final java.util.regex.Pattern PARENT_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); + @Override + public Create set$Xgafv(java.lang.String $Xgafv) { + return (Create) super.set$Xgafv($Xgafv); + } - /** - * Lists versions. - * - * Create a request for the method "versions.list". - * - * This request holds the parameters needed by the the artifactregistry server. After setting any - * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

- * {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} - * must be called to initialize this instance immediately after invoking the constructor.

- * - * @param parent The name of the parent resource whose versions will be listed. - * @since 1.13 - */ - protected List(java.lang.String parent) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListVersionsResponse.class); - this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); - if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); - } - } + @Override + public Create setAccessToken(java.lang.String accessToken) { + return (Create) super.setAccessToken(accessToken); + } - @Override - public com.google.api.client.http.HttpResponse executeUsingHead() throws java.io.IOException { - return super.executeUsingHead(); - } + @Override + public Create setAlt(java.lang.String alt) { + return (Create) super.setAlt(alt); + } - @Override - public com.google.api.client.http.HttpRequest buildHttpRequestUsingHead() throws java.io.IOException { - return super.buildHttpRequestUsingHead(); - } + @Override + public Create setCallback(java.lang.String callback) { + return (Create) super.setCallback(callback); + } - @Override - public List set$Xgafv(java.lang.String $Xgafv) { - return (List) super.set$Xgafv($Xgafv); - } + @Override + public Create setFields(java.lang.String fields) { + return (Create) super.setFields(fields); + } - @Override - public List setAccessToken(java.lang.String accessToken) { - return (List) super.setAccessToken(accessToken); - } + @Override + public Create setKey(java.lang.String key) { + return (Create) super.setKey(key); + } - @Override - public List setAlt(java.lang.String alt) { - return (List) super.setAlt(alt); - } + @Override + public Create setOauthToken(java.lang.String oauthToken) { + return (Create) super.setOauthToken(oauthToken); + } - @Override - public List setCallback(java.lang.String callback) { - return (List) super.setCallback(callback); - } + @Override + public Create setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Create) super.setPrettyPrint(prettyPrint); + } - @Override - public List setFields(java.lang.String fields) { - return (List) super.setFields(fields); - } + @Override + public Create setQuotaUser(java.lang.String quotaUser) { + return (Create) super.setQuotaUser(quotaUser); + } - @Override - public List setKey(java.lang.String key) { - return (List) super.setKey(key); - } + @Override + public Create setUploadType(java.lang.String uploadType) { + return (Create) super.setUploadType(uploadType); + } - @Override - public List setOauthToken(java.lang.String oauthToken) { - return (List) super.setOauthToken(oauthToken); - } + @Override + public Create setUploadProtocol(java.lang.String uploadProtocol) { + return (Create) super.setUploadProtocol(uploadProtocol); + } - @Override - public List setPrettyPrint(java.lang.Boolean prettyPrint) { - return (List) super.setPrettyPrint(prettyPrint); - } + /** Required. The name of the parent resource where the rule will be created. */ + @com.google.api.client.util.Key + private java.lang.String parent; - @Override - public List setQuotaUser(java.lang.String quotaUser) { - return (List) super.setQuotaUser(quotaUser); - } + /** Required. The name of the parent resource where the rule will be created. + */ + public java.lang.String getParent() { + return parent; + } - @Override - public List setUploadType(java.lang.String uploadType) { - return (List) super.setUploadType(uploadType); + /** Required. The name of the parent resource where the rule will be created. */ + public Create setParent(java.lang.String parent) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), + "Parameter parent must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); } + this.parent = parent; + return this; + } - @Override - public List setUploadProtocol(java.lang.String uploadProtocol) { - return (List) super.setUploadProtocol(uploadProtocol); - } + /** The rule id to use for this repository. */ + @com.google.api.client.util.Key + private java.lang.String ruleId; - /** The name of the parent resource whose versions will be listed. */ - @com.google.api.client.util.Key - private java.lang.String parent; + /** The rule id to use for this repository. + */ + public java.lang.String getRuleId() { + return ruleId; + } - /** The name of the parent resource whose versions will be listed. - */ - public java.lang.String getParent() { - return parent; - } + /** The rule id to use for this repository. */ + public Create setRuleId(java.lang.String ruleId) { + this.ruleId = ruleId; + return this; + } - /** The name of the parent resource whose versions will be listed. */ - public List setParent(java.lang.String parent) { - if (!getSuppressPatternChecks()) { - com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), - "Parameter parent must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/packages/[^/]+$"); - } - this.parent = parent; - return this; - } + @Override + public Create set(String parameterName, Object value) { + return (Create) super.set(parameterName, value); + } + } + /** + * Deletes a rule. + * + * Create a request for the method "rules.delete". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + * + * @param name Required. The name of the rule to delete. + * @return the request + */ + public Delete delete(java.lang.String name) throws java.io.IOException { + Delete result = new Delete(name); + initialize(result); + return result; + } - /** - * Optional. An expression for filtering the results of the request. Filter rules are - * case insensitive. The fields eligible for filtering are: * `name` * `annotations` - * Examples of using a filter: To filter the results of your request to versions with - * the name `my-version` in project `my-project` in the `us-central` region, in - * repository `my-repo`, append the following filter expression to your request: * - * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - * package/versions/my-version"` You can also use wildcards to match any number of - * characters before or after the value: * `name="projects/my-project/locations/us- - * central1/repositories/my-repo/packages/my-package/versionsversion"` * - * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - * package/versions/my*"` * `name="projects/my-project/locations/us- - * central1/repositories/my-repo/packages/my-package/versionsversion*"` To filter the - * results of your request to versions with the annotation key-value pair - * [`external_link`: `external_link_value`], append the following filter expression to - * your request: * `"annotations.external_link:external_link_value"` To filter just - * for a specific annotation key `external_link`, append the following filter - * expression to your request: * `"annotations.external_link"` If the annotation key - * or value contains special characters, you can escape them by surrounding the value - * with backticks. For example, to filter the results of your request to versions with - * the annotation key-value pair [`external.link`:`https://example.com/my-version`], - * append the following filter expression to your request: * `` - * "annotations.`external.link`:`https://example.com/my-version`" `` You can also - * filter with annotations with a wildcard to match any number of characters before or - * after the value: * `` "annotations.*_link:`*example.com*`" `` - */ - @com.google.api.client.util.Key - private java.lang.String filter; + public class Delete extends ArtifactRegistryRequest { - /** Optional. An expression for filtering the results of the request. Filter rules are case - insensitive. The fields eligible for filtering are: * `name` * `annotations` Examples of using a - filter: To filter the results of your request to versions with the name `my-version` in project - `my-project` in the `us-central` region, in repository `my-repo`, append the following filter - expression to your request: * `name="projects/my-project/locations/us-central1/repositories/my- - repo/packages/my-package/versions/my-version"` You can also use wildcards to match any number of - characters before or after the value: * `name="projects/my-project/locations/us- - central1/repositories/my-repo/packages/my-package/versionsversion"` * `name="projects/my- - project/locations/us-central1/repositories/my-repo/packages/my-package/versions/my*"` * - `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - package/versionsversion*"` To filter the results of your request to versions with the annotation - key-value pair [`external_link`: `external_link_value`], append the following filter expression to - your request: * `"annotations.external_link:external_link_value"` To filter just for a specific - annotation key `external_link`, append the following filter expression to your request: * - `"annotations.external_link"` If the annotation key or value contains special characters, you can - escape them by surrounding the value with backticks. For example, to filter the results of your - request to versions with the annotation key-value pair [`external.link`:`https://example.com/my- - version`], append the following filter expression to your request: * `` - "annotations.`external.link`:`https://example.com/my-version`" `` You can also filter with - annotations with a wildcard to match any number of characters before or after the value: * `` - "annotations.*_link:`*example.com*`" `` - */ - public java.lang.String getFilter() { - return filter; - } + private static final String REST_PATH = "v1/{+name}"; - /** - * Optional. An expression for filtering the results of the request. Filter rules are - * case insensitive. The fields eligible for filtering are: * `name` * `annotations` - * Examples of using a filter: To filter the results of your request to versions with - * the name `my-version` in project `my-project` in the `us-central` region, in - * repository `my-repo`, append the following filter expression to your request: * - * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - * package/versions/my-version"` You can also use wildcards to match any number of - * characters before or after the value: * `name="projects/my-project/locations/us- - * central1/repositories/my-repo/packages/my-package/versionsversion"` * - * `name="projects/my-project/locations/us-central1/repositories/my-repo/packages/my- - * package/versions/my*"` * `name="projects/my-project/locations/us- - * central1/repositories/my-repo/packages/my-package/versionsversion*"` To filter the - * results of your request to versions with the annotation key-value pair - * [`external_link`: `external_link_value`], append the following filter expression to - * your request: * `"annotations.external_link:external_link_value"` To filter just - * for a specific annotation key `external_link`, append the following filter - * expression to your request: * `"annotations.external_link"` If the annotation key - * or value contains special characters, you can escape them by surrounding the value - * with backticks. For example, to filter the results of your request to versions with - * the annotation key-value pair [`external.link`:`https://example.com/my-version`], - * append the following filter expression to your request: * `` - * "annotations.`external.link`:`https://example.com/my-version`" `` You can also - * filter with annotations with a wildcard to match any number of characters before or - * after the value: * `` "annotations.*_link:`*example.com*`" `` - */ - public List setFilter(java.lang.String filter) { - this.filter = filter; - return this; + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/rules/[^/]+$"); + + /** + * Deletes a rule. + * + * Create a request for the method "rules.delete". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Delete#execute()} method to invoke the remote operation. + *

{@link + * Delete#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name Required. The name of the rule to delete. + * @since 1.13 + */ + protected Delete(java.lang.String name) { + super(ArtifactRegistry.this, "DELETE", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.Empty.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/rules/[^/]+$"); } + } - /** Optional. The field to order the results by. */ - @com.google.api.client.util.Key - private java.lang.String orderBy; + @Override + public Delete set$Xgafv(java.lang.String $Xgafv) { + return (Delete) super.set$Xgafv($Xgafv); + } - /** Optional. The field to order the results by. - */ - public java.lang.String getOrderBy() { - return orderBy; - } + @Override + public Delete setAccessToken(java.lang.String accessToken) { + return (Delete) super.setAccessToken(accessToken); + } - /** Optional. The field to order the results by. */ - public List setOrderBy(java.lang.String orderBy) { - this.orderBy = orderBy; - return this; - } + @Override + public Delete setAlt(java.lang.String alt) { + return (Delete) super.setAlt(alt); + } - /** The maximum number of versions to return. Maximum page size is 1,000. */ - @com.google.api.client.util.Key - private java.lang.Integer pageSize; + @Override + public Delete setCallback(java.lang.String callback) { + return (Delete) super.setCallback(callback); + } - /** The maximum number of versions to return. Maximum page size is 1,000. - */ - public java.lang.Integer getPageSize() { - return pageSize; - } + @Override + public Delete setFields(java.lang.String fields) { + return (Delete) super.setFields(fields); + } - /** The maximum number of versions to return. Maximum page size is 1,000. */ - public List setPageSize(java.lang.Integer pageSize) { - this.pageSize = pageSize; - return this; - } + @Override + public Delete setKey(java.lang.String key) { + return (Delete) super.setKey(key); + } - /** The next_page_token value returned from a previous list request, if any. */ - @com.google.api.client.util.Key - private java.lang.String pageToken; + @Override + public Delete setOauthToken(java.lang.String oauthToken) { + return (Delete) super.setOauthToken(oauthToken); + } - /** The next_page_token value returned from a previous list request, if any. - */ - public java.lang.String getPageToken() { - return pageToken; - } + @Override + public Delete setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Delete) super.setPrettyPrint(prettyPrint); + } - /** The next_page_token value returned from a previous list request, if any. */ - public List setPageToken(java.lang.String pageToken) { - this.pageToken = pageToken; - return this; - } + @Override + public Delete setQuotaUser(java.lang.String quotaUser) { + return (Delete) super.setQuotaUser(quotaUser); + } - /** The view that should be returned in the response. */ - @com.google.api.client.util.Key - private java.lang.String view; + @Override + public Delete setUploadType(java.lang.String uploadType) { + return (Delete) super.setUploadType(uploadType); + } - /** The view that should be returned in the response. - */ - public java.lang.String getView() { - return view; - } + @Override + public Delete setUploadProtocol(java.lang.String uploadProtocol) { + return (Delete) super.setUploadProtocol(uploadProtocol); + } - /** The view that should be returned in the response. */ - public List setView(java.lang.String view) { - this.view = view; - return this; - } + /** Required. The name of the rule to delete. */ + @com.google.api.client.util.Key + private java.lang.String name; - @Override - public List set(String parameterName, Object value) { - return (List) super.set(parameterName, value); + /** Required. The name of the rule to delete. + */ + public java.lang.String getName() { + return name; + } + + /** Required. The name of the rule to delete. */ + public Delete setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/rules/[^/]+$"); } + this.name = name; + return this; } + @Override + public Delete set(String parameterName, Object value) { + return (Delete) super.set(parameterName, value); + } } - } - /** - * An accessor for creating requests from the PythonPackages collection. - * - *

The typical use is:

- *
-         *   {@code ArtifactRegistry artifactregistry = new ArtifactRegistry(...);}
-         *   {@code ArtifactRegistry.PythonPackages.List request = artifactregistry.pythonPackages().list(parameters ...)}
-         * 
- * - * @return the resource collection - */ - public PythonPackages pythonPackages() { - return new PythonPackages(); - } - - /** - * The "pythonPackages" collection of methods. - */ - public class PythonPackages { - /** - * Gets a python package. + * Gets a rule. * - * Create a request for the method "pythonPackages.get". + * Create a request for the method "rules.get". * * This request holds the parameters needed by the artifactregistry server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation. * - * @param name Required. The name of the python package. + * @param name Required. The name of the rule to retrieve. * @return the request */ public Get get(java.lang.String name) throws java.io.IOException { @@ -8046,33 +9814,33 @@ public Get get(java.lang.String name) throws java.io.IOException { return result; } - public class Get extends ArtifactRegistryRequest { + public class Get extends ArtifactRegistryRequest { private static final String REST_PATH = "v1/{+name}"; private final java.util.regex.Pattern NAME_PATTERN = - java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/pythonPackages/[^/]+$"); + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/rules/[^/]+$"); /** - * Gets a python package. + * Gets a rule. * - * Create a request for the method "pythonPackages.get". + * Create a request for the method "rules.get". * * This request holds the parameters needed by the the artifactregistry server. After setting any * optional parameters, call the {@link Get#execute()} method to invoke the remote operation.

* {@link Get#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor.

* - * @param name Required. The name of the python package. + * @param name Required. The name of the rule to retrieve. * @since 1.13 */ protected Get(java.lang.String name) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.PythonPackage.class); + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1Rule.class); this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/pythonPackages/[^/]+$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/rules/[^/]+$"); } } @@ -8141,22 +9909,22 @@ public Get setUploadProtocol(java.lang.String uploadProtocol) { return (Get) super.setUploadProtocol(uploadProtocol); } - /** Required. The name of the python package. */ + /** Required. The name of the rule to retrieve. */ @com.google.api.client.util.Key private java.lang.String name; - /** Required. The name of the python package. + /** Required. The name of the rule to retrieve. */ public java.lang.String getName() { return name; } - /** Required. The name of the python package. */ + /** Required. The name of the rule to retrieve. */ public Get setName(java.lang.String name) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), "Parameter name must conform to the pattern " + - "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/pythonPackages/[^/]+$"); + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/rules/[^/]+$"); } this.name = name; return this; @@ -8168,14 +9936,15 @@ public Get set(String parameterName, Object value) { } } /** - * Lists python packages. + * Lists rules. * - * Create a request for the method "pythonPackages.list". + * Create a request for the method "rules.list". * * This request holds the parameters needed by the artifactregistry server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation. * - * @param parent Required. The name of the parent resource whose python packages will be listed. + * @param parent Required. The name of the parent repository whose rules will be listed. For example: + * `projects/p1/locations/us-central1/repositories/repo1`. * @return the request */ public List list(java.lang.String parent) throws java.io.IOException { @@ -8184,28 +9953,29 @@ public List list(java.lang.String parent) throws java.io.IOException { return result; } - public class List extends ArtifactRegistryRequest { + public class List extends ArtifactRegistryRequest { - private static final String REST_PATH = "v1/{+parent}/pythonPackages"; + private static final String REST_PATH = "v1/{+parent}/rules"; private final java.util.regex.Pattern PARENT_PATTERN = java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+$"); /** - * Lists python packages. + * Lists rules. * - * Create a request for the method "pythonPackages.list". + * Create a request for the method "rules.list". * * This request holds the parameters needed by the the artifactregistry server. After setting any * optional parameters, call the {@link List#execute()} method to invoke the remote operation.

* {@link List#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} * must be called to initialize this instance immediately after invoking the constructor.

* - * @param parent Required. The name of the parent resource whose python packages will be listed. + * @param parent Required. The name of the parent repository whose rules will be listed. For example: + * `projects/p1/locations/us-central1/repositories/repo1`. * @since 1.13 */ protected List(java.lang.String parent) { - super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListPythonPackagesResponse.class); + super(ArtifactRegistry.this, "GET", REST_PATH, null, com.google.api.services.artifactregistry.v1.model.ListRulesResponse.class); this.parent = com.google.api.client.util.Preconditions.checkNotNull(parent, "Required parameter parent must be specified."); if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -8279,17 +10049,24 @@ public List setUploadProtocol(java.lang.String uploadProtocol) { return (List) super.setUploadProtocol(uploadProtocol); } - /** Required. The name of the parent resource whose python packages will be listed. */ + /** + * Required. The name of the parent repository whose rules will be listed. For example: + * `projects/p1/locations/us-central1/repositories/repo1`. + */ @com.google.api.client.util.Key private java.lang.String parent; - /** Required. The name of the parent resource whose python packages will be listed. + /** Required. The name of the parent repository whose rules will be listed. For example: + `projects/p1/locations/us-central1/repositories/repo1`. */ public java.lang.String getParent() { return parent; } - /** Required. The name of the parent resource whose python packages will be listed. */ + /** + * Required. The name of the parent repository whose rules will be listed. For example: + * `projects/p1/locations/us-central1/repositories/repo1`. + */ public List setParent(java.lang.String parent) { if (!getSuppressPatternChecks()) { com.google.api.client.util.Preconditions.checkArgument(PARENT_PATTERN.matcher(parent).matches(), @@ -8300,17 +10077,17 @@ public List setParent(java.lang.String parent) { return this; } - /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + /** The maximum number of rules to return. Maximum page size is 1,000. */ @com.google.api.client.util.Key private java.lang.Integer pageSize; - /** The maximum number of artifacts to return. Maximum page size is 1,000. + /** The maximum number of rules to return. Maximum page size is 1,000. */ public java.lang.Integer getPageSize() { return pageSize; } - /** The maximum number of artifacts to return. Maximum page size is 1,000. */ + /** The maximum number of rules to return. Maximum page size is 1,000. */ public List setPageSize(java.lang.Integer pageSize) { this.pageSize = pageSize; return this; @@ -8337,6 +10114,171 @@ public List set(String parameterName, Object value) { return (List) super.set(parameterName, value); } } + /** + * Updates a rule. + * + * Create a request for the method "rules.patch". + * + * This request holds the parameters needed by the artifactregistry server. After setting any + * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. + * + * @param name The name of the rule, for example: "projects/p1/locations/us- + * central1/repositories/repo1/rules/rule1". + * @param content the {@link com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1Rule} + * @return the request + */ + public Patch patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1Rule content) throws java.io.IOException { + Patch result = new Patch(name, content); + initialize(result); + return result; + } + + public class Patch extends ArtifactRegistryRequest { + + private static final String REST_PATH = "v1/{+name}"; + + private final java.util.regex.Pattern NAME_PATTERN = + java.util.regex.Pattern.compile("^projects/[^/]+/locations/[^/]+/repositories/[^/]+/rules/[^/]+$"); + + /** + * Updates a rule. + * + * Create a request for the method "rules.patch". + * + * This request holds the parameters needed by the the artifactregistry server. After setting any + * optional parameters, call the {@link Patch#execute()} method to invoke the remote operation. + *

{@link + * Patch#initialize(com.google.api.client.googleapis.services.AbstractGoogleClientRequest)} must + * be called to initialize this instance immediately after invoking the constructor.

+ * + * @param name The name of the rule, for example: "projects/p1/locations/us- + * central1/repositories/repo1/rules/rule1". + * @param content the {@link com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1Rule} + * @since 1.13 + */ + protected Patch(java.lang.String name, com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1Rule content) { + super(ArtifactRegistry.this, "PATCH", REST_PATH, content, com.google.api.services.artifactregistry.v1.model.GoogleDevtoolsArtifactregistryV1Rule.class); + this.name = com.google.api.client.util.Preconditions.checkNotNull(name, "Required parameter name must be specified."); + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/rules/[^/]+$"); + } + } + + @Override + public Patch set$Xgafv(java.lang.String $Xgafv) { + return (Patch) super.set$Xgafv($Xgafv); + } + + @Override + public Patch setAccessToken(java.lang.String accessToken) { + return (Patch) super.setAccessToken(accessToken); + } + + @Override + public Patch setAlt(java.lang.String alt) { + return (Patch) super.setAlt(alt); + } + + @Override + public Patch setCallback(java.lang.String callback) { + return (Patch) super.setCallback(callback); + } + + @Override + public Patch setFields(java.lang.String fields) { + return (Patch) super.setFields(fields); + } + + @Override + public Patch setKey(java.lang.String key) { + return (Patch) super.setKey(key); + } + + @Override + public Patch setOauthToken(java.lang.String oauthToken) { + return (Patch) super.setOauthToken(oauthToken); + } + + @Override + public Patch setPrettyPrint(java.lang.Boolean prettyPrint) { + return (Patch) super.setPrettyPrint(prettyPrint); + } + + @Override + public Patch setQuotaUser(java.lang.String quotaUser) { + return (Patch) super.setQuotaUser(quotaUser); + } + + @Override + public Patch setUploadType(java.lang.String uploadType) { + return (Patch) super.setUploadType(uploadType); + } + + @Override + public Patch setUploadProtocol(java.lang.String uploadProtocol) { + return (Patch) super.setUploadProtocol(uploadProtocol); + } + + /** + * The name of the rule, for example: "projects/p1/locations/us- + * central1/repositories/repo1/rules/rule1". + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** The name of the rule, for example: "projects/p1/locations/us- + central1/repositories/repo1/rules/rule1". + */ + public java.lang.String getName() { + return name; + } + + /** + * The name of the rule, for example: "projects/p1/locations/us- + * central1/repositories/repo1/rules/rule1". + */ + public Patch setName(java.lang.String name) { + if (!getSuppressPatternChecks()) { + com.google.api.client.util.Preconditions.checkArgument(NAME_PATTERN.matcher(name).matches(), + "Parameter name must conform to the pattern " + + "^projects/[^/]+/locations/[^/]+/repositories/[^/]+/rules/[^/]+$"); + } + this.name = name; + return this; + } + + /** + * The update mask applies to the resource. For the `FieldMask` definition, see + * https://developers.google.com/protocol- + * buffers/docs/reference/google.protobuf#fieldmask + */ + @com.google.api.client.util.Key + private String updateMask; + + /** The update mask applies to the resource. For the `FieldMask` definition, see + https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask + */ + public String getUpdateMask() { + return updateMask; + } + + /** + * The update mask applies to the resource. For the `FieldMask` definition, see + * https://developers.google.com/protocol- + * buffers/docs/reference/google.protobuf#fieldmask + */ + public Patch setUpdateMask(String updateMask) { + this.updateMask = updateMask; + return this; + } + + @Override + public Patch set(String parameterName, Object value) { + return (Patch) super.set(parameterName, value); + } + } } /** diff --git a/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/Attachment.java b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/Attachment.java new file mode 100644 index 00000000000..e0c6bb7bc19 --- /dev/null +++ b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/Attachment.java @@ -0,0 +1,281 @@ +/* + * 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. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.artifactregistry.v1.model; + +/** + * An Attachment refers to additional metadata that can be attached to artifacts in + * ArtifactRegistry. An attachment consists of one or more files. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Artifact Registry API. For a detailed explanation + * see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class Attachment extends com.google.api.client.json.GenericJson { + + /** + * Optional. User annotations. These attributes can only be set and used by the user, and not by + * Artifact Registry. See https://google.aip.dev/128#annotations for more details such as format + * and size limitations. Client specified annotations. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.Map annotations; + + /** + * The namespace this attachment belongs to. E.g. If an Attachment is created by artifact + * analysis, namespace is set to artifactanalysis.googleapis.com. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String attachmentNamespace; + + /** + * Output only. The time when the attachment was created. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private String createTime; + + /** + * Required. The files that blong to this Attachment. If the file ID part contains slashes, they + * are escaped. E.g. "projects/p1/locations/us-central1/repositories/repo1/files/sha:". + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List files; + + /** + * The name of the attachment. E.g. "projects/p1/locations/us/repositories/repo/attachments/sbom". + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** + * Output only. The name of the OCI version that this attachment created. Only populated for + * Docker attachments. E.g. "projects/p1/locations/us- + * central1/repositories/repo1/packages/p1/versions/v1". + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String ociVersionName; + + /** + * Required. The target the attachment is for, can be a Version, Package or Repository. E.g. + * "projects/p1/locations/us-central1/repositories/repo1/packages/p1/versions/v1". + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String target; + + /** + * Type of Attachment. E.g. application/vnd.spdx+jsonn + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String type; + + /** + * Output only. The time when the attachment was last updated. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private String updateTime; + + /** + * Optional. User annotations. These attributes can only be set and used by the user, and not by + * Artifact Registry. See https://google.aip.dev/128#annotations for more details such as format + * and size limitations. Client specified annotations. + * @return value or {@code null} for none + */ + public java.util.Map getAnnotations() { + return annotations; + } + + /** + * Optional. User annotations. These attributes can only be set and used by the user, and not by + * Artifact Registry. See https://google.aip.dev/128#annotations for more details such as format + * and size limitations. Client specified annotations. + * @param annotations annotations or {@code null} for none + */ + public Attachment setAnnotations(java.util.Map annotations) { + this.annotations = annotations; + return this; + } + + /** + * The namespace this attachment belongs to. E.g. If an Attachment is created by artifact + * analysis, namespace is set to artifactanalysis.googleapis.com. + * @return value or {@code null} for none + */ + public java.lang.String getAttachmentNamespace() { + return attachmentNamespace; + } + + /** + * The namespace this attachment belongs to. E.g. If an Attachment is created by artifact + * analysis, namespace is set to artifactanalysis.googleapis.com. + * @param attachmentNamespace attachmentNamespace or {@code null} for none + */ + public Attachment setAttachmentNamespace(java.lang.String attachmentNamespace) { + this.attachmentNamespace = attachmentNamespace; + return this; + } + + /** + * Output only. The time when the attachment was created. + * @return value or {@code null} for none + */ + public String getCreateTime() { + return createTime; + } + + /** + * Output only. The time when the attachment was created. + * @param createTime createTime or {@code null} for none + */ + public Attachment setCreateTime(String createTime) { + this.createTime = createTime; + return this; + } + + /** + * Required. The files that blong to this Attachment. If the file ID part contains slashes, they + * are escaped. E.g. "projects/p1/locations/us-central1/repositories/repo1/files/sha:". + * @return value or {@code null} for none + */ + public java.util.List getFiles() { + return files; + } + + /** + * Required. The files that blong to this Attachment. If the file ID part contains slashes, they + * are escaped. E.g. "projects/p1/locations/us-central1/repositories/repo1/files/sha:". + * @param files files or {@code null} for none + */ + public Attachment setFiles(java.util.List files) { + this.files = files; + return this; + } + + /** + * The name of the attachment. E.g. "projects/p1/locations/us/repositories/repo/attachments/sbom". + * @return value or {@code null} for none + */ + public java.lang.String getName() { + return name; + } + + /** + * The name of the attachment. E.g. "projects/p1/locations/us/repositories/repo/attachments/sbom". + * @param name name or {@code null} for none + */ + public Attachment setName(java.lang.String name) { + this.name = name; + return this; + } + + /** + * Output only. The name of the OCI version that this attachment created. Only populated for + * Docker attachments. E.g. "projects/p1/locations/us- + * central1/repositories/repo1/packages/p1/versions/v1". + * @return value or {@code null} for none + */ + public java.lang.String getOciVersionName() { + return ociVersionName; + } + + /** + * Output only. The name of the OCI version that this attachment created. Only populated for + * Docker attachments. E.g. "projects/p1/locations/us- + * central1/repositories/repo1/packages/p1/versions/v1". + * @param ociVersionName ociVersionName or {@code null} for none + */ + public Attachment setOciVersionName(java.lang.String ociVersionName) { + this.ociVersionName = ociVersionName; + return this; + } + + /** + * Required. The target the attachment is for, can be a Version, Package or Repository. E.g. + * "projects/p1/locations/us-central1/repositories/repo1/packages/p1/versions/v1". + * @return value or {@code null} for none + */ + public java.lang.String getTarget() { + return target; + } + + /** + * Required. The target the attachment is for, can be a Version, Package or Repository. E.g. + * "projects/p1/locations/us-central1/repositories/repo1/packages/p1/versions/v1". + * @param target target or {@code null} for none + */ + public Attachment setTarget(java.lang.String target) { + this.target = target; + return this; + } + + /** + * Type of Attachment. E.g. application/vnd.spdx+jsonn + * @return value or {@code null} for none + */ + public java.lang.String getType() { + return type; + } + + /** + * Type of Attachment. E.g. application/vnd.spdx+jsonn + * @param type type or {@code null} for none + */ + public Attachment setType(java.lang.String type) { + this.type = type; + return this; + } + + /** + * Output only. The time when the attachment was last updated. + * @return value or {@code null} for none + */ + public String getUpdateTime() { + return updateTime; + } + + /** + * Output only. The time when the attachment was last updated. + * @param updateTime updateTime or {@code null} for none + */ + public Attachment setUpdateTime(String updateTime) { + this.updateTime = updateTime; + return this; + } + + @Override + public Attachment set(String fieldName, Object value) { + return (Attachment) super.set(fieldName, value); + } + + @Override + public Attachment clone() { + return (Attachment) super.clone(); + } + +} diff --git a/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/GoogleDevtoolsArtifactregistryV1File.java b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/GoogleDevtoolsArtifactregistryV1File.java index 2bf420618bc..ee158a5ba82 100644 --- a/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/GoogleDevtoolsArtifactregistryV1File.java +++ b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/GoogleDevtoolsArtifactregistryV1File.java @@ -30,6 +30,13 @@ @SuppressWarnings("javadoc") public final class GoogleDevtoolsArtifactregistryV1File extends com.google.api.client.json.GenericJson { + /** + * Optional. Client specified annotations. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.Map annotations; + /** * Output only. The time when the File was created. * The value may be {@code null}. @@ -82,6 +89,23 @@ public final class GoogleDevtoolsArtifactregistryV1File extends com.google.api.c @com.google.api.client.util.Key private String updateTime; + /** + * Optional. Client specified annotations. + * @return value or {@code null} for none + */ + public java.util.Map getAnnotations() { + return annotations; + } + + /** + * Optional. Client specified annotations. + * @param annotations annotations or {@code null} for none + */ + public GoogleDevtoolsArtifactregistryV1File setAnnotations(java.util.Map annotations) { + this.annotations = annotations; + return this; + } + /** * Output only. The time when the File was created. * @return value or {@code null} for none diff --git a/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/GoogleDevtoolsArtifactregistryV1Rule.java b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/GoogleDevtoolsArtifactregistryV1Rule.java new file mode 100644 index 00000000000..b94ba8c1f3c --- /dev/null +++ b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/GoogleDevtoolsArtifactregistryV1Rule.java @@ -0,0 +1,170 @@ +/* + * 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. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.artifactregistry.v1.model; + +/** + * A Rule applies to repository or package level. It defines the deny or allow action of the + * operation when the conditions in the rule are met. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Artifact Registry API. For a detailed explanation + * see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class GoogleDevtoolsArtifactregistryV1Rule extends com.google.api.client.json.GenericJson { + + /** + * The action this rule makes. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String action; + + /** + * Optional. The condition of the rule in CEL expression. If not provided, the rule matches all + * the objects. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private Expr condition; + + /** + * The name of the rule, for example: "projects/p1/locations/us- + * central1/repositories/repo1/rules/rule1". + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String name; + + /** + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String operation; + + /** + * The package ID the rule applies to. If empty, this rule applies to all the packages inside the + * repository. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String packageId; + + /** + * The action this rule makes. + * @return value or {@code null} for none + */ + public java.lang.String getAction() { + return action; + } + + /** + * The action this rule makes. + * @param action action or {@code null} for none + */ + public GoogleDevtoolsArtifactregistryV1Rule setAction(java.lang.String action) { + this.action = action; + return this; + } + + /** + * Optional. The condition of the rule in CEL expression. If not provided, the rule matches all + * the objects. + * @return value or {@code null} for none + */ + public Expr getCondition() { + return condition; + } + + /** + * Optional. The condition of the rule in CEL expression. If not provided, the rule matches all + * the objects. + * @param condition condition or {@code null} for none + */ + public GoogleDevtoolsArtifactregistryV1Rule setCondition(Expr condition) { + this.condition = condition; + return this; + } + + /** + * The name of the rule, for example: "projects/p1/locations/us- + * central1/repositories/repo1/rules/rule1". + * @return value or {@code null} for none + */ + public java.lang.String getName() { + return name; + } + + /** + * The name of the rule, for example: "projects/p1/locations/us- + * central1/repositories/repo1/rules/rule1". + * @param name name or {@code null} for none + */ + public GoogleDevtoolsArtifactregistryV1Rule setName(java.lang.String name) { + this.name = name; + return this; + } + + /** + * @return value or {@code null} for none + */ + public java.lang.String getOperation() { + return operation; + } + + /** + * @param operation operation or {@code null} for none + */ + public GoogleDevtoolsArtifactregistryV1Rule setOperation(java.lang.String operation) { + this.operation = operation; + return this; + } + + /** + * The package ID the rule applies to. If empty, this rule applies to all the packages inside the + * repository. + * @return value or {@code null} for none + */ + public java.lang.String getPackageId() { + return packageId; + } + + /** + * The package ID the rule applies to. If empty, this rule applies to all the packages inside the + * repository. + * @param packageId packageId or {@code null} for none + */ + public GoogleDevtoolsArtifactregistryV1Rule setPackageId(java.lang.String packageId) { + this.packageId = packageId; + return this; + } + + @Override + public GoogleDevtoolsArtifactregistryV1Rule set(String fieldName, Object value) { + return (GoogleDevtoolsArtifactregistryV1Rule) super.set(fieldName, value); + } + + @Override + public GoogleDevtoolsArtifactregistryV1Rule clone() { + return (GoogleDevtoolsArtifactregistryV1Rule) super.clone(); + } + +} diff --git a/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/ListAttachmentsResponse.java b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/ListAttachmentsResponse.java new file mode 100644 index 00000000000..51a4ce958bb --- /dev/null +++ b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/ListAttachmentsResponse.java @@ -0,0 +1,100 @@ +/* + * 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. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.artifactregistry.v1.model; + +/** + * The response from listing attachments. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Artifact Registry API. For a detailed explanation + * see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class ListAttachmentsResponse extends com.google.api.client.json.GenericJson { + + /** + * The Attachments returned. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List attachments; + + static { + // hack to force ProGuard to consider Attachment used, since otherwise it would be stripped out + // see https://github.com/google/google-api-java-client/issues/543 + com.google.api.client.util.Data.nullOf(Attachment.class); + } + + /** + * The token to retrieve the next page of attachments, or empty if there are no more attachments + * to return. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String nextPageToken; + + /** + * The Attachments returned. + * @return value or {@code null} for none + */ + public java.util.List getAttachments() { + return attachments; + } + + /** + * The Attachments returned. + * @param attachments attachments or {@code null} for none + */ + public ListAttachmentsResponse setAttachments(java.util.List attachments) { + this.attachments = attachments; + return this; + } + + /** + * The token to retrieve the next page of attachments, or empty if there are no more attachments + * to return. + * @return value or {@code null} for none + */ + public java.lang.String getNextPageToken() { + return nextPageToken; + } + + /** + * The token to retrieve the next page of attachments, or empty if there are no more attachments + * to return. + * @param nextPageToken nextPageToken or {@code null} for none + */ + public ListAttachmentsResponse setNextPageToken(java.lang.String nextPageToken) { + this.nextPageToken = nextPageToken; + return this; + } + + @Override + public ListAttachmentsResponse set(String fieldName, Object value) { + return (ListAttachmentsResponse) super.set(fieldName, value); + } + + @Override + public ListAttachmentsResponse clone() { + return (ListAttachmentsResponse) super.clone(); + } + +} diff --git a/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/ListRulesResponse.java b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/ListRulesResponse.java new file mode 100644 index 00000000000..a153b5d2a8c --- /dev/null +++ b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/ListRulesResponse.java @@ -0,0 +1,97 @@ +/* + * 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. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.artifactregistry.v1.model; + +/** + * The response from listing rules. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Artifact Registry API. For a detailed explanation + * see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class ListRulesResponse extends com.google.api.client.json.GenericJson { + + /** + * The token to retrieve the next page of rules, or empty if there are no more rules to return. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String nextPageToken; + + /** + * The rules returned. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.List rules; + + static { + // hack to force ProGuard to consider GoogleDevtoolsArtifactregistryV1Rule used, since otherwise it would be stripped out + // see https://github.com/google/google-api-java-client/issues/543 + com.google.api.client.util.Data.nullOf(GoogleDevtoolsArtifactregistryV1Rule.class); + } + + /** + * The token to retrieve the next page of rules, or empty if there are no more rules to return. + * @return value or {@code null} for none + */ + public java.lang.String getNextPageToken() { + return nextPageToken; + } + + /** + * The token to retrieve the next page of rules, or empty if there are no more rules to return. + * @param nextPageToken nextPageToken or {@code null} for none + */ + public ListRulesResponse setNextPageToken(java.lang.String nextPageToken) { + this.nextPageToken = nextPageToken; + return this; + } + + /** + * The rules returned. + * @return value or {@code null} for none + */ + public java.util.List getRules() { + return rules; + } + + /** + * The rules returned. + * @param rules rules or {@code null} for none + */ + public ListRulesResponse setRules(java.util.List rules) { + this.rules = rules; + return this; + } + + @Override + public ListRulesResponse set(String fieldName, Object value) { + return (ListRulesResponse) super.set(fieldName, value); + } + + @Override + public ListRulesResponse clone() { + return (ListRulesResponse) super.clone(); + } + +} diff --git a/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/UploadFileMediaResponse.java b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/UploadFileMediaResponse.java new file mode 100644 index 00000000000..7ebd111cd89 --- /dev/null +++ b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/UploadFileMediaResponse.java @@ -0,0 +1,67 @@ +/* + * 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. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.artifactregistry.v1.model; + +/** + * The response to upload a generic artifact. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Artifact Registry API. For a detailed explanation + * see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class UploadFileMediaResponse extends com.google.api.client.json.GenericJson { + + /** + * Operation that will be returned to the user. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private Operation operation; + + /** + * Operation that will be returned to the user. + * @return value or {@code null} for none + */ + public Operation getOperation() { + return operation; + } + + /** + * Operation that will be returned to the user. + * @param operation operation or {@code null} for none + */ + public UploadFileMediaResponse setOperation(Operation operation) { + this.operation = operation; + return this; + } + + @Override + public UploadFileMediaResponse set(String fieldName, Object value) { + return (UploadFileMediaResponse) super.set(fieldName, value); + } + + @Override + public UploadFileMediaResponse clone() { + return (UploadFileMediaResponse) super.clone(); + } + +} diff --git a/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/UploadFileRequest.java b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/UploadFileRequest.java new file mode 100644 index 00000000000..20cfd45d724 --- /dev/null +++ b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/UploadFileRequest.java @@ -0,0 +1,70 @@ +/* + * 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. + */ +/* + * This code was generated by https://github.com/googleapis/google-api-java-client-services/ + * Modify at your own risk. + */ + +package com.google.api.services.artifactregistry.v1.model; + +/** + * The request to upload a file. + * + *

This is the Java data model class that specifies how to parse/serialize into the JSON that is + * transmitted over HTTP when working with the Artifact Registry API. For a detailed explanation + * see: + * https://developers.google.com/api-client-library/java/google-http-java-client/json + *

+ * + * @author Google, Inc. + */ +@SuppressWarnings("javadoc") +public final class UploadFileRequest extends com.google.api.client.json.GenericJson { + + /** + * Optional. The ID of the file. If left empty will default to sha256 digest of the content + * uploaded. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.lang.String fileId; + + /** + * Optional. The ID of the file. If left empty will default to sha256 digest of the content + * uploaded. + * @return value or {@code null} for none + */ + public java.lang.String getFileId() { + return fileId; + } + + /** + * Optional. The ID of the file. If left empty will default to sha256 digest of the content + * uploaded. + * @param fileId fileId or {@code null} for none + */ + public UploadFileRequest setFileId(java.lang.String fileId) { + this.fileId = fileId; + return this; + } + + @Override + public UploadFileRequest set(String fieldName, Object value) { + return (UploadFileRequest) super.set(fieldName, value); + } + + @Override + public UploadFileRequest clone() { + return (UploadFileRequest) super.clone(); + } + +} diff --git a/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/Version.java b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/Version.java index d7572980bbc..525f46e6589 100644 --- a/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/Version.java +++ b/clients/google-api-services-artifactregistry/v1/2.0.0/com/google/api/services/artifactregistry/v1/model/Version.java @@ -31,6 +31,13 @@ @SuppressWarnings("javadoc") public final class Version extends com.google.api.client.json.GenericJson { + /** + * Optional. Client specified annotations. + * The value may be {@code null}. + */ + @com.google.api.client.util.Key + private java.util.Map annotations; + /** * The time when the version was created. * The value may be {@code null}. @@ -83,6 +90,23 @@ public final class Version extends com.google.api.client.json.GenericJson { @com.google.api.client.util.Key private String updateTime; + /** + * Optional. Client specified annotations. + * @return value or {@code null} for none + */ + public java.util.Map getAnnotations() { + return annotations; + } + + /** + * Optional. Client specified annotations. + * @param annotations annotations or {@code null} for none + */ + public Version setAnnotations(java.util.Map annotations) { + this.annotations = annotations; + return this; + } + /** * The time when the version was created. * @return value or {@code null} for none diff --git a/clients/google-api-services-artifactregistry/v1/2.0.0/pom.xml b/clients/google-api-services-artifactregistry/v1/2.0.0/pom.xml index e956791efd0..5628d138b6e 100644 --- a/clients/google-api-services-artifactregistry/v1/2.0.0/pom.xml +++ b/clients/google-api-services-artifactregistry/v1/2.0.0/pom.xml @@ -8,8 +8,8 @@ com.google.apis google-api-services-artifactregistry - v1-rev20240903-2.0.0 - Artifact Registry API v1-rev20240903-2.0.0 + v1-rev20240923-2.0.0 + Artifact Registry API v1-rev20240923-2.0.0 jar 2011 diff --git a/clients/google-api-services-artifactregistry/v1/README.md b/clients/google-api-services-artifactregistry/v1/README.md index e385ddc9b25..45d71cceef3 100644 --- a/clients/google-api-services-artifactregistry/v1/README.md +++ b/clients/google-api-services-artifactregistry/v1/README.md @@ -22,7 +22,7 @@ Add the following lines to your `pom.xml` file: com.google.apis google-api-services-artifactregistry - v1-rev20240903-2.0.0 + v1-rev20240923-2.0.0 @@ -35,7 +35,7 @@ repositories { mavenCentral() } dependencies { - implementation 'com.google.apis:google-api-services-artifactregistry:v1-rev20240903-2.0.0' + implementation 'com.google.apis:google-api-services-artifactregistry:v1-rev20240923-2.0.0' } ```