Skip to content
This repository was archived by the owner on Sep 16, 2023. It is now read-only.

Commit dd2adb5

Browse files
fix: Fix the resource annotations for GetRepositoryRequest (#171)
- [x] Regenerate this pull request now. BREAKING CHANGE: This will be a breaking change for languages that generate client libraries using resource annotations to provide overloads accepting resource names. Where previously such languages would have generated (in-pseudocode) GetRepository(LocationName) they will now (correctly) generate GetRepository(RepositoryName). Code using the older methods will be broken by this change, but would never have worked anyway. PiperOrigin-RevId: 403028264 Source-Link: googleapis/googleapis@9bac62d Source-Link: https://github.com/googleapis/googleapis-gen/commit/4f54454b649bcedea14bb01955a65850ce906d9b Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNGY1NDQ1NGI2NDliY2VkZWExNGJiMDE5NTVhNjU4NTBjZTkwNmQ5YiJ9
1 parent e97c22c commit dd2adb5

34 files changed

+117
-117
lines changed

proto-google-cloud-artifact-registry-v1/src/main/java/com/google/devtools/artifactregistry/v1/DockerImage.java

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@
2525
* DockerImage represents a docker artifact.
2626
* The following fields are returned as untyped metadata in the Version
2727
* resource, using camelcase keys (i.e. metadata.imageSizeBytes):
28-
* * imageSizeBytes
29-
* * mediaType
30-
* * buildTime
28+
* - imageSizeBytes
29+
* - mediaType
30+
* - buildTime
3131
* </pre>
3232
*
3333
* Protobuf type {@code google.devtools.artifactregistry.v1.DockerImage}
@@ -556,10 +556,10 @@ public final boolean isInitialized() {
556556

557557
@java.lang.Override
558558
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
559-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
559+
if (!getNameBytes().isEmpty()) {
560560
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_);
561561
}
562-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uri_)) {
562+
if (!getUriBytes().isEmpty()) {
563563
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, uri_);
564564
}
565565
for (int i = 0; i < tags_.size(); i++) {
@@ -571,7 +571,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
571571
if (uploadTime_ != null) {
572572
output.writeMessage(5, getUploadTime());
573573
}
574-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(mediaType_)) {
574+
if (!getMediaTypeBytes().isEmpty()) {
575575
com.google.protobuf.GeneratedMessageV3.writeString(output, 6, mediaType_);
576576
}
577577
if (buildTime_ != null) {
@@ -586,10 +586,10 @@ public int getSerializedSize() {
586586
if (size != -1) return size;
587587

588588
size = 0;
589-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
589+
if (!getNameBytes().isEmpty()) {
590590
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_);
591591
}
592-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uri_)) {
592+
if (!getUriBytes().isEmpty()) {
593593
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, uri_);
594594
}
595595
{
@@ -606,7 +606,7 @@ public int getSerializedSize() {
606606
if (uploadTime_ != null) {
607607
size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getUploadTime());
608608
}
609-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(mediaType_)) {
609+
if (!getMediaTypeBytes().isEmpty()) {
610610
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, mediaType_);
611611
}
612612
if (buildTime_ != null) {
@@ -779,9 +779,9 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build
779779
* DockerImage represents a docker artifact.
780780
* The following fields are returned as untyped metadata in the Version
781781
* resource, using camelcase keys (i.e. metadata.imageSizeBytes):
782-
* * imageSizeBytes
783-
* * mediaType
784-
* * buildTime
782+
* - imageSizeBytes
783+
* - mediaType
784+
* - buildTime
785785
* </pre>
786786
*
787787
* Protobuf type {@code google.devtools.artifactregistry.v1.DockerImage}

proto-google-cloud-artifact-registry-v1/src/main/java/com/google/devtools/artifactregistry/v1/GetRepositoryRequest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,7 @@ public final boolean isInitialized() {
178178

179179
@java.lang.Override
180180
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
181-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
181+
if (!getNameBytes().isEmpty()) {
182182
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_);
183183
}
184184
unknownFields.writeTo(output);
@@ -190,7 +190,7 @@ public int getSerializedSize() {
190190
if (size != -1) return size;
191191

192192
size = 0;
193-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
193+
if (!getNameBytes().isEmpty()) {
194194
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_);
195195
}
196196
size += unknownFields.getSerializedSize();

proto-google-cloud-artifact-registry-v1/src/main/java/com/google/devtools/artifactregistry/v1/ListDockerImagesRequest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -254,13 +254,13 @@ public final boolean isInitialized() {
254254

255255
@java.lang.Override
256256
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
257-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) {
257+
if (!getParentBytes().isEmpty()) {
258258
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_);
259259
}
260260
if (pageSize_ != 0) {
261261
output.writeInt32(2, pageSize_);
262262
}
263-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) {
263+
if (!getPageTokenBytes().isEmpty()) {
264264
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_);
265265
}
266266
unknownFields.writeTo(output);
@@ -272,13 +272,13 @@ public int getSerializedSize() {
272272
if (size != -1) return size;
273273

274274
size = 0;
275-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) {
275+
if (!getParentBytes().isEmpty()) {
276276
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_);
277277
}
278278
if (pageSize_ != 0) {
279279
size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_);
280280
}
281-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) {
281+
if (!getPageTokenBytes().isEmpty()) {
282282
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_);
283283
}
284284
size += unknownFields.getSerializedSize();

