• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright 2020 Google LLC
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *     https://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 // Generated by the protocol buffer compiler.  DO NOT EDIT!
17 // source: google/cloud/aiplatform/v1/custom_job.proto
18 
19 package com.google.cloud.aiplatform.v1;
20 
21 /**
22  *
23  *
24  * <pre>
25  * The spec of a Container.
26  * </pre>
27  *
28  * Protobuf type {@code google.cloud.aiplatform.v1.ContainerSpec}
29  */
30 public final class ContainerSpec extends com.google.protobuf.GeneratedMessageV3
31     implements
32     // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1.ContainerSpec)
33     ContainerSpecOrBuilder {
34   private static final long serialVersionUID = 0L;
35   // Use ContainerSpec.newBuilder() to construct.
ContainerSpec(com.google.protobuf.GeneratedMessageV3.Builder<?> builder)36   private ContainerSpec(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
37     super(builder);
38   }
39 
ContainerSpec()40   private ContainerSpec() {
41     imageUri_ = "";
42     command_ = com.google.protobuf.LazyStringArrayList.EMPTY;
43     args_ = com.google.protobuf.LazyStringArrayList.EMPTY;
44     env_ = java.util.Collections.emptyList();
45   }
46 
47   @java.lang.Override
48   @SuppressWarnings({"unused"})
newInstance(UnusedPrivateParameter unused)49   protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
50     return new ContainerSpec();
51   }
52 
53   @java.lang.Override
getUnknownFields()54   public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
55     return this.unknownFields;
56   }
57 
getDescriptor()58   public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
59     return com.google.cloud.aiplatform.v1.CustomJobProto
60         .internal_static_google_cloud_aiplatform_v1_ContainerSpec_descriptor;
61   }
62 
63   @java.lang.Override
64   protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()65       internalGetFieldAccessorTable() {
66     return com.google.cloud.aiplatform.v1.CustomJobProto
67         .internal_static_google_cloud_aiplatform_v1_ContainerSpec_fieldAccessorTable
68         .ensureFieldAccessorsInitialized(
69             com.google.cloud.aiplatform.v1.ContainerSpec.class,
70             com.google.cloud.aiplatform.v1.ContainerSpec.Builder.class);
71   }
72 
73   public static final int IMAGE_URI_FIELD_NUMBER = 1;
74 
75   @SuppressWarnings("serial")
76   private volatile java.lang.Object imageUri_ = "";
77   /**
78    *
79    *
80    * <pre>
81    * Required. The URI of a container image in the Container Registry that is to
82    * be run on each worker replica.
83    * </pre>
84    *
85    * <code>string image_uri = 1 [(.google.api.field_behavior) = REQUIRED];</code>
86    *
87    * @return The imageUri.
88    */
89   @java.lang.Override
getImageUri()90   public java.lang.String getImageUri() {
91     java.lang.Object ref = imageUri_;
92     if (ref instanceof java.lang.String) {
93       return (java.lang.String) ref;
94     } else {
95       com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
96       java.lang.String s = bs.toStringUtf8();
97       imageUri_ = s;
98       return s;
99     }
100   }
101   /**
102    *
103    *
104    * <pre>
105    * Required. The URI of a container image in the Container Registry that is to
106    * be run on each worker replica.
107    * </pre>
108    *
109    * <code>string image_uri = 1 [(.google.api.field_behavior) = REQUIRED];</code>
110    *
111    * @return The bytes for imageUri.
112    */
113   @java.lang.Override
getImageUriBytes()114   public com.google.protobuf.ByteString getImageUriBytes() {
115     java.lang.Object ref = imageUri_;
116     if (ref instanceof java.lang.String) {
117       com.google.protobuf.ByteString b =
118           com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
119       imageUri_ = b;
120       return b;
121     } else {
122       return (com.google.protobuf.ByteString) ref;
123     }
124   }
125 
126   public static final int COMMAND_FIELD_NUMBER = 2;
127 
128   @SuppressWarnings("serial")
129   private com.google.protobuf.LazyStringList command_;
130   /**
131    *
132    *
133    * <pre>
134    * The command to be invoked when the container is started.
135    * It overrides the entrypoint instruction in Dockerfile when provided.
136    * </pre>
137    *
138    * <code>repeated string command = 2;</code>
139    *
140    * @return A list containing the command.
141    */
getCommandList()142   public com.google.protobuf.ProtocolStringList getCommandList() {
143     return command_;
144   }
145   /**
146    *
147    *
148    * <pre>
149    * The command to be invoked when the container is started.
150    * It overrides the entrypoint instruction in Dockerfile when provided.
151    * </pre>
152    *
153    * <code>repeated string command = 2;</code>
154    *
155    * @return The count of command.
156    */
getCommandCount()157   public int getCommandCount() {
158     return command_.size();
159   }
160   /**
161    *
162    *
163    * <pre>
164    * The command to be invoked when the container is started.
165    * It overrides the entrypoint instruction in Dockerfile when provided.
166    * </pre>
167    *
168    * <code>repeated string command = 2;</code>
169    *
170    * @param index The index of the element to return.
171    * @return The command at the given index.
172    */
getCommand(int index)173   public java.lang.String getCommand(int index) {
174     return command_.get(index);
175   }
176   /**
177    *
178    *
179    * <pre>
180    * The command to be invoked when the container is started.
181    * It overrides the entrypoint instruction in Dockerfile when provided.
182    * </pre>
183    *
184    * <code>repeated string command = 2;</code>
185    *
186    * @param index The index of the value to return.
187    * @return The bytes of the command at the given index.
188    */
getCommandBytes(int index)189   public com.google.protobuf.ByteString getCommandBytes(int index) {
190     return command_.getByteString(index);
191   }
192 
193   public static final int ARGS_FIELD_NUMBER = 3;
194 
195   @SuppressWarnings("serial")
196   private com.google.protobuf.LazyStringList args_;
197   /**
198    *
199    *
200    * <pre>
201    * The arguments to be passed when starting the container.
202    * </pre>
203    *
204    * <code>repeated string args = 3;</code>
205    *
206    * @return A list containing the args.
207    */
getArgsList()208   public com.google.protobuf.ProtocolStringList getArgsList() {
209     return args_;
210   }
211   /**
212    *
213    *
214    * <pre>
215    * The arguments to be passed when starting the container.
216    * </pre>
217    *
218    * <code>repeated string args = 3;</code>
219    *
220    * @return The count of args.
221    */
getArgsCount()222   public int getArgsCount() {
223     return args_.size();
224   }
225   /**
226    *
227    *
228    * <pre>
229    * The arguments to be passed when starting the container.
230    * </pre>
231    *
232    * <code>repeated string args = 3;</code>
233    *
234    * @param index The index of the element to return.
235    * @return The args at the given index.
236    */
getArgs(int index)237   public java.lang.String getArgs(int index) {
238     return args_.get(index);
239   }
240   /**
241    *
242    *
243    * <pre>
244    * The arguments to be passed when starting the container.
245    * </pre>
246    *
247    * <code>repeated string args = 3;</code>
248    *
249    * @param index The index of the value to return.
250    * @return The bytes of the args at the given index.
251    */
getArgsBytes(int index)252   public com.google.protobuf.ByteString getArgsBytes(int index) {
253     return args_.getByteString(index);
254   }
255 
256   public static final int ENV_FIELD_NUMBER = 4;
257 
258   @SuppressWarnings("serial")
259   private java.util.List<com.google.cloud.aiplatform.v1.EnvVar> env_;
260   /**
261    *
262    *
263    * <pre>
264    * Environment variables to be passed to the container.
265    * Maximum limit is 100.
266    * </pre>
267    *
268    * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
269    */
270   @java.lang.Override
getEnvList()271   public java.util.List<com.google.cloud.aiplatform.v1.EnvVar> getEnvList() {
272     return env_;
273   }
274   /**
275    *
276    *
277    * <pre>
278    * Environment variables to be passed to the container.
279    * Maximum limit is 100.
280    * </pre>
281    *
282    * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
283    */
284   @java.lang.Override
285   public java.util.List<? extends com.google.cloud.aiplatform.v1.EnvVarOrBuilder>
getEnvOrBuilderList()286       getEnvOrBuilderList() {
287     return env_;
288   }
289   /**
290    *
291    *
292    * <pre>
293    * Environment variables to be passed to the container.
294    * Maximum limit is 100.
295    * </pre>
296    *
297    * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
298    */
299   @java.lang.Override
getEnvCount()300   public int getEnvCount() {
301     return env_.size();
302   }
303   /**
304    *
305    *
306    * <pre>
307    * Environment variables to be passed to the container.
308    * Maximum limit is 100.
309    * </pre>
310    *
311    * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
312    */
313   @java.lang.Override
getEnv(int index)314   public com.google.cloud.aiplatform.v1.EnvVar getEnv(int index) {
315     return env_.get(index);
316   }
317   /**
318    *
319    *
320    * <pre>
321    * Environment variables to be passed to the container.
322    * Maximum limit is 100.
323    * </pre>
324    *
325    * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
326    */
327   @java.lang.Override
getEnvOrBuilder(int index)328   public com.google.cloud.aiplatform.v1.EnvVarOrBuilder getEnvOrBuilder(int index) {
329     return env_.get(index);
330   }
331 
332   private byte memoizedIsInitialized = -1;
333 
334   @java.lang.Override
isInitialized()335   public final boolean isInitialized() {
336     byte isInitialized = memoizedIsInitialized;
337     if (isInitialized == 1) return true;
338     if (isInitialized == 0) return false;
339 
340     memoizedIsInitialized = 1;
341     return true;
342   }
343 
344   @java.lang.Override
writeTo(com.google.protobuf.CodedOutputStream output)345   public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
346     if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(imageUri_)) {
347       com.google.protobuf.GeneratedMessageV3.writeString(output, 1, imageUri_);
348     }
349     for (int i = 0; i < command_.size(); i++) {
350       com.google.protobuf.GeneratedMessageV3.writeString(output, 2, command_.getRaw(i));
351     }
352     for (int i = 0; i < args_.size(); i++) {
353       com.google.protobuf.GeneratedMessageV3.writeString(output, 3, args_.getRaw(i));
354     }
355     for (int i = 0; i < env_.size(); i++) {
356       output.writeMessage(4, env_.get(i));
357     }
358     getUnknownFields().writeTo(output);
359   }
360 
361   @java.lang.Override
getSerializedSize()362   public int getSerializedSize() {
363     int size = memoizedSize;
364     if (size != -1) return size;
365 
366     size = 0;
367     if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(imageUri_)) {
368       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, imageUri_);
369     }
370     {
371       int dataSize = 0;
372       for (int i = 0; i < command_.size(); i++) {
373         dataSize += computeStringSizeNoTag(command_.getRaw(i));
374       }
375       size += dataSize;
376       size += 1 * getCommandList().size();
377     }
378     {
379       int dataSize = 0;
380       for (int i = 0; i < args_.size(); i++) {
381         dataSize += computeStringSizeNoTag(args_.getRaw(i));
382       }
383       size += dataSize;
384       size += 1 * getArgsList().size();
385     }
386     for (int i = 0; i < env_.size(); i++) {
387       size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, env_.get(i));
388     }
389     size += getUnknownFields().getSerializedSize();
390     memoizedSize = size;
391     return size;
392   }
393 
394   @java.lang.Override
equals(final java.lang.Object obj)395   public boolean equals(final java.lang.Object obj) {
396     if (obj == this) {
397       return true;
398     }
399     if (!(obj instanceof com.google.cloud.aiplatform.v1.ContainerSpec)) {
400       return super.equals(obj);
401     }
402     com.google.cloud.aiplatform.v1.ContainerSpec other =
403         (com.google.cloud.aiplatform.v1.ContainerSpec) obj;
404 
405     if (!getImageUri().equals(other.getImageUri())) return false;
406     if (!getCommandList().equals(other.getCommandList())) return false;
407     if (!getArgsList().equals(other.getArgsList())) return false;
408     if (!getEnvList().equals(other.getEnvList())) return false;
409     if (!getUnknownFields().equals(other.getUnknownFields())) return false;
410     return true;
411   }
412 
413   @java.lang.Override
hashCode()414   public int hashCode() {
415     if (memoizedHashCode != 0) {
416       return memoizedHashCode;
417     }
418     int hash = 41;
419     hash = (19 * hash) + getDescriptor().hashCode();
420     hash = (37 * hash) + IMAGE_URI_FIELD_NUMBER;
421     hash = (53 * hash) + getImageUri().hashCode();
422     if (getCommandCount() > 0) {
423       hash = (37 * hash) + COMMAND_FIELD_NUMBER;
424       hash = (53 * hash) + getCommandList().hashCode();
425     }
426     if (getArgsCount() > 0) {
427       hash = (37 * hash) + ARGS_FIELD_NUMBER;
428       hash = (53 * hash) + getArgsList().hashCode();
429     }
430     if (getEnvCount() > 0) {
431       hash = (37 * hash) + ENV_FIELD_NUMBER;
432       hash = (53 * hash) + getEnvList().hashCode();
433     }
434     hash = (29 * hash) + getUnknownFields().hashCode();
435     memoizedHashCode = hash;
436     return hash;
437   }
438 
parseFrom(java.nio.ByteBuffer data)439   public static com.google.cloud.aiplatform.v1.ContainerSpec parseFrom(java.nio.ByteBuffer data)
440       throws com.google.protobuf.InvalidProtocolBufferException {
441     return PARSER.parseFrom(data);
442   }
443 
parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)444   public static com.google.cloud.aiplatform.v1.ContainerSpec parseFrom(
445       java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
446       throws com.google.protobuf.InvalidProtocolBufferException {
447     return PARSER.parseFrom(data, extensionRegistry);
448   }
449 
parseFrom( com.google.protobuf.ByteString data)450   public static com.google.cloud.aiplatform.v1.ContainerSpec parseFrom(
451       com.google.protobuf.ByteString data)
452       throws com.google.protobuf.InvalidProtocolBufferException {
453     return PARSER.parseFrom(data);
454   }
455 
parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)456   public static com.google.cloud.aiplatform.v1.ContainerSpec parseFrom(
457       com.google.protobuf.ByteString data,
458       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
459       throws com.google.protobuf.InvalidProtocolBufferException {
460     return PARSER.parseFrom(data, extensionRegistry);
461   }
462 
parseFrom(byte[] data)463   public static com.google.cloud.aiplatform.v1.ContainerSpec parseFrom(byte[] data)
464       throws com.google.protobuf.InvalidProtocolBufferException {
465     return PARSER.parseFrom(data);
466   }
467 
parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)468   public static com.google.cloud.aiplatform.v1.ContainerSpec parseFrom(
469       byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
470       throws com.google.protobuf.InvalidProtocolBufferException {
471     return PARSER.parseFrom(data, extensionRegistry);
472   }
473 
parseFrom(java.io.InputStream input)474   public static com.google.cloud.aiplatform.v1.ContainerSpec parseFrom(java.io.InputStream input)
475       throws java.io.IOException {
476     return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
477   }
478 
parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)479   public static com.google.cloud.aiplatform.v1.ContainerSpec parseFrom(
480       java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
481       throws java.io.IOException {
482     return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
483         PARSER, input, extensionRegistry);
484   }
485 
parseDelimitedFrom( java.io.InputStream input)486   public static com.google.cloud.aiplatform.v1.ContainerSpec parseDelimitedFrom(
487       java.io.InputStream input) throws java.io.IOException {
488     return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
489   }
490 
parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)491   public static com.google.cloud.aiplatform.v1.ContainerSpec parseDelimitedFrom(
492       java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
493       throws java.io.IOException {
494     return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
495         PARSER, input, extensionRegistry);
496   }
497 
parseFrom( com.google.protobuf.CodedInputStream input)498   public static com.google.cloud.aiplatform.v1.ContainerSpec parseFrom(
499       com.google.protobuf.CodedInputStream input) throws java.io.IOException {
500     return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
501   }
502 
parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)503   public static com.google.cloud.aiplatform.v1.ContainerSpec parseFrom(
504       com.google.protobuf.CodedInputStream input,
505       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
506       throws java.io.IOException {
507     return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
508         PARSER, input, extensionRegistry);
509   }
510 
511   @java.lang.Override
newBuilderForType()512   public Builder newBuilderForType() {
513     return newBuilder();
514   }
515 
newBuilder()516   public static Builder newBuilder() {
517     return DEFAULT_INSTANCE.toBuilder();
518   }
519 
newBuilder(com.google.cloud.aiplatform.v1.ContainerSpec prototype)520   public static Builder newBuilder(com.google.cloud.aiplatform.v1.ContainerSpec prototype) {
521     return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
522   }
523 
524   @java.lang.Override
toBuilder()525   public Builder toBuilder() {
526     return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
527   }
528 
529   @java.lang.Override
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)530   protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
531     Builder builder = new Builder(parent);
532     return builder;
533   }
534   /**
535    *
536    *
537    * <pre>
538    * The spec of a Container.
539    * </pre>
540    *
541    * Protobuf type {@code google.cloud.aiplatform.v1.ContainerSpec}
542    */
543   public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder>
544       implements
545       // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1.ContainerSpec)
546       com.google.cloud.aiplatform.v1.ContainerSpecOrBuilder {
getDescriptor()547     public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
548       return com.google.cloud.aiplatform.v1.CustomJobProto
549           .internal_static_google_cloud_aiplatform_v1_ContainerSpec_descriptor;
550     }
551 
552     @java.lang.Override
553     protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()554         internalGetFieldAccessorTable() {
555       return com.google.cloud.aiplatform.v1.CustomJobProto
556           .internal_static_google_cloud_aiplatform_v1_ContainerSpec_fieldAccessorTable
557           .ensureFieldAccessorsInitialized(
558               com.google.cloud.aiplatform.v1.ContainerSpec.class,
559               com.google.cloud.aiplatform.v1.ContainerSpec.Builder.class);
560     }
561 
562     // Construct using com.google.cloud.aiplatform.v1.ContainerSpec.newBuilder()
Builder()563     private Builder() {}
564 
Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)565     private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
566       super(parent);
567     }
568 
569     @java.lang.Override
clear()570     public Builder clear() {
571       super.clear();
572       bitField0_ = 0;
573       imageUri_ = "";
574       command_ = com.google.protobuf.LazyStringArrayList.EMPTY;
575       bitField0_ = (bitField0_ & ~0x00000002);
576       args_ = com.google.protobuf.LazyStringArrayList.EMPTY;
577       bitField0_ = (bitField0_ & ~0x00000004);
578       if (envBuilder_ == null) {
579         env_ = java.util.Collections.emptyList();
580       } else {
581         env_ = null;
582         envBuilder_.clear();
583       }
584       bitField0_ = (bitField0_ & ~0x00000008);
585       return this;
586     }
587 
588     @java.lang.Override
getDescriptorForType()589     public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
590       return com.google.cloud.aiplatform.v1.CustomJobProto
591           .internal_static_google_cloud_aiplatform_v1_ContainerSpec_descriptor;
592     }
593 
594     @java.lang.Override
getDefaultInstanceForType()595     public com.google.cloud.aiplatform.v1.ContainerSpec getDefaultInstanceForType() {
596       return com.google.cloud.aiplatform.v1.ContainerSpec.getDefaultInstance();
597     }
598 
599     @java.lang.Override
build()600     public com.google.cloud.aiplatform.v1.ContainerSpec build() {
601       com.google.cloud.aiplatform.v1.ContainerSpec result = buildPartial();
602       if (!result.isInitialized()) {
603         throw newUninitializedMessageException(result);
604       }
605       return result;
606     }
607 
608     @java.lang.Override
buildPartial()609     public com.google.cloud.aiplatform.v1.ContainerSpec buildPartial() {
610       com.google.cloud.aiplatform.v1.ContainerSpec result =
611           new com.google.cloud.aiplatform.v1.ContainerSpec(this);
612       buildPartialRepeatedFields(result);
613       if (bitField0_ != 0) {
614         buildPartial0(result);
615       }
616       onBuilt();
617       return result;
618     }
619 
buildPartialRepeatedFields(com.google.cloud.aiplatform.v1.ContainerSpec result)620     private void buildPartialRepeatedFields(com.google.cloud.aiplatform.v1.ContainerSpec result) {
621       if (((bitField0_ & 0x00000002) != 0)) {
622         command_ = command_.getUnmodifiableView();
623         bitField0_ = (bitField0_ & ~0x00000002);
624       }
625       result.command_ = command_;
626       if (((bitField0_ & 0x00000004) != 0)) {
627         args_ = args_.getUnmodifiableView();
628         bitField0_ = (bitField0_ & ~0x00000004);
629       }
630       result.args_ = args_;
631       if (envBuilder_ == null) {
632         if (((bitField0_ & 0x00000008) != 0)) {
633           env_ = java.util.Collections.unmodifiableList(env_);
634           bitField0_ = (bitField0_ & ~0x00000008);
635         }
636         result.env_ = env_;
637       } else {
638         result.env_ = envBuilder_.build();
639       }
640     }
641 
buildPartial0(com.google.cloud.aiplatform.v1.ContainerSpec result)642     private void buildPartial0(com.google.cloud.aiplatform.v1.ContainerSpec result) {
643       int from_bitField0_ = bitField0_;
644       if (((from_bitField0_ & 0x00000001) != 0)) {
645         result.imageUri_ = imageUri_;
646       }
647     }
648 
649     @java.lang.Override
clone()650     public Builder clone() {
651       return super.clone();
652     }
653 
654     @java.lang.Override
setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)655     public Builder setField(
656         com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
657       return super.setField(field, value);
658     }
659 
660     @java.lang.Override
clearField(com.google.protobuf.Descriptors.FieldDescriptor field)661     public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
662       return super.clearField(field);
663     }
664 
665     @java.lang.Override
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)666     public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
667       return super.clearOneof(oneof);
668     }
669 
670     @java.lang.Override
setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)671     public Builder setRepeatedField(
672         com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) {
673       return super.setRepeatedField(field, index, value);
674     }
675 
676     @java.lang.Override
addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)677     public Builder addRepeatedField(
678         com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
679       return super.addRepeatedField(field, value);
680     }
681 
682     @java.lang.Override
mergeFrom(com.google.protobuf.Message other)683     public Builder mergeFrom(com.google.protobuf.Message other) {
684       if (other instanceof com.google.cloud.aiplatform.v1.ContainerSpec) {
685         return mergeFrom((com.google.cloud.aiplatform.v1.ContainerSpec) other);
686       } else {
687         super.mergeFrom(other);
688         return this;
689       }
690     }
691 
mergeFrom(com.google.cloud.aiplatform.v1.ContainerSpec other)692     public Builder mergeFrom(com.google.cloud.aiplatform.v1.ContainerSpec other) {
693       if (other == com.google.cloud.aiplatform.v1.ContainerSpec.getDefaultInstance()) return this;
694       if (!other.getImageUri().isEmpty()) {
695         imageUri_ = other.imageUri_;
696         bitField0_ |= 0x00000001;
697         onChanged();
698       }
699       if (!other.command_.isEmpty()) {
700         if (command_.isEmpty()) {
701           command_ = other.command_;
702           bitField0_ = (bitField0_ & ~0x00000002);
703         } else {
704           ensureCommandIsMutable();
705           command_.addAll(other.command_);
706         }
707         onChanged();
708       }
709       if (!other.args_.isEmpty()) {
710         if (args_.isEmpty()) {
711           args_ = other.args_;
712           bitField0_ = (bitField0_ & ~0x00000004);
713         } else {
714           ensureArgsIsMutable();
715           args_.addAll(other.args_);
716         }
717         onChanged();
718       }
719       if (envBuilder_ == null) {
720         if (!other.env_.isEmpty()) {
721           if (env_.isEmpty()) {
722             env_ = other.env_;
723             bitField0_ = (bitField0_ & ~0x00000008);
724           } else {
725             ensureEnvIsMutable();
726             env_.addAll(other.env_);
727           }
728           onChanged();
729         }
730       } else {
731         if (!other.env_.isEmpty()) {
732           if (envBuilder_.isEmpty()) {
733             envBuilder_.dispose();
734             envBuilder_ = null;
735             env_ = other.env_;
736             bitField0_ = (bitField0_ & ~0x00000008);
737             envBuilder_ =
738                 com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders
739                     ? getEnvFieldBuilder()
740                     : null;
741           } else {
742             envBuilder_.addAllMessages(other.env_);
743           }
744         }
745       }
746       this.mergeUnknownFields(other.getUnknownFields());
747       onChanged();
748       return this;
749     }
750 
751     @java.lang.Override
isInitialized()752     public final boolean isInitialized() {
753       return true;
754     }
755 
756     @java.lang.Override
mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)757     public Builder mergeFrom(
758         com.google.protobuf.CodedInputStream input,
759         com.google.protobuf.ExtensionRegistryLite extensionRegistry)
760         throws java.io.IOException {
761       if (extensionRegistry == null) {
762         throw new java.lang.NullPointerException();
763       }
764       try {
765         boolean done = false;
766         while (!done) {
767           int tag = input.readTag();
768           switch (tag) {
769             case 0:
770               done = true;
771               break;
772             case 10:
773               {
774                 imageUri_ = input.readStringRequireUtf8();
775                 bitField0_ |= 0x00000001;
776                 break;
777               } // case 10
778             case 18:
779               {
780                 java.lang.String s = input.readStringRequireUtf8();
781                 ensureCommandIsMutable();
782                 command_.add(s);
783                 break;
784               } // case 18
785             case 26:
786               {
787                 java.lang.String s = input.readStringRequireUtf8();
788                 ensureArgsIsMutable();
789                 args_.add(s);
790                 break;
791               } // case 26
792             case 34:
793               {
794                 com.google.cloud.aiplatform.v1.EnvVar m =
795                     input.readMessage(
796                         com.google.cloud.aiplatform.v1.EnvVar.parser(), extensionRegistry);
797                 if (envBuilder_ == null) {
798                   ensureEnvIsMutable();
799                   env_.add(m);
800                 } else {
801                   envBuilder_.addMessage(m);
802                 }
803                 break;
804               } // case 34
805             default:
806               {
807                 if (!super.parseUnknownField(input, extensionRegistry, tag)) {
808                   done = true; // was an endgroup tag
809                 }
810                 break;
811               } // default:
812           } // switch (tag)
813         } // while (!done)
814       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
815         throw e.unwrapIOException();
816       } finally {
817         onChanged();
818       } // finally
819       return this;
820     }
821 
822     private int bitField0_;
823 
824     private java.lang.Object imageUri_ = "";
825     /**
826      *
827      *
828      * <pre>
829      * Required. The URI of a container image in the Container Registry that is to
830      * be run on each worker replica.
831      * </pre>
832      *
833      * <code>string image_uri = 1 [(.google.api.field_behavior) = REQUIRED];</code>
834      *
835      * @return The imageUri.
836      */
getImageUri()837     public java.lang.String getImageUri() {
838       java.lang.Object ref = imageUri_;
839       if (!(ref instanceof java.lang.String)) {
840         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
841         java.lang.String s = bs.toStringUtf8();
842         imageUri_ = s;
843         return s;
844       } else {
845         return (java.lang.String) ref;
846       }
847     }
848     /**
849      *
850      *
851      * <pre>
852      * Required. The URI of a container image in the Container Registry that is to
853      * be run on each worker replica.
854      * </pre>
855      *
856      * <code>string image_uri = 1 [(.google.api.field_behavior) = REQUIRED];</code>
857      *
858      * @return The bytes for imageUri.
859      */
getImageUriBytes()860     public com.google.protobuf.ByteString getImageUriBytes() {
861       java.lang.Object ref = imageUri_;
862       if (ref instanceof String) {
863         com.google.protobuf.ByteString b =
864             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
865         imageUri_ = b;
866         return b;
867       } else {
868         return (com.google.protobuf.ByteString) ref;
869       }
870     }
871     /**
872      *
873      *
874      * <pre>
875      * Required. The URI of a container image in the Container Registry that is to
876      * be run on each worker replica.
877      * </pre>
878      *
879      * <code>string image_uri = 1 [(.google.api.field_behavior) = REQUIRED];</code>
880      *
881      * @param value The imageUri to set.
882      * @return This builder for chaining.
883      */
setImageUri(java.lang.String value)884     public Builder setImageUri(java.lang.String value) {
885       if (value == null) {
886         throw new NullPointerException();
887       }
888       imageUri_ = value;
889       bitField0_ |= 0x00000001;
890       onChanged();
891       return this;
892     }
893     /**
894      *
895      *
896      * <pre>
897      * Required. The URI of a container image in the Container Registry that is to
898      * be run on each worker replica.
899      * </pre>
900      *
901      * <code>string image_uri = 1 [(.google.api.field_behavior) = REQUIRED];</code>
902      *
903      * @return This builder for chaining.
904      */
clearImageUri()905     public Builder clearImageUri() {
906       imageUri_ = getDefaultInstance().getImageUri();
907       bitField0_ = (bitField0_ & ~0x00000001);
908       onChanged();
909       return this;
910     }
911     /**
912      *
913      *
914      * <pre>
915      * Required. The URI of a container image in the Container Registry that is to
916      * be run on each worker replica.
917      * </pre>
918      *
919      * <code>string image_uri = 1 [(.google.api.field_behavior) = REQUIRED];</code>
920      *
921      * @param value The bytes for imageUri to set.
922      * @return This builder for chaining.
923      */
setImageUriBytes(com.google.protobuf.ByteString value)924     public Builder setImageUriBytes(com.google.protobuf.ByteString value) {
925       if (value == null) {
926         throw new NullPointerException();
927       }
928       checkByteStringIsUtf8(value);
929       imageUri_ = value;
930       bitField0_ |= 0x00000001;
931       onChanged();
932       return this;
933     }
934 
935     private com.google.protobuf.LazyStringList command_ =
936         com.google.protobuf.LazyStringArrayList.EMPTY;
937 
ensureCommandIsMutable()938     private void ensureCommandIsMutable() {
939       if (!((bitField0_ & 0x00000002) != 0)) {
940         command_ = new com.google.protobuf.LazyStringArrayList(command_);
941         bitField0_ |= 0x00000002;
942       }
943     }
944     /**
945      *
946      *
947      * <pre>
948      * The command to be invoked when the container is started.
949      * It overrides the entrypoint instruction in Dockerfile when provided.
950      * </pre>
951      *
952      * <code>repeated string command = 2;</code>
953      *
954      * @return A list containing the command.
955      */
getCommandList()956     public com.google.protobuf.ProtocolStringList getCommandList() {
957       return command_.getUnmodifiableView();
958     }
959     /**
960      *
961      *
962      * <pre>
963      * The command to be invoked when the container is started.
964      * It overrides the entrypoint instruction in Dockerfile when provided.
965      * </pre>
966      *
967      * <code>repeated string command = 2;</code>
968      *
969      * @return The count of command.
970      */
getCommandCount()971     public int getCommandCount() {
972       return command_.size();
973     }
974     /**
975      *
976      *
977      * <pre>
978      * The command to be invoked when the container is started.
979      * It overrides the entrypoint instruction in Dockerfile when provided.
980      * </pre>
981      *
982      * <code>repeated string command = 2;</code>
983      *
984      * @param index The index of the element to return.
985      * @return The command at the given index.
986      */
getCommand(int index)987     public java.lang.String getCommand(int index) {
988       return command_.get(index);
989     }
990     /**
991      *
992      *
993      * <pre>
994      * The command to be invoked when the container is started.
995      * It overrides the entrypoint instruction in Dockerfile when provided.
996      * </pre>
997      *
998      * <code>repeated string command = 2;</code>
999      *
1000      * @param index The index of the value to return.
1001      * @return The bytes of the command at the given index.
1002      */
getCommandBytes(int index)1003     public com.google.protobuf.ByteString getCommandBytes(int index) {
1004       return command_.getByteString(index);
1005     }
1006     /**
1007      *
1008      *
1009      * <pre>
1010      * The command to be invoked when the container is started.
1011      * It overrides the entrypoint instruction in Dockerfile when provided.
1012      * </pre>
1013      *
1014      * <code>repeated string command = 2;</code>
1015      *
1016      * @param index The index to set the value at.
1017      * @param value The command to set.
1018      * @return This builder for chaining.
1019      */
setCommand(int index, java.lang.String value)1020     public Builder setCommand(int index, java.lang.String value) {
1021       if (value == null) {
1022         throw new NullPointerException();
1023       }
1024       ensureCommandIsMutable();
1025       command_.set(index, value);
1026       onChanged();
1027       return this;
1028     }
1029     /**
1030      *
1031      *
1032      * <pre>
1033      * The command to be invoked when the container is started.
1034      * It overrides the entrypoint instruction in Dockerfile when provided.
1035      * </pre>
1036      *
1037      * <code>repeated string command = 2;</code>
1038      *
1039      * @param value The command to add.
1040      * @return This builder for chaining.
1041      */
addCommand(java.lang.String value)1042     public Builder addCommand(java.lang.String value) {
1043       if (value == null) {
1044         throw new NullPointerException();
1045       }
1046       ensureCommandIsMutable();
1047       command_.add(value);
1048       onChanged();
1049       return this;
1050     }
1051     /**
1052      *
1053      *
1054      * <pre>
1055      * The command to be invoked when the container is started.
1056      * It overrides the entrypoint instruction in Dockerfile when provided.
1057      * </pre>
1058      *
1059      * <code>repeated string command = 2;</code>
1060      *
1061      * @param values The command to add.
1062      * @return This builder for chaining.
1063      */
addAllCommand(java.lang.Iterable<java.lang.String> values)1064     public Builder addAllCommand(java.lang.Iterable<java.lang.String> values) {
1065       ensureCommandIsMutable();
1066       com.google.protobuf.AbstractMessageLite.Builder.addAll(values, command_);
1067       onChanged();
1068       return this;
1069     }
1070     /**
1071      *
1072      *
1073      * <pre>
1074      * The command to be invoked when the container is started.
1075      * It overrides the entrypoint instruction in Dockerfile when provided.
1076      * </pre>
1077      *
1078      * <code>repeated string command = 2;</code>
1079      *
1080      * @return This builder for chaining.
1081      */
clearCommand()1082     public Builder clearCommand() {
1083       command_ = com.google.protobuf.LazyStringArrayList.EMPTY;
1084       bitField0_ = (bitField0_ & ~0x00000002);
1085       onChanged();
1086       return this;
1087     }
1088     /**
1089      *
1090      *
1091      * <pre>
1092      * The command to be invoked when the container is started.
1093      * It overrides the entrypoint instruction in Dockerfile when provided.
1094      * </pre>
1095      *
1096      * <code>repeated string command = 2;</code>
1097      *
1098      * @param value The bytes of the command to add.
1099      * @return This builder for chaining.
1100      */
addCommandBytes(com.google.protobuf.ByteString value)1101     public Builder addCommandBytes(com.google.protobuf.ByteString value) {
1102       if (value == null) {
1103         throw new NullPointerException();
1104       }
1105       checkByteStringIsUtf8(value);
1106       ensureCommandIsMutable();
1107       command_.add(value);
1108       onChanged();
1109       return this;
1110     }
1111 
1112     private com.google.protobuf.LazyStringList args_ =
1113         com.google.protobuf.LazyStringArrayList.EMPTY;
1114 
ensureArgsIsMutable()1115     private void ensureArgsIsMutable() {
1116       if (!((bitField0_ & 0x00000004) != 0)) {
1117         args_ = new com.google.protobuf.LazyStringArrayList(args_);
1118         bitField0_ |= 0x00000004;
1119       }
1120     }
1121     /**
1122      *
1123      *
1124      * <pre>
1125      * The arguments to be passed when starting the container.
1126      * </pre>
1127      *
1128      * <code>repeated string args = 3;</code>
1129      *
1130      * @return A list containing the args.
1131      */
getArgsList()1132     public com.google.protobuf.ProtocolStringList getArgsList() {
1133       return args_.getUnmodifiableView();
1134     }
1135     /**
1136      *
1137      *
1138      * <pre>
1139      * The arguments to be passed when starting the container.
1140      * </pre>
1141      *
1142      * <code>repeated string args = 3;</code>
1143      *
1144      * @return The count of args.
1145      */
getArgsCount()1146     public int getArgsCount() {
1147       return args_.size();
1148     }
1149     /**
1150      *
1151      *
1152      * <pre>
1153      * The arguments to be passed when starting the container.
1154      * </pre>
1155      *
1156      * <code>repeated string args = 3;</code>
1157      *
1158      * @param index The index of the element to return.
1159      * @return The args at the given index.
1160      */
getArgs(int index)1161     public java.lang.String getArgs(int index) {
1162       return args_.get(index);
1163     }
1164     /**
1165      *
1166      *
1167      * <pre>
1168      * The arguments to be passed when starting the container.
1169      * </pre>
1170      *
1171      * <code>repeated string args = 3;</code>
1172      *
1173      * @param index The index of the value to return.
1174      * @return The bytes of the args at the given index.
1175      */
getArgsBytes(int index)1176     public com.google.protobuf.ByteString getArgsBytes(int index) {
1177       return args_.getByteString(index);
1178     }
1179     /**
1180      *
1181      *
1182      * <pre>
1183      * The arguments to be passed when starting the container.
1184      * </pre>
1185      *
1186      * <code>repeated string args = 3;</code>
1187      *
1188      * @param index The index to set the value at.
1189      * @param value The args to set.
1190      * @return This builder for chaining.
1191      */
setArgs(int index, java.lang.String value)1192     public Builder setArgs(int index, java.lang.String value) {
1193       if (value == null) {
1194         throw new NullPointerException();
1195       }
1196       ensureArgsIsMutable();
1197       args_.set(index, value);
1198       onChanged();
1199       return this;
1200     }
1201     /**
1202      *
1203      *
1204      * <pre>
1205      * The arguments to be passed when starting the container.
1206      * </pre>
1207      *
1208      * <code>repeated string args = 3;</code>
1209      *
1210      * @param value The args to add.
1211      * @return This builder for chaining.
1212      */
addArgs(java.lang.String value)1213     public Builder addArgs(java.lang.String value) {
1214       if (value == null) {
1215         throw new NullPointerException();
1216       }
1217       ensureArgsIsMutable();
1218       args_.add(value);
1219       onChanged();
1220       return this;
1221     }
1222     /**
1223      *
1224      *
1225      * <pre>
1226      * The arguments to be passed when starting the container.
1227      * </pre>
1228      *
1229      * <code>repeated string args = 3;</code>
1230      *
1231      * @param values The args to add.
1232      * @return This builder for chaining.
1233      */
addAllArgs(java.lang.Iterable<java.lang.String> values)1234     public Builder addAllArgs(java.lang.Iterable<java.lang.String> values) {
1235       ensureArgsIsMutable();
1236       com.google.protobuf.AbstractMessageLite.Builder.addAll(values, args_);
1237       onChanged();
1238       return this;
1239     }
1240     /**
1241      *
1242      *
1243      * <pre>
1244      * The arguments to be passed when starting the container.
1245      * </pre>
1246      *
1247      * <code>repeated string args = 3;</code>
1248      *
1249      * @return This builder for chaining.
1250      */
clearArgs()1251     public Builder clearArgs() {
1252       args_ = com.google.protobuf.LazyStringArrayList.EMPTY;
1253       bitField0_ = (bitField0_ & ~0x00000004);
1254       onChanged();
1255       return this;
1256     }
1257     /**
1258      *
1259      *
1260      * <pre>
1261      * The arguments to be passed when starting the container.
1262      * </pre>
1263      *
1264      * <code>repeated string args = 3;</code>
1265      *
1266      * @param value The bytes of the args to add.
1267      * @return This builder for chaining.
1268      */
addArgsBytes(com.google.protobuf.ByteString value)1269     public Builder addArgsBytes(com.google.protobuf.ByteString value) {
1270       if (value == null) {
1271         throw new NullPointerException();
1272       }
1273       checkByteStringIsUtf8(value);
1274       ensureArgsIsMutable();
1275       args_.add(value);
1276       onChanged();
1277       return this;
1278     }
1279 
1280     private java.util.List<com.google.cloud.aiplatform.v1.EnvVar> env_ =
1281         java.util.Collections.emptyList();
1282 
ensureEnvIsMutable()1283     private void ensureEnvIsMutable() {
1284       if (!((bitField0_ & 0x00000008) != 0)) {
1285         env_ = new java.util.ArrayList<com.google.cloud.aiplatform.v1.EnvVar>(env_);
1286         bitField0_ |= 0x00000008;
1287       }
1288     }
1289 
1290     private com.google.protobuf.RepeatedFieldBuilderV3<
1291             com.google.cloud.aiplatform.v1.EnvVar,
1292             com.google.cloud.aiplatform.v1.EnvVar.Builder,
1293             com.google.cloud.aiplatform.v1.EnvVarOrBuilder>
1294         envBuilder_;
1295 
1296     /**
1297      *
1298      *
1299      * <pre>
1300      * Environment variables to be passed to the container.
1301      * Maximum limit is 100.
1302      * </pre>
1303      *
1304      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1305      */
getEnvList()1306     public java.util.List<com.google.cloud.aiplatform.v1.EnvVar> getEnvList() {
1307       if (envBuilder_ == null) {
1308         return java.util.Collections.unmodifiableList(env_);
1309       } else {
1310         return envBuilder_.getMessageList();
1311       }
1312     }
1313     /**
1314      *
1315      *
1316      * <pre>
1317      * Environment variables to be passed to the container.
1318      * Maximum limit is 100.
1319      * </pre>
1320      *
1321      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1322      */
getEnvCount()1323     public int getEnvCount() {
1324       if (envBuilder_ == null) {
1325         return env_.size();
1326       } else {
1327         return envBuilder_.getCount();
1328       }
1329     }
1330     /**
1331      *
1332      *
1333      * <pre>
1334      * Environment variables to be passed to the container.
1335      * Maximum limit is 100.
1336      * </pre>
1337      *
1338      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1339      */
getEnv(int index)1340     public com.google.cloud.aiplatform.v1.EnvVar getEnv(int index) {
1341       if (envBuilder_ == null) {
1342         return env_.get(index);
1343       } else {
1344         return envBuilder_.getMessage(index);
1345       }
1346     }
1347     /**
1348      *
1349      *
1350      * <pre>
1351      * Environment variables to be passed to the container.
1352      * Maximum limit is 100.
1353      * </pre>
1354      *
1355      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1356      */
setEnv(int index, com.google.cloud.aiplatform.v1.EnvVar value)1357     public Builder setEnv(int index, com.google.cloud.aiplatform.v1.EnvVar value) {
1358       if (envBuilder_ == null) {
1359         if (value == null) {
1360           throw new NullPointerException();
1361         }
1362         ensureEnvIsMutable();
1363         env_.set(index, value);
1364         onChanged();
1365       } else {
1366         envBuilder_.setMessage(index, value);
1367       }
1368       return this;
1369     }
1370     /**
1371      *
1372      *
1373      * <pre>
1374      * Environment variables to be passed to the container.
1375      * Maximum limit is 100.
1376      * </pre>
1377      *
1378      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1379      */
setEnv( int index, com.google.cloud.aiplatform.v1.EnvVar.Builder builderForValue)1380     public Builder setEnv(
1381         int index, com.google.cloud.aiplatform.v1.EnvVar.Builder builderForValue) {
1382       if (envBuilder_ == null) {
1383         ensureEnvIsMutable();
1384         env_.set(index, builderForValue.build());
1385         onChanged();
1386       } else {
1387         envBuilder_.setMessage(index, builderForValue.build());
1388       }
1389       return this;
1390     }
1391     /**
1392      *
1393      *
1394      * <pre>
1395      * Environment variables to be passed to the container.
1396      * Maximum limit is 100.
1397      * </pre>
1398      *
1399      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1400      */
addEnv(com.google.cloud.aiplatform.v1.EnvVar value)1401     public Builder addEnv(com.google.cloud.aiplatform.v1.EnvVar value) {
1402       if (envBuilder_ == null) {
1403         if (value == null) {
1404           throw new NullPointerException();
1405         }
1406         ensureEnvIsMutable();
1407         env_.add(value);
1408         onChanged();
1409       } else {
1410         envBuilder_.addMessage(value);
1411       }
1412       return this;
1413     }
1414     /**
1415      *
1416      *
1417      * <pre>
1418      * Environment variables to be passed to the container.
1419      * Maximum limit is 100.
1420      * </pre>
1421      *
1422      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1423      */
addEnv(int index, com.google.cloud.aiplatform.v1.EnvVar value)1424     public Builder addEnv(int index, com.google.cloud.aiplatform.v1.EnvVar value) {
1425       if (envBuilder_ == null) {
1426         if (value == null) {
1427           throw new NullPointerException();
1428         }
1429         ensureEnvIsMutable();
1430         env_.add(index, value);
1431         onChanged();
1432       } else {
1433         envBuilder_.addMessage(index, value);
1434       }
1435       return this;
1436     }
1437     /**
1438      *
1439      *
1440      * <pre>
1441      * Environment variables to be passed to the container.
1442      * Maximum limit is 100.
1443      * </pre>
1444      *
1445      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1446      */
addEnv(com.google.cloud.aiplatform.v1.EnvVar.Builder builderForValue)1447     public Builder addEnv(com.google.cloud.aiplatform.v1.EnvVar.Builder builderForValue) {
1448       if (envBuilder_ == null) {
1449         ensureEnvIsMutable();
1450         env_.add(builderForValue.build());
1451         onChanged();
1452       } else {
1453         envBuilder_.addMessage(builderForValue.build());
1454       }
1455       return this;
1456     }
1457     /**
1458      *
1459      *
1460      * <pre>
1461      * Environment variables to be passed to the container.
1462      * Maximum limit is 100.
1463      * </pre>
1464      *
1465      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1466      */
addEnv( int index, com.google.cloud.aiplatform.v1.EnvVar.Builder builderForValue)1467     public Builder addEnv(
1468         int index, com.google.cloud.aiplatform.v1.EnvVar.Builder builderForValue) {
1469       if (envBuilder_ == null) {
1470         ensureEnvIsMutable();
1471         env_.add(index, builderForValue.build());
1472         onChanged();
1473       } else {
1474         envBuilder_.addMessage(index, builderForValue.build());
1475       }
1476       return this;
1477     }
1478     /**
1479      *
1480      *
1481      * <pre>
1482      * Environment variables to be passed to the container.
1483      * Maximum limit is 100.
1484      * </pre>
1485      *
1486      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1487      */
addAllEnv( java.lang.Iterable<? extends com.google.cloud.aiplatform.v1.EnvVar> values)1488     public Builder addAllEnv(
1489         java.lang.Iterable<? extends com.google.cloud.aiplatform.v1.EnvVar> values) {
1490       if (envBuilder_ == null) {
1491         ensureEnvIsMutable();
1492         com.google.protobuf.AbstractMessageLite.Builder.addAll(values, env_);
1493         onChanged();
1494       } else {
1495         envBuilder_.addAllMessages(values);
1496       }
1497       return this;
1498     }
1499     /**
1500      *
1501      *
1502      * <pre>
1503      * Environment variables to be passed to the container.
1504      * Maximum limit is 100.
1505      * </pre>
1506      *
1507      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1508      */
clearEnv()1509     public Builder clearEnv() {
1510       if (envBuilder_ == null) {
1511         env_ = java.util.Collections.emptyList();
1512         bitField0_ = (bitField0_ & ~0x00000008);
1513         onChanged();
1514       } else {
1515         envBuilder_.clear();
1516       }
1517       return this;
1518     }
1519     /**
1520      *
1521      *
1522      * <pre>
1523      * Environment variables to be passed to the container.
1524      * Maximum limit is 100.
1525      * </pre>
1526      *
1527      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1528      */
removeEnv(int index)1529     public Builder removeEnv(int index) {
1530       if (envBuilder_ == null) {
1531         ensureEnvIsMutable();
1532         env_.remove(index);
1533         onChanged();
1534       } else {
1535         envBuilder_.remove(index);
1536       }
1537       return this;
1538     }
1539     /**
1540      *
1541      *
1542      * <pre>
1543      * Environment variables to be passed to the container.
1544      * Maximum limit is 100.
1545      * </pre>
1546      *
1547      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1548      */
getEnvBuilder(int index)1549     public com.google.cloud.aiplatform.v1.EnvVar.Builder getEnvBuilder(int index) {
1550       return getEnvFieldBuilder().getBuilder(index);
1551     }
1552     /**
1553      *
1554      *
1555      * <pre>
1556      * Environment variables to be passed to the container.
1557      * Maximum limit is 100.
1558      * </pre>
1559      *
1560      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1561      */
getEnvOrBuilder(int index)1562     public com.google.cloud.aiplatform.v1.EnvVarOrBuilder getEnvOrBuilder(int index) {
1563       if (envBuilder_ == null) {
1564         return env_.get(index);
1565       } else {
1566         return envBuilder_.getMessageOrBuilder(index);
1567       }
1568     }
1569     /**
1570      *
1571      *
1572      * <pre>
1573      * Environment variables to be passed to the container.
1574      * Maximum limit is 100.
1575      * </pre>
1576      *
1577      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1578      */
1579     public java.util.List<? extends com.google.cloud.aiplatform.v1.EnvVarOrBuilder>
getEnvOrBuilderList()1580         getEnvOrBuilderList() {
1581       if (envBuilder_ != null) {
1582         return envBuilder_.getMessageOrBuilderList();
1583       } else {
1584         return java.util.Collections.unmodifiableList(env_);
1585       }
1586     }
1587     /**
1588      *
1589      *
1590      * <pre>
1591      * Environment variables to be passed to the container.
1592      * Maximum limit is 100.
1593      * </pre>
1594      *
1595      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1596      */
addEnvBuilder()1597     public com.google.cloud.aiplatform.v1.EnvVar.Builder addEnvBuilder() {
1598       return getEnvFieldBuilder()
1599           .addBuilder(com.google.cloud.aiplatform.v1.EnvVar.getDefaultInstance());
1600     }
1601     /**
1602      *
1603      *
1604      * <pre>
1605      * Environment variables to be passed to the container.
1606      * Maximum limit is 100.
1607      * </pre>
1608      *
1609      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1610      */
addEnvBuilder(int index)1611     public com.google.cloud.aiplatform.v1.EnvVar.Builder addEnvBuilder(int index) {
1612       return getEnvFieldBuilder()
1613           .addBuilder(index, com.google.cloud.aiplatform.v1.EnvVar.getDefaultInstance());
1614     }
1615     /**
1616      *
1617      *
1618      * <pre>
1619      * Environment variables to be passed to the container.
1620      * Maximum limit is 100.
1621      * </pre>
1622      *
1623      * <code>repeated .google.cloud.aiplatform.v1.EnvVar env = 4;</code>
1624      */
getEnvBuilderList()1625     public java.util.List<com.google.cloud.aiplatform.v1.EnvVar.Builder> getEnvBuilderList() {
1626       return getEnvFieldBuilder().getBuilderList();
1627     }
1628 
1629     private com.google.protobuf.RepeatedFieldBuilderV3<
1630             com.google.cloud.aiplatform.v1.EnvVar,
1631             com.google.cloud.aiplatform.v1.EnvVar.Builder,
1632             com.google.cloud.aiplatform.v1.EnvVarOrBuilder>
getEnvFieldBuilder()1633         getEnvFieldBuilder() {
1634       if (envBuilder_ == null) {
1635         envBuilder_ =
1636             new com.google.protobuf.RepeatedFieldBuilderV3<
1637                 com.google.cloud.aiplatform.v1.EnvVar,
1638                 com.google.cloud.aiplatform.v1.EnvVar.Builder,
1639                 com.google.cloud.aiplatform.v1.EnvVarOrBuilder>(
1640                 env_, ((bitField0_ & 0x00000008) != 0), getParentForChildren(), isClean());
1641         env_ = null;
1642       }
1643       return envBuilder_;
1644     }
1645 
1646     @java.lang.Override
setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields)1647     public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
1648       return super.setUnknownFields(unknownFields);
1649     }
1650 
1651     @java.lang.Override
mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields)1652     public final Builder mergeUnknownFields(
1653         final com.google.protobuf.UnknownFieldSet unknownFields) {
1654       return super.mergeUnknownFields(unknownFields);
1655     }
1656 
1657     // @@protoc_insertion_point(builder_scope:google.cloud.aiplatform.v1.ContainerSpec)
1658   }
1659 
1660   // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1.ContainerSpec)
1661   private static final com.google.cloud.aiplatform.v1.ContainerSpec DEFAULT_INSTANCE;
1662 
1663   static {
1664     DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1.ContainerSpec();
1665   }
1666 
getDefaultInstance()1667   public static com.google.cloud.aiplatform.v1.ContainerSpec getDefaultInstance() {
1668     return DEFAULT_INSTANCE;
1669   }
1670 
1671   private static final com.google.protobuf.Parser<ContainerSpec> PARSER =
1672       new com.google.protobuf.AbstractParser<ContainerSpec>() {
1673         @java.lang.Override
1674         public ContainerSpec parsePartialFrom(
1675             com.google.protobuf.CodedInputStream input,
1676             com.google.protobuf.ExtensionRegistryLite extensionRegistry)
1677             throws com.google.protobuf.InvalidProtocolBufferException {
1678           Builder builder = newBuilder();
1679           try {
1680             builder.mergeFrom(input, extensionRegistry);
1681           } catch (com.google.protobuf.InvalidProtocolBufferException e) {
1682             throw e.setUnfinishedMessage(builder.buildPartial());
1683           } catch (com.google.protobuf.UninitializedMessageException e) {
1684             throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
1685           } catch (java.io.IOException e) {
1686             throw new com.google.protobuf.InvalidProtocolBufferException(e)
1687                 .setUnfinishedMessage(builder.buildPartial());
1688           }
1689           return builder.buildPartial();
1690         }
1691       };
1692 
parser()1693   public static com.google.protobuf.Parser<ContainerSpec> parser() {
1694     return PARSER;
1695   }
1696 
1697   @java.lang.Override
getParserForType()1698   public com.google.protobuf.Parser<ContainerSpec> getParserForType() {
1699     return PARSER;
1700   }
1701 
1702   @java.lang.Override
getDefaultInstanceForType()1703   public com.google.cloud.aiplatform.v1.ContainerSpec getDefaultInstanceForType() {
1704     return DEFAULT_INSTANCE;
1705   }
1706 }
1707