proto-google-cloud-artifact-registry-v1/src/main/java/com/google/devtools/artifactregistry/v1/ListDockerImagesResponse.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
267267
for (int i = 0; i < dockerImages_.size(); i++) {
268268
output.writeMessage(1, dockerImages_.get(i));
269269
}
270-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) {
270+
if (!getNextPageTokenBytes().isEmpty()) {
271271
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_);
272272
}
273273
unknownFields.writeTo(output);
@@ -282,7 +282,7 @@ public int getSerializedSize() {
282282
for (int i = 0; i < dockerImages_.size(); i++) {
283283
size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, dockerImages_.get(i));
284284
}
285-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) {
285+
if (!getNextPageTokenBytes().isEmpty()) {
286286
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_);
287287
}
288288
size += unknownFields.getSerializedSize();

proto-google-cloud-artifact-registry-v1/src/main/java/com/google/devtools/artifactregistry/v1/ListRepositoriesRequest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -258,13 +258,13 @@ public final boolean isInitialized() {
258258

259259
@java.lang.Override
260260
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
261-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) {
261+
if (!getParentBytes().isEmpty()) {
262262
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_);
263263
}
264264
if (pageSize_ != 0) {
265265
output.writeInt32(2, pageSize_);
266266
}
267-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) {
267+
if (!getPageTokenBytes().isEmpty()) {
268268
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_);
269269
}
270270
unknownFields.writeTo(output);
@@ -276,13 +276,13 @@ public int getSerializedSize() {
276276
if (size != -1) return size;
277277

278278
size = 0;
279-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) {
279+
if (!getParentBytes().isEmpty()) {
280280
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_);
281281
}
282282
if (pageSize_ != 0) {
283283
size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_);
284284
}
285-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) {
285+
if (!getPageTokenBytes().isEmpty()) {
286286
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_);
287287
}
288288
size += unknownFields.getSerializedSize();

proto-google-cloud-artifact-registry-v1/src/main/java/com/google/devtools/artifactregistry/v1/ListRepositoriesResponse.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
267267
for (int i = 0; i < repositories_.size(); i++) {
268268
output.writeMessage(1, repositories_.get(i));
269269
}
270-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) {
270+
if (!getNextPageTokenBytes().isEmpty()) {
271271
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_);
272272
}
273273
unknownFields.writeTo(output);
@@ -282,7 +282,7 @@ public int getSerializedSize() {
282282
for (int i = 0; i < repositories_.size(); i++) {
283283
size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, repositories_.get(i));
284284
}
285-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) {
285+
if (!getNextPageTokenBytes().isEmpty()) {
286286
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_);
287287
}
288288
size += unknownFields.getSerializedSize();

proto-google-cloud-artifact-registry-v1/src/main/java/com/google/devtools/artifactregistry/v1/Repository.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -850,15 +850,15 @@ public final boolean isInitialized() {
850850

851851
@java.lang.Override
852852
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
853-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
853+
if (!getNameBytes().isEmpty()) {
854854
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_);
855855
}
856856
if (format_
857857
!= com.google.devtools.artifactregistry.v1.Repository.Format.FORMAT_UNSPECIFIED
858858
.getNumber()) {
859859
output.writeEnum(2, format_);
860860
}
861-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
861+
if (!getDescriptionBytes().isEmpty()) {
862862
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, description_);
863863
}
864864
com.google.protobuf.GeneratedMessageV3.serializeStringMapTo(
@@ -869,7 +869,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
869869
if (updateTime_ != null) {
870870
output.writeMessage(6, getUpdateTime());
871871
}
872-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKeyName_)) {
872+
if (!getKmsKeyNameBytes().isEmpty()) {
873873
com.google.protobuf.GeneratedMessageV3.writeString(output, 8, kmsKeyName_);
874874
}
875875
unknownFields.writeTo(output);
@@ -881,15 +881,15 @@ public int getSerializedSize() {
881881
if (size != -1) return size;
882882

883883
size = 0;
884-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
884+
if (!getNameBytes().isEmpty()) {
885885
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_);
886886
}
887887
if (format_
888888
!= com.google.devtools.artifactregistry.v1.Repository.Format.FORMAT_UNSPECIFIED
889889
.getNumber()) {
890890
size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, format_);
891891
}
892-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) {
892+
if (!getDescriptionBytes().isEmpty()) {
893893
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, description_);
894894
}
895895
for (java.util.Map.Entry<java.lang.String, java.lang.String> entry :
@@ -908,7 +908,7 @@ public int getSerializedSize() {
908908
if (updateTime_ != null) {
909909
size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getUpdateTime());
910910
}
911-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKeyName_)) {
911+
if (!getKmsKeyNameBytes().isEmpty()) {
912912
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, kmsKeyName_);
913913
}
914914
size += unknownFields.getSerializedSize();

proto-google-cloud-artifact-registry-v1/src/main/proto/google/devtools/artifactregistry/v1/artifact.proto

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,9 @@ option ruby_package = "Google::Cloud::ArtifactRegistry::V1";
3232
// DockerImage represents a docker artifact.
3333
// The following fields are returned as untyped metadata in the Version
3434
// resource, using camelcase keys (i.e. metadata.imageSizeBytes):
35-
// * imageSizeBytes
36-
// * mediaType
37-
// * buildTime
35+
// - imageSizeBytes
36+
// - mediaType
37+
// - buildTime
3838
message DockerImage {
3939
option (google.api.resource) = {
4040
type: "artifactregistry.googleapis.com/DockerImage"

proto-google-cloud-artifact-registry-v1beta2/src/main/java/com/google/devtools/artifactregistry/v1beta2/CreateRepositoryRequest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -296,10 +296,10 @@ public final boolean isInitialized() {
296296

297297
@java.lang.Override
298298
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
299-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) {
299+
if (!getParentBytes().isEmpty()) {
300300
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_);
301301
}
302-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(repositoryId_)) {
302+
if (!getRepositoryIdBytes().isEmpty()) {
303303
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, repositoryId_);
304304
}
305305
if (repository_ != null) {
@@ -314,10 +314,10 @@ public int getSerializedSize() {
314314
if (size != -1) return size;
315315

316316
size = 0;
317-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) {
317+
if (!getParentBytes().isEmpty()) {
318318
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_);
319319
}
320-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(repositoryId_)) {
320+
if (!getRepositoryIdBytes().isEmpty()) {
321321
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, repositoryId_);
322322
}
323323
if (repository_ != null) {

proto-google-cloud-artifact-registry-v1beta2/src/main/java/com/google/devtools/artifactregistry/v1beta2/CreateTagRequest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -295,10 +295,10 @@ public final boolean isInitialized() {
295295

296296
@java.lang.Override
297297
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
298-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) {
298+
if (!getParentBytes().isEmpty()) {
299299
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_);
300300
}
301-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(tagId_)) {
301+
if (!getTagIdBytes().isEmpty()) {
302302
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, tagId_);
303303
}
304304
if (tag_ != null) {
@@ -313,10 +313,10 @@ public int getSerializedSize() {
313313
if (size != -1) return size;
314314

315315
size = 0;
316-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) {
316+
if (!getParentBytes().isEmpty()) {
317317
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_);
318318
}
319-
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(tagId_)) {
319+
if (!getTagIdBytes().isEmpty()) {
320320
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, tagId_);
321321
}
322322
if (tag_ != null) {

0 commit comments

Comments
 (0)