• 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/privacy/dlp/v2/storage.proto
18 
19 package com.google.privacy.dlp.v2;
20 
21 /**
22  *
23  *
24  * <pre>
25  * A unique identifier for a Datastore entity.
26  * If a key's partition ID or any of its path kinds or names are
27  * reserved/read-only, the key is reserved/read-only.
28  * A reserved/read-only key is forbidden in certain documented contexts.
29  * </pre>
30  *
31  * Protobuf type {@code google.privacy.dlp.v2.Key}
32  */
33 public final class Key extends com.google.protobuf.GeneratedMessageV3
34     implements
35     // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2.Key)
36     KeyOrBuilder {
37   private static final long serialVersionUID = 0L;
38   // Use Key.newBuilder() to construct.
Key(com.google.protobuf.GeneratedMessageV3.Builder<?> builder)39   private Key(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
40     super(builder);
41   }
42 
Key()43   private Key() {
44     path_ = 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 Key();
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.privacy.dlp.v2.DlpStorage
60         .internal_static_google_privacy_dlp_v2_Key_descriptor;
61   }
62 
63   @java.lang.Override
64   protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()65       internalGetFieldAccessorTable() {
66     return com.google.privacy.dlp.v2.DlpStorage
67         .internal_static_google_privacy_dlp_v2_Key_fieldAccessorTable
68         .ensureFieldAccessorsInitialized(
69             com.google.privacy.dlp.v2.Key.class, com.google.privacy.dlp.v2.Key.Builder.class);
70   }
71 
72   public interface PathElementOrBuilder
73       extends
74       // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2.Key.PathElement)
75       com.google.protobuf.MessageOrBuilder {
76 
77     /**
78      *
79      *
80      * <pre>
81      * The kind of the entity.
82      * A kind matching regex `__.*__` is reserved/read-only.
83      * A kind must not contain more than 1500 bytes when UTF-8 encoded.
84      * Cannot be `""`.
85      * </pre>
86      *
87      * <code>string kind = 1;</code>
88      *
89      * @return The kind.
90      */
getKind()91     java.lang.String getKind();
92     /**
93      *
94      *
95      * <pre>
96      * The kind of the entity.
97      * A kind matching regex `__.*__` is reserved/read-only.
98      * A kind must not contain more than 1500 bytes when UTF-8 encoded.
99      * Cannot be `""`.
100      * </pre>
101      *
102      * <code>string kind = 1;</code>
103      *
104      * @return The bytes for kind.
105      */
getKindBytes()106     com.google.protobuf.ByteString getKindBytes();
107 
108     /**
109      *
110      *
111      * <pre>
112      * The auto-allocated ID of the entity.
113      * Never equal to zero. Values less than zero are discouraged and may not
114      * be supported in the future.
115      * </pre>
116      *
117      * <code>int64 id = 2;</code>
118      *
119      * @return Whether the id field is set.
120      */
hasId()121     boolean hasId();
122     /**
123      *
124      *
125      * <pre>
126      * The auto-allocated ID of the entity.
127      * Never equal to zero. Values less than zero are discouraged and may not
128      * be supported in the future.
129      * </pre>
130      *
131      * <code>int64 id = 2;</code>
132      *
133      * @return The id.
134      */
getId()135     long getId();
136 
137     /**
138      *
139      *
140      * <pre>
141      * The name of the entity.
142      * A name matching regex `__.*__` is reserved/read-only.
143      * A name must not be more than 1500 bytes when UTF-8 encoded.
144      * Cannot be `""`.
145      * </pre>
146      *
147      * <code>string name = 3;</code>
148      *
149      * @return Whether the name field is set.
150      */
hasName()151     boolean hasName();
152     /**
153      *
154      *
155      * <pre>
156      * The name of the entity.
157      * A name matching regex `__.*__` is reserved/read-only.
158      * A name must not be more than 1500 bytes when UTF-8 encoded.
159      * Cannot be `""`.
160      * </pre>
161      *
162      * <code>string name = 3;</code>
163      *
164      * @return The name.
165      */
getName()166     java.lang.String getName();
167     /**
168      *
169      *
170      * <pre>
171      * The name of the entity.
172      * A name matching regex `__.*__` is reserved/read-only.
173      * A name must not be more than 1500 bytes when UTF-8 encoded.
174      * Cannot be `""`.
175      * </pre>
176      *
177      * <code>string name = 3;</code>
178      *
179      * @return The bytes for name.
180      */
getNameBytes()181     com.google.protobuf.ByteString getNameBytes();
182 
getIdTypeCase()183     public com.google.privacy.dlp.v2.Key.PathElement.IdTypeCase getIdTypeCase();
184   }
185   /**
186    *
187    *
188    * <pre>
189    * A (kind, ID/name) pair used to construct a key path.
190    * If either name or ID is set, the element is complete.
191    * If neither is set, the element is incomplete.
192    * </pre>
193    *
194    * Protobuf type {@code google.privacy.dlp.v2.Key.PathElement}
195    */
196   public static final class PathElement extends com.google.protobuf.GeneratedMessageV3
197       implements
198       // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2.Key.PathElement)
199       PathElementOrBuilder {
200     private static final long serialVersionUID = 0L;
201     // Use PathElement.newBuilder() to construct.
PathElement(com.google.protobuf.GeneratedMessageV3.Builder<?> builder)202     private PathElement(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
203       super(builder);
204     }
205 
PathElement()206     private PathElement() {
207       kind_ = "";
208     }
209 
210     @java.lang.Override
211     @SuppressWarnings({"unused"})
newInstance(UnusedPrivateParameter unused)212     protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
213       return new PathElement();
214     }
215 
216     @java.lang.Override
getUnknownFields()217     public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
218       return this.unknownFields;
219     }
220 
getDescriptor()221     public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
222       return com.google.privacy.dlp.v2.DlpStorage
223           .internal_static_google_privacy_dlp_v2_Key_PathElement_descriptor;
224     }
225 
226     @java.lang.Override
227     protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()228         internalGetFieldAccessorTable() {
229       return com.google.privacy.dlp.v2.DlpStorage
230           .internal_static_google_privacy_dlp_v2_Key_PathElement_fieldAccessorTable
231           .ensureFieldAccessorsInitialized(
232               com.google.privacy.dlp.v2.Key.PathElement.class,
233               com.google.privacy.dlp.v2.Key.PathElement.Builder.class);
234     }
235 
236     private int idTypeCase_ = 0;
237     private java.lang.Object idType_;
238 
239     public enum IdTypeCase
240         implements
241             com.google.protobuf.Internal.EnumLite,
242             com.google.protobuf.AbstractMessage.InternalOneOfEnum {
243       ID(2),
244       NAME(3),
245       IDTYPE_NOT_SET(0);
246       private final int value;
247 
IdTypeCase(int value)248       private IdTypeCase(int value) {
249         this.value = value;
250       }
251       /**
252        * @param value The number of the enum to look for.
253        * @return The enum associated with the given number.
254        * @deprecated Use {@link #forNumber(int)} instead.
255        */
256       @java.lang.Deprecated
valueOf(int value)257       public static IdTypeCase valueOf(int value) {
258         return forNumber(value);
259       }
260 
forNumber(int value)261       public static IdTypeCase forNumber(int value) {
262         switch (value) {
263           case 2:
264             return ID;
265           case 3:
266             return NAME;
267           case 0:
268             return IDTYPE_NOT_SET;
269           default:
270             return null;
271         }
272       }
273 
getNumber()274       public int getNumber() {
275         return this.value;
276       }
277     };
278 
getIdTypeCase()279     public IdTypeCase getIdTypeCase() {
280       return IdTypeCase.forNumber(idTypeCase_);
281     }
282 
283     public static final int KIND_FIELD_NUMBER = 1;
284 
285     @SuppressWarnings("serial")
286     private volatile java.lang.Object kind_ = "";
287     /**
288      *
289      *
290      * <pre>
291      * The kind of the entity.
292      * A kind matching regex `__.*__` is reserved/read-only.
293      * A kind must not contain more than 1500 bytes when UTF-8 encoded.
294      * Cannot be `""`.
295      * </pre>
296      *
297      * <code>string kind = 1;</code>
298      *
299      * @return The kind.
300      */
301     @java.lang.Override
getKind()302     public java.lang.String getKind() {
303       java.lang.Object ref = kind_;
304       if (ref instanceof java.lang.String) {
305         return (java.lang.String) ref;
306       } else {
307         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
308         java.lang.String s = bs.toStringUtf8();
309         kind_ = s;
310         return s;
311       }
312     }
313     /**
314      *
315      *
316      * <pre>
317      * The kind of the entity.
318      * A kind matching regex `__.*__` is reserved/read-only.
319      * A kind must not contain more than 1500 bytes when UTF-8 encoded.
320      * Cannot be `""`.
321      * </pre>
322      *
323      * <code>string kind = 1;</code>
324      *
325      * @return The bytes for kind.
326      */
327     @java.lang.Override
getKindBytes()328     public com.google.protobuf.ByteString getKindBytes() {
329       java.lang.Object ref = kind_;
330       if (ref instanceof java.lang.String) {
331         com.google.protobuf.ByteString b =
332             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
333         kind_ = b;
334         return b;
335       } else {
336         return (com.google.protobuf.ByteString) ref;
337       }
338     }
339 
340     public static final int ID_FIELD_NUMBER = 2;
341     /**
342      *
343      *
344      * <pre>
345      * The auto-allocated ID of the entity.
346      * Never equal to zero. Values less than zero are discouraged and may not
347      * be supported in the future.
348      * </pre>
349      *
350      * <code>int64 id = 2;</code>
351      *
352      * @return Whether the id field is set.
353      */
354     @java.lang.Override
hasId()355     public boolean hasId() {
356       return idTypeCase_ == 2;
357     }
358     /**
359      *
360      *
361      * <pre>
362      * The auto-allocated ID of the entity.
363      * Never equal to zero. Values less than zero are discouraged and may not
364      * be supported in the future.
365      * </pre>
366      *
367      * <code>int64 id = 2;</code>
368      *
369      * @return The id.
370      */
371     @java.lang.Override
getId()372     public long getId() {
373       if (idTypeCase_ == 2) {
374         return (java.lang.Long) idType_;
375       }
376       return 0L;
377     }
378 
379     public static final int NAME_FIELD_NUMBER = 3;
380     /**
381      *
382      *
383      * <pre>
384      * The name of the entity.
385      * A name matching regex `__.*__` is reserved/read-only.
386      * A name must not be more than 1500 bytes when UTF-8 encoded.
387      * Cannot be `""`.
388      * </pre>
389      *
390      * <code>string name = 3;</code>
391      *
392      * @return Whether the name field is set.
393      */
hasName()394     public boolean hasName() {
395       return idTypeCase_ == 3;
396     }
397     /**
398      *
399      *
400      * <pre>
401      * The name of the entity.
402      * A name matching regex `__.*__` is reserved/read-only.
403      * A name must not be more than 1500 bytes when UTF-8 encoded.
404      * Cannot be `""`.
405      * </pre>
406      *
407      * <code>string name = 3;</code>
408      *
409      * @return The name.
410      */
getName()411     public java.lang.String getName() {
412       java.lang.Object ref = "";
413       if (idTypeCase_ == 3) {
414         ref = idType_;
415       }
416       if (ref instanceof java.lang.String) {
417         return (java.lang.String) ref;
418       } else {
419         com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
420         java.lang.String s = bs.toStringUtf8();
421         if (idTypeCase_ == 3) {
422           idType_ = s;
423         }
424         return s;
425       }
426     }
427     /**
428      *
429      *
430      * <pre>
431      * The name of the entity.
432      * A name matching regex `__.*__` is reserved/read-only.
433      * A name must not be more than 1500 bytes when UTF-8 encoded.
434      * Cannot be `""`.
435      * </pre>
436      *
437      * <code>string name = 3;</code>
438      *
439      * @return The bytes for name.
440      */
getNameBytes()441     public com.google.protobuf.ByteString getNameBytes() {
442       java.lang.Object ref = "";
443       if (idTypeCase_ == 3) {
444         ref = idType_;
445       }
446       if (ref instanceof java.lang.String) {
447         com.google.protobuf.ByteString b =
448             com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
449         if (idTypeCase_ == 3) {
450           idType_ = b;
451         }
452         return b;
453       } else {
454         return (com.google.protobuf.ByteString) ref;
455       }
456     }
457 
458     private byte memoizedIsInitialized = -1;
459 
460     @java.lang.Override
isInitialized()461     public final boolean isInitialized() {
462       byte isInitialized = memoizedIsInitialized;
463       if (isInitialized == 1) return true;
464       if (isInitialized == 0) return false;
465 
466       memoizedIsInitialized = 1;
467       return true;
468     }
469 
470     @java.lang.Override
writeTo(com.google.protobuf.CodedOutputStream output)471     public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
472       if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kind_)) {
473         com.google.protobuf.GeneratedMessageV3.writeString(output, 1, kind_);
474       }
475       if (idTypeCase_ == 2) {
476         output.writeInt64(2, (long) ((java.lang.Long) idType_));
477       }
478       if (idTypeCase_ == 3) {
479         com.google.protobuf.GeneratedMessageV3.writeString(output, 3, idType_);
480       }
481       getUnknownFields().writeTo(output);
482     }
483 
484     @java.lang.Override
getSerializedSize()485     public int getSerializedSize() {
486       int size = memoizedSize;
487       if (size != -1) return size;
488 
489       size = 0;
490       if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kind_)) {
491         size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, kind_);
492       }
493       if (idTypeCase_ == 2) {
494         size +=
495             com.google.protobuf.CodedOutputStream.computeInt64Size(
496                 2, (long) ((java.lang.Long) idType_));
497       }
498       if (idTypeCase_ == 3) {
499         size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, idType_);
500       }
501       size += getUnknownFields().getSerializedSize();
502       memoizedSize = size;
503       return size;
504     }
505 
506     @java.lang.Override
equals(final java.lang.Object obj)507     public boolean equals(final java.lang.Object obj) {
508       if (obj == this) {
509         return true;
510       }
511       if (!(obj instanceof com.google.privacy.dlp.v2.Key.PathElement)) {
512         return super.equals(obj);
513       }
514       com.google.privacy.dlp.v2.Key.PathElement other =
515           (com.google.privacy.dlp.v2.Key.PathElement) obj;
516 
517       if (!getKind().equals(other.getKind())) return false;
518       if (!getIdTypeCase().equals(other.getIdTypeCase())) return false;
519       switch (idTypeCase_) {
520         case 2:
521           if (getId() != other.getId()) return false;
522           break;
523         case 3:
524           if (!getName().equals(other.getName())) return false;
525           break;
526         case 0:
527         default:
528       }
529       if (!getUnknownFields().equals(other.getUnknownFields())) return false;
530       return true;
531     }
532 
533     @java.lang.Override
hashCode()534     public int hashCode() {
535       if (memoizedHashCode != 0) {
536         return memoizedHashCode;
537       }
538       int hash = 41;
539       hash = (19 * hash) + getDescriptor().hashCode();
540       hash = (37 * hash) + KIND_FIELD_NUMBER;
541       hash = (53 * hash) + getKind().hashCode();
542       switch (idTypeCase_) {
543         case 2:
544           hash = (37 * hash) + ID_FIELD_NUMBER;
545           hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getId());
546           break;
547         case 3:
548           hash = (37 * hash) + NAME_FIELD_NUMBER;
549           hash = (53 * hash) + getName().hashCode();
550           break;
551         case 0:
552         default:
553       }
554       hash = (29 * hash) + getUnknownFields().hashCode();
555       memoizedHashCode = hash;
556       return hash;
557     }
558 
parseFrom(java.nio.ByteBuffer data)559     public static com.google.privacy.dlp.v2.Key.PathElement parseFrom(java.nio.ByteBuffer data)
560         throws com.google.protobuf.InvalidProtocolBufferException {
561       return PARSER.parseFrom(data);
562     }
563 
parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)564     public static com.google.privacy.dlp.v2.Key.PathElement parseFrom(
565         java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
566         throws com.google.protobuf.InvalidProtocolBufferException {
567       return PARSER.parseFrom(data, extensionRegistry);
568     }
569 
parseFrom( com.google.protobuf.ByteString data)570     public static com.google.privacy.dlp.v2.Key.PathElement parseFrom(
571         com.google.protobuf.ByteString data)
572         throws com.google.protobuf.InvalidProtocolBufferException {
573       return PARSER.parseFrom(data);
574     }
575 
parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)576     public static com.google.privacy.dlp.v2.Key.PathElement parseFrom(
577         com.google.protobuf.ByteString data,
578         com.google.protobuf.ExtensionRegistryLite extensionRegistry)
579         throws com.google.protobuf.InvalidProtocolBufferException {
580       return PARSER.parseFrom(data, extensionRegistry);
581     }
582 
parseFrom(byte[] data)583     public static com.google.privacy.dlp.v2.Key.PathElement parseFrom(byte[] data)
584         throws com.google.protobuf.InvalidProtocolBufferException {
585       return PARSER.parseFrom(data);
586     }
587 
parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)588     public static com.google.privacy.dlp.v2.Key.PathElement parseFrom(
589         byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
590         throws com.google.protobuf.InvalidProtocolBufferException {
591       return PARSER.parseFrom(data, extensionRegistry);
592     }
593 
parseFrom(java.io.InputStream input)594     public static com.google.privacy.dlp.v2.Key.PathElement parseFrom(java.io.InputStream input)
595         throws java.io.IOException {
596       return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
597     }
598 
parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)599     public static com.google.privacy.dlp.v2.Key.PathElement parseFrom(
600         java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
601         throws java.io.IOException {
602       return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
603           PARSER, input, extensionRegistry);
604     }
605 
parseDelimitedFrom( java.io.InputStream input)606     public static com.google.privacy.dlp.v2.Key.PathElement parseDelimitedFrom(
607         java.io.InputStream input) throws java.io.IOException {
608       return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
609     }
610 
parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)611     public static com.google.privacy.dlp.v2.Key.PathElement parseDelimitedFrom(
612         java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
613         throws java.io.IOException {
614       return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
615           PARSER, input, extensionRegistry);
616     }
617 
parseFrom( com.google.protobuf.CodedInputStream input)618     public static com.google.privacy.dlp.v2.Key.PathElement parseFrom(
619         com.google.protobuf.CodedInputStream input) throws java.io.IOException {
620       return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
621     }
622 
parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)623     public static com.google.privacy.dlp.v2.Key.PathElement parseFrom(
624         com.google.protobuf.CodedInputStream input,
625         com.google.protobuf.ExtensionRegistryLite extensionRegistry)
626         throws java.io.IOException {
627       return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
628           PARSER, input, extensionRegistry);
629     }
630 
631     @java.lang.Override
newBuilderForType()632     public Builder newBuilderForType() {
633       return newBuilder();
634     }
635 
newBuilder()636     public static Builder newBuilder() {
637       return DEFAULT_INSTANCE.toBuilder();
638     }
639 
newBuilder(com.google.privacy.dlp.v2.Key.PathElement prototype)640     public static Builder newBuilder(com.google.privacy.dlp.v2.Key.PathElement prototype) {
641       return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
642     }
643 
644     @java.lang.Override
toBuilder()645     public Builder toBuilder() {
646       return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
647     }
648 
649     @java.lang.Override
newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent)650     protected Builder newBuilderForType(
651         com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
652       Builder builder = new Builder(parent);
653       return builder;
654     }
655     /**
656      *
657      *
658      * <pre>
659      * A (kind, ID/name) pair used to construct a key path.
660      * If either name or ID is set, the element is complete.
661      * If neither is set, the element is incomplete.
662      * </pre>
663      *
664      * Protobuf type {@code google.privacy.dlp.v2.Key.PathElement}
665      */
666     public static final class Builder
667         extends com.google.protobuf.GeneratedMessageV3.Builder<Builder>
668         implements
669         // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2.Key.PathElement)
670         com.google.privacy.dlp.v2.Key.PathElementOrBuilder {
getDescriptor()671       public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
672         return com.google.privacy.dlp.v2.DlpStorage
673             .internal_static_google_privacy_dlp_v2_Key_PathElement_descriptor;
674       }
675 
676       @java.lang.Override
677       protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()678           internalGetFieldAccessorTable() {
679         return com.google.privacy.dlp.v2.DlpStorage
680             .internal_static_google_privacy_dlp_v2_Key_PathElement_fieldAccessorTable
681             .ensureFieldAccessorsInitialized(
682                 com.google.privacy.dlp.v2.Key.PathElement.class,
683                 com.google.privacy.dlp.v2.Key.PathElement.Builder.class);
684       }
685 
686       // Construct using com.google.privacy.dlp.v2.Key.PathElement.newBuilder()
Builder()687       private Builder() {}
688 
Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)689       private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
690         super(parent);
691       }
692 
693       @java.lang.Override
clear()694       public Builder clear() {
695         super.clear();
696         bitField0_ = 0;
697         kind_ = "";
698         idTypeCase_ = 0;
699         idType_ = null;
700         return this;
701       }
702 
703       @java.lang.Override
getDescriptorForType()704       public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
705         return com.google.privacy.dlp.v2.DlpStorage
706             .internal_static_google_privacy_dlp_v2_Key_PathElement_descriptor;
707       }
708 
709       @java.lang.Override
getDefaultInstanceForType()710       public com.google.privacy.dlp.v2.Key.PathElement getDefaultInstanceForType() {
711         return com.google.privacy.dlp.v2.Key.PathElement.getDefaultInstance();
712       }
713 
714       @java.lang.Override
build()715       public com.google.privacy.dlp.v2.Key.PathElement build() {
716         com.google.privacy.dlp.v2.Key.PathElement result = buildPartial();
717         if (!result.isInitialized()) {
718           throw newUninitializedMessageException(result);
719         }
720         return result;
721       }
722 
723       @java.lang.Override
buildPartial()724       public com.google.privacy.dlp.v2.Key.PathElement buildPartial() {
725         com.google.privacy.dlp.v2.Key.PathElement result =
726             new com.google.privacy.dlp.v2.Key.PathElement(this);
727         if (bitField0_ != 0) {
728           buildPartial0(result);
729         }
730         buildPartialOneofs(result);
731         onBuilt();
732         return result;
733       }
734 
buildPartial0(com.google.privacy.dlp.v2.Key.PathElement result)735       private void buildPartial0(com.google.privacy.dlp.v2.Key.PathElement result) {
736         int from_bitField0_ = bitField0_;
737         if (((from_bitField0_ & 0x00000001) != 0)) {
738           result.kind_ = kind_;
739         }
740       }
741 
buildPartialOneofs(com.google.privacy.dlp.v2.Key.PathElement result)742       private void buildPartialOneofs(com.google.privacy.dlp.v2.Key.PathElement result) {
743         result.idTypeCase_ = idTypeCase_;
744         result.idType_ = this.idType_;
745       }
746 
747       @java.lang.Override
clone()748       public Builder clone() {
749         return super.clone();
750       }
751 
752       @java.lang.Override
setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)753       public Builder setField(
754           com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
755         return super.setField(field, value);
756       }
757 
758       @java.lang.Override
clearField(com.google.protobuf.Descriptors.FieldDescriptor field)759       public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
760         return super.clearField(field);
761       }
762 
763       @java.lang.Override
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)764       public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
765         return super.clearOneof(oneof);
766       }
767 
768       @java.lang.Override
setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)769       public Builder setRepeatedField(
770           com.google.protobuf.Descriptors.FieldDescriptor field,
771           int index,
772           java.lang.Object value) {
773         return super.setRepeatedField(field, index, value);
774       }
775 
776       @java.lang.Override
addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)777       public Builder addRepeatedField(
778           com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
779         return super.addRepeatedField(field, value);
780       }
781 
782       @java.lang.Override
mergeFrom(com.google.protobuf.Message other)783       public Builder mergeFrom(com.google.protobuf.Message other) {
784         if (other instanceof com.google.privacy.dlp.v2.Key.PathElement) {
785           return mergeFrom((com.google.privacy.dlp.v2.Key.PathElement) other);
786         } else {
787           super.mergeFrom(other);
788           return this;
789         }
790       }
791 
mergeFrom(com.google.privacy.dlp.v2.Key.PathElement other)792       public Builder mergeFrom(com.google.privacy.dlp.v2.Key.PathElement other) {
793         if (other == com.google.privacy.dlp.v2.Key.PathElement.getDefaultInstance()) return this;
794         if (!other.getKind().isEmpty()) {
795           kind_ = other.kind_;
796           bitField0_ |= 0x00000001;
797           onChanged();
798         }
799         switch (other.getIdTypeCase()) {
800           case ID:
801             {
802               setId(other.getId());
803               break;
804             }
805           case NAME:
806             {
807               idTypeCase_ = 3;
808               idType_ = other.idType_;
809               onChanged();
810               break;
811             }
812           case IDTYPE_NOT_SET:
813             {
814               break;
815             }
816         }
817         this.mergeUnknownFields(other.getUnknownFields());
818         onChanged();
819         return this;
820       }
821 
822       @java.lang.Override
isInitialized()823       public final boolean isInitialized() {
824         return true;
825       }
826 
827       @java.lang.Override
mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)828       public Builder mergeFrom(
829           com.google.protobuf.CodedInputStream input,
830           com.google.protobuf.ExtensionRegistryLite extensionRegistry)
831           throws java.io.IOException {
832         if (extensionRegistry == null) {
833           throw new java.lang.NullPointerException();
834         }
835         try {
836           boolean done = false;
837           while (!done) {
838             int tag = input.readTag();
839             switch (tag) {
840               case 0:
841                 done = true;
842                 break;
843               case 10:
844                 {
845                   kind_ = input.readStringRequireUtf8();
846                   bitField0_ |= 0x00000001;
847                   break;
848                 } // case 10
849               case 16:
850                 {
851                   idType_ = input.readInt64();
852                   idTypeCase_ = 2;
853                   break;
854                 } // case 16
855               case 26:
856                 {
857                   java.lang.String s = input.readStringRequireUtf8();
858                   idTypeCase_ = 3;
859                   idType_ = s;
860                   break;
861                 } // case 26
862               default:
863                 {
864                   if (!super.parseUnknownField(input, extensionRegistry, tag)) {
865                     done = true; // was an endgroup tag
866                   }
867                   break;
868                 } // default:
869             } // switch (tag)
870           } // while (!done)
871         } catch (com.google.protobuf.InvalidProtocolBufferException e) {
872           throw e.unwrapIOException();
873         } finally {
874           onChanged();
875         } // finally
876         return this;
877       }
878 
879       private int idTypeCase_ = 0;
880       private java.lang.Object idType_;
881 
getIdTypeCase()882       public IdTypeCase getIdTypeCase() {
883         return IdTypeCase.forNumber(idTypeCase_);
884       }
885 
clearIdType()886       public Builder clearIdType() {
887         idTypeCase_ = 0;
888         idType_ = null;
889         onChanged();
890         return this;
891       }
892 
893       private int bitField0_;
894 
895       private java.lang.Object kind_ = "";
896       /**
897        *
898        *
899        * <pre>
900        * The kind of the entity.
901        * A kind matching regex `__.*__` is reserved/read-only.
902        * A kind must not contain more than 1500 bytes when UTF-8 encoded.
903        * Cannot be `""`.
904        * </pre>
905        *
906        * <code>string kind = 1;</code>
907        *
908        * @return The kind.
909        */
getKind()910       public java.lang.String getKind() {
911         java.lang.Object ref = kind_;
912         if (!(ref instanceof java.lang.String)) {
913           com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
914           java.lang.String s = bs.toStringUtf8();
915           kind_ = s;
916           return s;
917         } else {
918           return (java.lang.String) ref;
919         }
920       }
921       /**
922        *
923        *
924        * <pre>
925        * The kind of the entity.
926        * A kind matching regex `__.*__` is reserved/read-only.
927        * A kind must not contain more than 1500 bytes when UTF-8 encoded.
928        * Cannot be `""`.
929        * </pre>
930        *
931        * <code>string kind = 1;</code>
932        *
933        * @return The bytes for kind.
934        */
getKindBytes()935       public com.google.protobuf.ByteString getKindBytes() {
936         java.lang.Object ref = kind_;
937         if (ref instanceof String) {
938           com.google.protobuf.ByteString b =
939               com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
940           kind_ = b;
941           return b;
942         } else {
943           return (com.google.protobuf.ByteString) ref;
944         }
945       }
946       /**
947        *
948        *
949        * <pre>
950        * The kind of the entity.
951        * A kind matching regex `__.*__` is reserved/read-only.
952        * A kind must not contain more than 1500 bytes when UTF-8 encoded.
953        * Cannot be `""`.
954        * </pre>
955        *
956        * <code>string kind = 1;</code>
957        *
958        * @param value The kind to set.
959        * @return This builder for chaining.
960        */
setKind(java.lang.String value)961       public Builder setKind(java.lang.String value) {
962         if (value == null) {
963           throw new NullPointerException();
964         }
965         kind_ = value;
966         bitField0_ |= 0x00000001;
967         onChanged();
968         return this;
969       }
970       /**
971        *
972        *
973        * <pre>
974        * The kind of the entity.
975        * A kind matching regex `__.*__` is reserved/read-only.
976        * A kind must not contain more than 1500 bytes when UTF-8 encoded.
977        * Cannot be `""`.
978        * </pre>
979        *
980        * <code>string kind = 1;</code>
981        *
982        * @return This builder for chaining.
983        */
clearKind()984       public Builder clearKind() {
985         kind_ = getDefaultInstance().getKind();
986         bitField0_ = (bitField0_ & ~0x00000001);
987         onChanged();
988         return this;
989       }
990       /**
991        *
992        *
993        * <pre>
994        * The kind of the entity.
995        * A kind matching regex `__.*__` is reserved/read-only.
996        * A kind must not contain more than 1500 bytes when UTF-8 encoded.
997        * Cannot be `""`.
998        * </pre>
999        *
1000        * <code>string kind = 1;</code>
1001        *
1002        * @param value The bytes for kind to set.
1003        * @return This builder for chaining.
1004        */
setKindBytes(com.google.protobuf.ByteString value)1005       public Builder setKindBytes(com.google.protobuf.ByteString value) {
1006         if (value == null) {
1007           throw new NullPointerException();
1008         }
1009         checkByteStringIsUtf8(value);
1010         kind_ = value;
1011         bitField0_ |= 0x00000001;
1012         onChanged();
1013         return this;
1014       }
1015 
1016       /**
1017        *
1018        *
1019        * <pre>
1020        * The auto-allocated ID of the entity.
1021        * Never equal to zero. Values less than zero are discouraged and may not
1022        * be supported in the future.
1023        * </pre>
1024        *
1025        * <code>int64 id = 2;</code>
1026        *
1027        * @return Whether the id field is set.
1028        */
hasId()1029       public boolean hasId() {
1030         return idTypeCase_ == 2;
1031       }
1032       /**
1033        *
1034        *
1035        * <pre>
1036        * The auto-allocated ID of the entity.
1037        * Never equal to zero. Values less than zero are discouraged and may not
1038        * be supported in the future.
1039        * </pre>
1040        *
1041        * <code>int64 id = 2;</code>
1042        *
1043        * @return The id.
1044        */
getId()1045       public long getId() {
1046         if (idTypeCase_ == 2) {
1047           return (java.lang.Long) idType_;
1048         }
1049         return 0L;
1050       }
1051       /**
1052        *
1053        *
1054        * <pre>
1055        * The auto-allocated ID of the entity.
1056        * Never equal to zero. Values less than zero are discouraged and may not
1057        * be supported in the future.
1058        * </pre>
1059        *
1060        * <code>int64 id = 2;</code>
1061        *
1062        * @param value The id to set.
1063        * @return This builder for chaining.
1064        */
setId(long value)1065       public Builder setId(long value) {
1066 
1067         idTypeCase_ = 2;
1068         idType_ = value;
1069         onChanged();
1070         return this;
1071       }
1072       /**
1073        *
1074        *
1075        * <pre>
1076        * The auto-allocated ID of the entity.
1077        * Never equal to zero. Values less than zero are discouraged and may not
1078        * be supported in the future.
1079        * </pre>
1080        *
1081        * <code>int64 id = 2;</code>
1082        *
1083        * @return This builder for chaining.
1084        */
clearId()1085       public Builder clearId() {
1086         if (idTypeCase_ == 2) {
1087           idTypeCase_ = 0;
1088           idType_ = null;
1089           onChanged();
1090         }
1091         return this;
1092       }
1093 
1094       /**
1095        *
1096        *
1097        * <pre>
1098        * The name of the entity.
1099        * A name matching regex `__.*__` is reserved/read-only.
1100        * A name must not be more than 1500 bytes when UTF-8 encoded.
1101        * Cannot be `""`.
1102        * </pre>
1103        *
1104        * <code>string name = 3;</code>
1105        *
1106        * @return Whether the name field is set.
1107        */
1108       @java.lang.Override
hasName()1109       public boolean hasName() {
1110         return idTypeCase_ == 3;
1111       }
1112       /**
1113        *
1114        *
1115        * <pre>
1116        * The name of the entity.
1117        * A name matching regex `__.*__` is reserved/read-only.
1118        * A name must not be more than 1500 bytes when UTF-8 encoded.
1119        * Cannot be `""`.
1120        * </pre>
1121        *
1122        * <code>string name = 3;</code>
1123        *
1124        * @return The name.
1125        */
1126       @java.lang.Override
getName()1127       public java.lang.String getName() {
1128         java.lang.Object ref = "";
1129         if (idTypeCase_ == 3) {
1130           ref = idType_;
1131         }
1132         if (!(ref instanceof java.lang.String)) {
1133           com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
1134           java.lang.String s = bs.toStringUtf8();
1135           if (idTypeCase_ == 3) {
1136             idType_ = s;
1137           }
1138           return s;
1139         } else {
1140           return (java.lang.String) ref;
1141         }
1142       }
1143       /**
1144        *
1145        *
1146        * <pre>
1147        * The name of the entity.
1148        * A name matching regex `__.*__` is reserved/read-only.
1149        * A name must not be more than 1500 bytes when UTF-8 encoded.
1150        * Cannot be `""`.
1151        * </pre>
1152        *
1153        * <code>string name = 3;</code>
1154        *
1155        * @return The bytes for name.
1156        */
1157       @java.lang.Override
getNameBytes()1158       public com.google.protobuf.ByteString getNameBytes() {
1159         java.lang.Object ref = "";
1160         if (idTypeCase_ == 3) {
1161           ref = idType_;
1162         }
1163         if (ref instanceof String) {
1164           com.google.protobuf.ByteString b =
1165               com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
1166           if (idTypeCase_ == 3) {
1167             idType_ = b;
1168           }
1169           return b;
1170         } else {
1171           return (com.google.protobuf.ByteString) ref;
1172         }
1173       }
1174       /**
1175        *
1176        *
1177        * <pre>
1178        * The name of the entity.
1179        * A name matching regex `__.*__` is reserved/read-only.
1180        * A name must not be more than 1500 bytes when UTF-8 encoded.
1181        * Cannot be `""`.
1182        * </pre>
1183        *
1184        * <code>string name = 3;</code>
1185        *
1186        * @param value The name to set.
1187        * @return This builder for chaining.
1188        */
setName(java.lang.String value)1189       public Builder setName(java.lang.String value) {
1190         if (value == null) {
1191           throw new NullPointerException();
1192         }
1193         idTypeCase_ = 3;
1194         idType_ = value;
1195         onChanged();
1196         return this;
1197       }
1198       /**
1199        *
1200        *
1201        * <pre>
1202        * The name of the entity.
1203        * A name matching regex `__.*__` is reserved/read-only.
1204        * A name must not be more than 1500 bytes when UTF-8 encoded.
1205        * Cannot be `""`.
1206        * </pre>
1207        *
1208        * <code>string name = 3;</code>
1209        *
1210        * @return This builder for chaining.
1211        */
clearName()1212       public Builder clearName() {
1213         if (idTypeCase_ == 3) {
1214           idTypeCase_ = 0;
1215           idType_ = null;
1216           onChanged();
1217         }
1218         return this;
1219       }
1220       /**
1221        *
1222        *
1223        * <pre>
1224        * The name of the entity.
1225        * A name matching regex `__.*__` is reserved/read-only.
1226        * A name must not be more than 1500 bytes when UTF-8 encoded.
1227        * Cannot be `""`.
1228        * </pre>
1229        *
1230        * <code>string name = 3;</code>
1231        *
1232        * @param value The bytes for name to set.
1233        * @return This builder for chaining.
1234        */
setNameBytes(com.google.protobuf.ByteString value)1235       public Builder setNameBytes(com.google.protobuf.ByteString value) {
1236         if (value == null) {
1237           throw new NullPointerException();
1238         }
1239         checkByteStringIsUtf8(value);
1240         idTypeCase_ = 3;
1241         idType_ = value;
1242         onChanged();
1243         return this;
1244       }
1245 
1246       @java.lang.Override
setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields)1247       public final Builder setUnknownFields(
1248           final com.google.protobuf.UnknownFieldSet unknownFields) {
1249         return super.setUnknownFields(unknownFields);
1250       }
1251 
1252       @java.lang.Override
mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields)1253       public final Builder mergeUnknownFields(
1254           final com.google.protobuf.UnknownFieldSet unknownFields) {
1255         return super.mergeUnknownFields(unknownFields);
1256       }
1257 
1258       // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2.Key.PathElement)
1259     }
1260 
1261     // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2.Key.PathElement)
1262     private static final com.google.privacy.dlp.v2.Key.PathElement DEFAULT_INSTANCE;
1263 
1264     static {
1265       DEFAULT_INSTANCE = new com.google.privacy.dlp.v2.Key.PathElement();
1266     }
1267 
getDefaultInstance()1268     public static com.google.privacy.dlp.v2.Key.PathElement getDefaultInstance() {
1269       return DEFAULT_INSTANCE;
1270     }
1271 
1272     private static final com.google.protobuf.Parser<PathElement> PARSER =
1273         new com.google.protobuf.AbstractParser<PathElement>() {
1274           @java.lang.Override
1275           public PathElement parsePartialFrom(
1276               com.google.protobuf.CodedInputStream input,
1277               com.google.protobuf.ExtensionRegistryLite extensionRegistry)
1278               throws com.google.protobuf.InvalidProtocolBufferException {
1279             Builder builder = newBuilder();
1280             try {
1281               builder.mergeFrom(input, extensionRegistry);
1282             } catch (com.google.protobuf.InvalidProtocolBufferException e) {
1283               throw e.setUnfinishedMessage(builder.buildPartial());
1284             } catch (com.google.protobuf.UninitializedMessageException e) {
1285               throw e.asInvalidProtocolBufferException()
1286                   .setUnfinishedMessage(builder.buildPartial());
1287             } catch (java.io.IOException e) {
1288               throw new com.google.protobuf.InvalidProtocolBufferException(e)
1289                   .setUnfinishedMessage(builder.buildPartial());
1290             }
1291             return builder.buildPartial();
1292           }
1293         };
1294 
parser()1295     public static com.google.protobuf.Parser<PathElement> parser() {
1296       return PARSER;
1297     }
1298 
1299     @java.lang.Override
getParserForType()1300     public com.google.protobuf.Parser<PathElement> getParserForType() {
1301       return PARSER;
1302     }
1303 
1304     @java.lang.Override
getDefaultInstanceForType()1305     public com.google.privacy.dlp.v2.Key.PathElement getDefaultInstanceForType() {
1306       return DEFAULT_INSTANCE;
1307     }
1308   }
1309 
1310   public static final int PARTITION_ID_FIELD_NUMBER = 1;
1311   private com.google.privacy.dlp.v2.PartitionId partitionId_;
1312   /**
1313    *
1314    *
1315    * <pre>
1316    * Entities are partitioned into subsets, currently identified by a project
1317    * ID and namespace ID.
1318    * Queries are scoped to a single partition.
1319    * </pre>
1320    *
1321    * <code>.google.privacy.dlp.v2.PartitionId partition_id = 1;</code>
1322    *
1323    * @return Whether the partitionId field is set.
1324    */
1325   @java.lang.Override
hasPartitionId()1326   public boolean hasPartitionId() {
1327     return partitionId_ != null;
1328   }
1329   /**
1330    *
1331    *
1332    * <pre>
1333    * Entities are partitioned into subsets, currently identified by a project
1334    * ID and namespace ID.
1335    * Queries are scoped to a single partition.
1336    * </pre>
1337    *
1338    * <code>.google.privacy.dlp.v2.PartitionId partition_id = 1;</code>
1339    *
1340    * @return The partitionId.
1341    */
1342   @java.lang.Override
getPartitionId()1343   public com.google.privacy.dlp.v2.PartitionId getPartitionId() {
1344     return partitionId_ == null
1345         ? com.google.privacy.dlp.v2.PartitionId.getDefaultInstance()
1346         : partitionId_;
1347   }
1348   /**
1349    *
1350    *
1351    * <pre>
1352    * Entities are partitioned into subsets, currently identified by a project
1353    * ID and namespace ID.
1354    * Queries are scoped to a single partition.
1355    * </pre>
1356    *
1357    * <code>.google.privacy.dlp.v2.PartitionId partition_id = 1;</code>
1358    */
1359   @java.lang.Override
getPartitionIdOrBuilder()1360   public com.google.privacy.dlp.v2.PartitionIdOrBuilder getPartitionIdOrBuilder() {
1361     return partitionId_ == null
1362         ? com.google.privacy.dlp.v2.PartitionId.getDefaultInstance()
1363         : partitionId_;
1364   }
1365 
1366   public static final int PATH_FIELD_NUMBER = 2;
1367 
1368   @SuppressWarnings("serial")
1369   private java.util.List<com.google.privacy.dlp.v2.Key.PathElement> path_;
1370   /**
1371    *
1372    *
1373    * <pre>
1374    * The entity path.
1375    * An entity path consists of one or more elements composed of a kind and a
1376    * string or numerical identifier, which identify entities. The first
1377    * element identifies a _root entity_, the second element identifies
1378    * a _child_ of the root entity, the third element identifies a child of the
1379    * second entity, and so forth. The entities identified by all prefixes of
1380    * the path are called the element's _ancestors_.
1381    * A path can never be empty, and a path can have at most 100 elements.
1382    * </pre>
1383    *
1384    * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
1385    */
1386   @java.lang.Override
getPathList()1387   public java.util.List<com.google.privacy.dlp.v2.Key.PathElement> getPathList() {
1388     return path_;
1389   }
1390   /**
1391    *
1392    *
1393    * <pre>
1394    * The entity path.
1395    * An entity path consists of one or more elements composed of a kind and a
1396    * string or numerical identifier, which identify entities. The first
1397    * element identifies a _root entity_, the second element identifies
1398    * a _child_ of the root entity, the third element identifies a child of the
1399    * second entity, and so forth. The entities identified by all prefixes of
1400    * the path are called the element's _ancestors_.
1401    * A path can never be empty, and a path can have at most 100 elements.
1402    * </pre>
1403    *
1404    * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
1405    */
1406   @java.lang.Override
1407   public java.util.List<? extends com.google.privacy.dlp.v2.Key.PathElementOrBuilder>
getPathOrBuilderList()1408       getPathOrBuilderList() {
1409     return path_;
1410   }
1411   /**
1412    *
1413    *
1414    * <pre>
1415    * The entity path.
1416    * An entity path consists of one or more elements composed of a kind and a
1417    * string or numerical identifier, which identify entities. The first
1418    * element identifies a _root entity_, the second element identifies
1419    * a _child_ of the root entity, the third element identifies a child of the
1420    * second entity, and so forth. The entities identified by all prefixes of
1421    * the path are called the element's _ancestors_.
1422    * A path can never be empty, and a path can have at most 100 elements.
1423    * </pre>
1424    *
1425    * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
1426    */
1427   @java.lang.Override
getPathCount()1428   public int getPathCount() {
1429     return path_.size();
1430   }
1431   /**
1432    *
1433    *
1434    * <pre>
1435    * The entity path.
1436    * An entity path consists of one or more elements composed of a kind and a
1437    * string or numerical identifier, which identify entities. The first
1438    * element identifies a _root entity_, the second element identifies
1439    * a _child_ of the root entity, the third element identifies a child of the
1440    * second entity, and so forth. The entities identified by all prefixes of
1441    * the path are called the element's _ancestors_.
1442    * A path can never be empty, and a path can have at most 100 elements.
1443    * </pre>
1444    *
1445    * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
1446    */
1447   @java.lang.Override
getPath(int index)1448   public com.google.privacy.dlp.v2.Key.PathElement getPath(int index) {
1449     return path_.get(index);
1450   }
1451   /**
1452    *
1453    *
1454    * <pre>
1455    * The entity path.
1456    * An entity path consists of one or more elements composed of a kind and a
1457    * string or numerical identifier, which identify entities. The first
1458    * element identifies a _root entity_, the second element identifies
1459    * a _child_ of the root entity, the third element identifies a child of the
1460    * second entity, and so forth. The entities identified by all prefixes of
1461    * the path are called the element's _ancestors_.
1462    * A path can never be empty, and a path can have at most 100 elements.
1463    * </pre>
1464    *
1465    * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
1466    */
1467   @java.lang.Override
getPathOrBuilder(int index)1468   public com.google.privacy.dlp.v2.Key.PathElementOrBuilder getPathOrBuilder(int index) {
1469     return path_.get(index);
1470   }
1471 
1472   private byte memoizedIsInitialized = -1;
1473 
1474   @java.lang.Override
isInitialized()1475   public final boolean isInitialized() {
1476     byte isInitialized = memoizedIsInitialized;
1477     if (isInitialized == 1) return true;
1478     if (isInitialized == 0) return false;
1479 
1480     memoizedIsInitialized = 1;
1481     return true;
1482   }
1483 
1484   @java.lang.Override
writeTo(com.google.protobuf.CodedOutputStream output)1485   public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
1486     if (partitionId_ != null) {
1487       output.writeMessage(1, getPartitionId());
1488     }
1489     for (int i = 0; i < path_.size(); i++) {
1490       output.writeMessage(2, path_.get(i));
1491     }
1492     getUnknownFields().writeTo(output);
1493   }
1494 
1495   @java.lang.Override
getSerializedSize()1496   public int getSerializedSize() {
1497     int size = memoizedSize;
1498     if (size != -1) return size;
1499 
1500     size = 0;
1501     if (partitionId_ != null) {
1502       size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getPartitionId());
1503     }
1504     for (int i = 0; i < path_.size(); i++) {
1505       size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, path_.get(i));
1506     }
1507     size += getUnknownFields().getSerializedSize();
1508     memoizedSize = size;
1509     return size;
1510   }
1511 
1512   @java.lang.Override
equals(final java.lang.Object obj)1513   public boolean equals(final java.lang.Object obj) {
1514     if (obj == this) {
1515       return true;
1516     }
1517     if (!(obj instanceof com.google.privacy.dlp.v2.Key)) {
1518       return super.equals(obj);
1519     }
1520     com.google.privacy.dlp.v2.Key other = (com.google.privacy.dlp.v2.Key) obj;
1521 
1522     if (hasPartitionId() != other.hasPartitionId()) return false;
1523     if (hasPartitionId()) {
1524       if (!getPartitionId().equals(other.getPartitionId())) return false;
1525     }
1526     if (!getPathList().equals(other.getPathList())) return false;
1527     if (!getUnknownFields().equals(other.getUnknownFields())) return false;
1528     return true;
1529   }
1530 
1531   @java.lang.Override
hashCode()1532   public int hashCode() {
1533     if (memoizedHashCode != 0) {
1534       return memoizedHashCode;
1535     }
1536     int hash = 41;
1537     hash = (19 * hash) + getDescriptor().hashCode();
1538     if (hasPartitionId()) {
1539       hash = (37 * hash) + PARTITION_ID_FIELD_NUMBER;
1540       hash = (53 * hash) + getPartitionId().hashCode();
1541     }
1542     if (getPathCount() > 0) {
1543       hash = (37 * hash) + PATH_FIELD_NUMBER;
1544       hash = (53 * hash) + getPathList().hashCode();
1545     }
1546     hash = (29 * hash) + getUnknownFields().hashCode();
1547     memoizedHashCode = hash;
1548     return hash;
1549   }
1550 
parseFrom(java.nio.ByteBuffer data)1551   public static com.google.privacy.dlp.v2.Key parseFrom(java.nio.ByteBuffer data)
1552       throws com.google.protobuf.InvalidProtocolBufferException {
1553     return PARSER.parseFrom(data);
1554   }
1555 
parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)1556   public static com.google.privacy.dlp.v2.Key parseFrom(
1557       java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
1558       throws com.google.protobuf.InvalidProtocolBufferException {
1559     return PARSER.parseFrom(data, extensionRegistry);
1560   }
1561 
parseFrom(com.google.protobuf.ByteString data)1562   public static com.google.privacy.dlp.v2.Key parseFrom(com.google.protobuf.ByteString data)
1563       throws com.google.protobuf.InvalidProtocolBufferException {
1564     return PARSER.parseFrom(data);
1565   }
1566 
parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)1567   public static com.google.privacy.dlp.v2.Key parseFrom(
1568       com.google.protobuf.ByteString data,
1569       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
1570       throws com.google.protobuf.InvalidProtocolBufferException {
1571     return PARSER.parseFrom(data, extensionRegistry);
1572   }
1573 
parseFrom(byte[] data)1574   public static com.google.privacy.dlp.v2.Key parseFrom(byte[] data)
1575       throws com.google.protobuf.InvalidProtocolBufferException {
1576     return PARSER.parseFrom(data);
1577   }
1578 
parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)1579   public static com.google.privacy.dlp.v2.Key parseFrom(
1580       byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
1581       throws com.google.protobuf.InvalidProtocolBufferException {
1582     return PARSER.parseFrom(data, extensionRegistry);
1583   }
1584 
parseFrom(java.io.InputStream input)1585   public static com.google.privacy.dlp.v2.Key parseFrom(java.io.InputStream input)
1586       throws java.io.IOException {
1587     return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
1588   }
1589 
parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)1590   public static com.google.privacy.dlp.v2.Key parseFrom(
1591       java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
1592       throws java.io.IOException {
1593     return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
1594         PARSER, input, extensionRegistry);
1595   }
1596 
parseDelimitedFrom(java.io.InputStream input)1597   public static com.google.privacy.dlp.v2.Key parseDelimitedFrom(java.io.InputStream input)
1598       throws java.io.IOException {
1599     return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
1600   }
1601 
parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)1602   public static com.google.privacy.dlp.v2.Key parseDelimitedFrom(
1603       java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
1604       throws java.io.IOException {
1605     return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
1606         PARSER, input, extensionRegistry);
1607   }
1608 
parseFrom(com.google.protobuf.CodedInputStream input)1609   public static com.google.privacy.dlp.v2.Key parseFrom(com.google.protobuf.CodedInputStream input)
1610       throws java.io.IOException {
1611     return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
1612   }
1613 
parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)1614   public static com.google.privacy.dlp.v2.Key parseFrom(
1615       com.google.protobuf.CodedInputStream input,
1616       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
1617       throws java.io.IOException {
1618     return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
1619         PARSER, input, extensionRegistry);
1620   }
1621 
1622   @java.lang.Override
newBuilderForType()1623   public Builder newBuilderForType() {
1624     return newBuilder();
1625   }
1626 
newBuilder()1627   public static Builder newBuilder() {
1628     return DEFAULT_INSTANCE.toBuilder();
1629   }
1630 
newBuilder(com.google.privacy.dlp.v2.Key prototype)1631   public static Builder newBuilder(com.google.privacy.dlp.v2.Key prototype) {
1632     return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
1633   }
1634 
1635   @java.lang.Override
toBuilder()1636   public Builder toBuilder() {
1637     return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
1638   }
1639 
1640   @java.lang.Override
newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)1641   protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
1642     Builder builder = new Builder(parent);
1643     return builder;
1644   }
1645   /**
1646    *
1647    *
1648    * <pre>
1649    * A unique identifier for a Datastore entity.
1650    * If a key's partition ID or any of its path kinds or names are
1651    * reserved/read-only, the key is reserved/read-only.
1652    * A reserved/read-only key is forbidden in certain documented contexts.
1653    * </pre>
1654    *
1655    * Protobuf type {@code google.privacy.dlp.v2.Key}
1656    */
1657   public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Builder>
1658       implements
1659       // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2.Key)
1660       com.google.privacy.dlp.v2.KeyOrBuilder {
getDescriptor()1661     public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
1662       return com.google.privacy.dlp.v2.DlpStorage
1663           .internal_static_google_privacy_dlp_v2_Key_descriptor;
1664     }
1665 
1666     @java.lang.Override
1667     protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()1668         internalGetFieldAccessorTable() {
1669       return com.google.privacy.dlp.v2.DlpStorage
1670           .internal_static_google_privacy_dlp_v2_Key_fieldAccessorTable
1671           .ensureFieldAccessorsInitialized(
1672               com.google.privacy.dlp.v2.Key.class, com.google.privacy.dlp.v2.Key.Builder.class);
1673     }
1674 
1675     // Construct using com.google.privacy.dlp.v2.Key.newBuilder()
Builder()1676     private Builder() {}
1677 
Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)1678     private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
1679       super(parent);
1680     }
1681 
1682     @java.lang.Override
clear()1683     public Builder clear() {
1684       super.clear();
1685       bitField0_ = 0;
1686       partitionId_ = null;
1687       if (partitionIdBuilder_ != null) {
1688         partitionIdBuilder_.dispose();
1689         partitionIdBuilder_ = null;
1690       }
1691       if (pathBuilder_ == null) {
1692         path_ = java.util.Collections.emptyList();
1693       } else {
1694         path_ = null;
1695         pathBuilder_.clear();
1696       }
1697       bitField0_ = (bitField0_ & ~0x00000002);
1698       return this;
1699     }
1700 
1701     @java.lang.Override
getDescriptorForType()1702     public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
1703       return com.google.privacy.dlp.v2.DlpStorage
1704           .internal_static_google_privacy_dlp_v2_Key_descriptor;
1705     }
1706 
1707     @java.lang.Override
getDefaultInstanceForType()1708     public com.google.privacy.dlp.v2.Key getDefaultInstanceForType() {
1709       return com.google.privacy.dlp.v2.Key.getDefaultInstance();
1710     }
1711 
1712     @java.lang.Override
build()1713     public com.google.privacy.dlp.v2.Key build() {
1714       com.google.privacy.dlp.v2.Key result = buildPartial();
1715       if (!result.isInitialized()) {
1716         throw newUninitializedMessageException(result);
1717       }
1718       return result;
1719     }
1720 
1721     @java.lang.Override
buildPartial()1722     public com.google.privacy.dlp.v2.Key buildPartial() {
1723       com.google.privacy.dlp.v2.Key result = new com.google.privacy.dlp.v2.Key(this);
1724       buildPartialRepeatedFields(result);
1725       if (bitField0_ != 0) {
1726         buildPartial0(result);
1727       }
1728       onBuilt();
1729       return result;
1730     }
1731 
buildPartialRepeatedFields(com.google.privacy.dlp.v2.Key result)1732     private void buildPartialRepeatedFields(com.google.privacy.dlp.v2.Key result) {
1733       if (pathBuilder_ == null) {
1734         if (((bitField0_ & 0x00000002) != 0)) {
1735           path_ = java.util.Collections.unmodifiableList(path_);
1736           bitField0_ = (bitField0_ & ~0x00000002);
1737         }
1738         result.path_ = path_;
1739       } else {
1740         result.path_ = pathBuilder_.build();
1741       }
1742     }
1743 
buildPartial0(com.google.privacy.dlp.v2.Key result)1744     private void buildPartial0(com.google.privacy.dlp.v2.Key result) {
1745       int from_bitField0_ = bitField0_;
1746       if (((from_bitField0_ & 0x00000001) != 0)) {
1747         result.partitionId_ =
1748             partitionIdBuilder_ == null ? partitionId_ : partitionIdBuilder_.build();
1749       }
1750     }
1751 
1752     @java.lang.Override
clone()1753     public Builder clone() {
1754       return super.clone();
1755     }
1756 
1757     @java.lang.Override
setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)1758     public Builder setField(
1759         com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
1760       return super.setField(field, value);
1761     }
1762 
1763     @java.lang.Override
clearField(com.google.protobuf.Descriptors.FieldDescriptor field)1764     public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
1765       return super.clearField(field);
1766     }
1767 
1768     @java.lang.Override
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)1769     public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
1770       return super.clearOneof(oneof);
1771     }
1772 
1773     @java.lang.Override
setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value)1774     public Builder setRepeatedField(
1775         com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) {
1776       return super.setRepeatedField(field, index, value);
1777     }
1778 
1779     @java.lang.Override
addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value)1780     public Builder addRepeatedField(
1781         com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
1782       return super.addRepeatedField(field, value);
1783     }
1784 
1785     @java.lang.Override
mergeFrom(com.google.protobuf.Message other)1786     public Builder mergeFrom(com.google.protobuf.Message other) {
1787       if (other instanceof com.google.privacy.dlp.v2.Key) {
1788         return mergeFrom((com.google.privacy.dlp.v2.Key) other);
1789       } else {
1790         super.mergeFrom(other);
1791         return this;
1792       }
1793     }
1794 
mergeFrom(com.google.privacy.dlp.v2.Key other)1795     public Builder mergeFrom(com.google.privacy.dlp.v2.Key other) {
1796       if (other == com.google.privacy.dlp.v2.Key.getDefaultInstance()) return this;
1797       if (other.hasPartitionId()) {
1798         mergePartitionId(other.getPartitionId());
1799       }
1800       if (pathBuilder_ == null) {
1801         if (!other.path_.isEmpty()) {
1802           if (path_.isEmpty()) {
1803             path_ = other.path_;
1804             bitField0_ = (bitField0_ & ~0x00000002);
1805           } else {
1806             ensurePathIsMutable();
1807             path_.addAll(other.path_);
1808           }
1809           onChanged();
1810         }
1811       } else {
1812         if (!other.path_.isEmpty()) {
1813           if (pathBuilder_.isEmpty()) {
1814             pathBuilder_.dispose();
1815             pathBuilder_ = null;
1816             path_ = other.path_;
1817             bitField0_ = (bitField0_ & ~0x00000002);
1818             pathBuilder_ =
1819                 com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders
1820                     ? getPathFieldBuilder()
1821                     : null;
1822           } else {
1823             pathBuilder_.addAllMessages(other.path_);
1824           }
1825         }
1826       }
1827       this.mergeUnknownFields(other.getUnknownFields());
1828       onChanged();
1829       return this;
1830     }
1831 
1832     @java.lang.Override
isInitialized()1833     public final boolean isInitialized() {
1834       return true;
1835     }
1836 
1837     @java.lang.Override
mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)1838     public Builder mergeFrom(
1839         com.google.protobuf.CodedInputStream input,
1840         com.google.protobuf.ExtensionRegistryLite extensionRegistry)
1841         throws java.io.IOException {
1842       if (extensionRegistry == null) {
1843         throw new java.lang.NullPointerException();
1844       }
1845       try {
1846         boolean done = false;
1847         while (!done) {
1848           int tag = input.readTag();
1849           switch (tag) {
1850             case 0:
1851               done = true;
1852               break;
1853             case 10:
1854               {
1855                 input.readMessage(getPartitionIdFieldBuilder().getBuilder(), extensionRegistry);
1856                 bitField0_ |= 0x00000001;
1857                 break;
1858               } // case 10
1859             case 18:
1860               {
1861                 com.google.privacy.dlp.v2.Key.PathElement m =
1862                     input.readMessage(
1863                         com.google.privacy.dlp.v2.Key.PathElement.parser(), extensionRegistry);
1864                 if (pathBuilder_ == null) {
1865                   ensurePathIsMutable();
1866                   path_.add(m);
1867                 } else {
1868                   pathBuilder_.addMessage(m);
1869                 }
1870                 break;
1871               } // case 18
1872             default:
1873               {
1874                 if (!super.parseUnknownField(input, extensionRegistry, tag)) {
1875                   done = true; // was an endgroup tag
1876                 }
1877                 break;
1878               } // default:
1879           } // switch (tag)
1880         } // while (!done)
1881       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
1882         throw e.unwrapIOException();
1883       } finally {
1884         onChanged();
1885       } // finally
1886       return this;
1887     }
1888 
1889     private int bitField0_;
1890 
1891     private com.google.privacy.dlp.v2.PartitionId partitionId_;
1892     private com.google.protobuf.SingleFieldBuilderV3<
1893             com.google.privacy.dlp.v2.PartitionId,
1894             com.google.privacy.dlp.v2.PartitionId.Builder,
1895             com.google.privacy.dlp.v2.PartitionIdOrBuilder>
1896         partitionIdBuilder_;
1897     /**
1898      *
1899      *
1900      * <pre>
1901      * Entities are partitioned into subsets, currently identified by a project
1902      * ID and namespace ID.
1903      * Queries are scoped to a single partition.
1904      * </pre>
1905      *
1906      * <code>.google.privacy.dlp.v2.PartitionId partition_id = 1;</code>
1907      *
1908      * @return Whether the partitionId field is set.
1909      */
hasPartitionId()1910     public boolean hasPartitionId() {
1911       return ((bitField0_ & 0x00000001) != 0);
1912     }
1913     /**
1914      *
1915      *
1916      * <pre>
1917      * Entities are partitioned into subsets, currently identified by a project
1918      * ID and namespace ID.
1919      * Queries are scoped to a single partition.
1920      * </pre>
1921      *
1922      * <code>.google.privacy.dlp.v2.PartitionId partition_id = 1;</code>
1923      *
1924      * @return The partitionId.
1925      */
getPartitionId()1926     public com.google.privacy.dlp.v2.PartitionId getPartitionId() {
1927       if (partitionIdBuilder_ == null) {
1928         return partitionId_ == null
1929             ? com.google.privacy.dlp.v2.PartitionId.getDefaultInstance()
1930             : partitionId_;
1931       } else {
1932         return partitionIdBuilder_.getMessage();
1933       }
1934     }
1935     /**
1936      *
1937      *
1938      * <pre>
1939      * Entities are partitioned into subsets, currently identified by a project
1940      * ID and namespace ID.
1941      * Queries are scoped to a single partition.
1942      * </pre>
1943      *
1944      * <code>.google.privacy.dlp.v2.PartitionId partition_id = 1;</code>
1945      */
setPartitionId(com.google.privacy.dlp.v2.PartitionId value)1946     public Builder setPartitionId(com.google.privacy.dlp.v2.PartitionId value) {
1947       if (partitionIdBuilder_ == null) {
1948         if (value == null) {
1949           throw new NullPointerException();
1950         }
1951         partitionId_ = value;
1952       } else {
1953         partitionIdBuilder_.setMessage(value);
1954       }
1955       bitField0_ |= 0x00000001;
1956       onChanged();
1957       return this;
1958     }
1959     /**
1960      *
1961      *
1962      * <pre>
1963      * Entities are partitioned into subsets, currently identified by a project
1964      * ID and namespace ID.
1965      * Queries are scoped to a single partition.
1966      * </pre>
1967      *
1968      * <code>.google.privacy.dlp.v2.PartitionId partition_id = 1;</code>
1969      */
setPartitionId(com.google.privacy.dlp.v2.PartitionId.Builder builderForValue)1970     public Builder setPartitionId(com.google.privacy.dlp.v2.PartitionId.Builder builderForValue) {
1971       if (partitionIdBuilder_ == null) {
1972         partitionId_ = builderForValue.build();
1973       } else {
1974         partitionIdBuilder_.setMessage(builderForValue.build());
1975       }
1976       bitField0_ |= 0x00000001;
1977       onChanged();
1978       return this;
1979     }
1980     /**
1981      *
1982      *
1983      * <pre>
1984      * Entities are partitioned into subsets, currently identified by a project
1985      * ID and namespace ID.
1986      * Queries are scoped to a single partition.
1987      * </pre>
1988      *
1989      * <code>.google.privacy.dlp.v2.PartitionId partition_id = 1;</code>
1990      */
mergePartitionId(com.google.privacy.dlp.v2.PartitionId value)1991     public Builder mergePartitionId(com.google.privacy.dlp.v2.PartitionId value) {
1992       if (partitionIdBuilder_ == null) {
1993         if (((bitField0_ & 0x00000001) != 0)
1994             && partitionId_ != null
1995             && partitionId_ != com.google.privacy.dlp.v2.PartitionId.getDefaultInstance()) {
1996           getPartitionIdBuilder().mergeFrom(value);
1997         } else {
1998           partitionId_ = value;
1999         }
2000       } else {
2001         partitionIdBuilder_.mergeFrom(value);
2002       }
2003       bitField0_ |= 0x00000001;
2004       onChanged();
2005       return this;
2006     }
2007     /**
2008      *
2009      *
2010      * <pre>
2011      * Entities are partitioned into subsets, currently identified by a project
2012      * ID and namespace ID.
2013      * Queries are scoped to a single partition.
2014      * </pre>
2015      *
2016      * <code>.google.privacy.dlp.v2.PartitionId partition_id = 1;</code>
2017      */
clearPartitionId()2018     public Builder clearPartitionId() {
2019       bitField0_ = (bitField0_ & ~0x00000001);
2020       partitionId_ = null;
2021       if (partitionIdBuilder_ != null) {
2022         partitionIdBuilder_.dispose();
2023         partitionIdBuilder_ = null;
2024       }
2025       onChanged();
2026       return this;
2027     }
2028     /**
2029      *
2030      *
2031      * <pre>
2032      * Entities are partitioned into subsets, currently identified by a project
2033      * ID and namespace ID.
2034      * Queries are scoped to a single partition.
2035      * </pre>
2036      *
2037      * <code>.google.privacy.dlp.v2.PartitionId partition_id = 1;</code>
2038      */
getPartitionIdBuilder()2039     public com.google.privacy.dlp.v2.PartitionId.Builder getPartitionIdBuilder() {
2040       bitField0_ |= 0x00000001;
2041       onChanged();
2042       return getPartitionIdFieldBuilder().getBuilder();
2043     }
2044     /**
2045      *
2046      *
2047      * <pre>
2048      * Entities are partitioned into subsets, currently identified by a project
2049      * ID and namespace ID.
2050      * Queries are scoped to a single partition.
2051      * </pre>
2052      *
2053      * <code>.google.privacy.dlp.v2.PartitionId partition_id = 1;</code>
2054      */
getPartitionIdOrBuilder()2055     public com.google.privacy.dlp.v2.PartitionIdOrBuilder getPartitionIdOrBuilder() {
2056       if (partitionIdBuilder_ != null) {
2057         return partitionIdBuilder_.getMessageOrBuilder();
2058       } else {
2059         return partitionId_ == null
2060             ? com.google.privacy.dlp.v2.PartitionId.getDefaultInstance()
2061             : partitionId_;
2062       }
2063     }
2064     /**
2065      *
2066      *
2067      * <pre>
2068      * Entities are partitioned into subsets, currently identified by a project
2069      * ID and namespace ID.
2070      * Queries are scoped to a single partition.
2071      * </pre>
2072      *
2073      * <code>.google.privacy.dlp.v2.PartitionId partition_id = 1;</code>
2074      */
2075     private com.google.protobuf.SingleFieldBuilderV3<
2076             com.google.privacy.dlp.v2.PartitionId,
2077             com.google.privacy.dlp.v2.PartitionId.Builder,
2078             com.google.privacy.dlp.v2.PartitionIdOrBuilder>
getPartitionIdFieldBuilder()2079         getPartitionIdFieldBuilder() {
2080       if (partitionIdBuilder_ == null) {
2081         partitionIdBuilder_ =
2082             new com.google.protobuf.SingleFieldBuilderV3<
2083                 com.google.privacy.dlp.v2.PartitionId,
2084                 com.google.privacy.dlp.v2.PartitionId.Builder,
2085                 com.google.privacy.dlp.v2.PartitionIdOrBuilder>(
2086                 getPartitionId(), getParentForChildren(), isClean());
2087         partitionId_ = null;
2088       }
2089       return partitionIdBuilder_;
2090     }
2091 
2092     private java.util.List<com.google.privacy.dlp.v2.Key.PathElement> path_ =
2093         java.util.Collections.emptyList();
2094 
ensurePathIsMutable()2095     private void ensurePathIsMutable() {
2096       if (!((bitField0_ & 0x00000002) != 0)) {
2097         path_ = new java.util.ArrayList<com.google.privacy.dlp.v2.Key.PathElement>(path_);
2098         bitField0_ |= 0x00000002;
2099       }
2100     }
2101 
2102     private com.google.protobuf.RepeatedFieldBuilderV3<
2103             com.google.privacy.dlp.v2.Key.PathElement,
2104             com.google.privacy.dlp.v2.Key.PathElement.Builder,
2105             com.google.privacy.dlp.v2.Key.PathElementOrBuilder>
2106         pathBuilder_;
2107 
2108     /**
2109      *
2110      *
2111      * <pre>
2112      * The entity path.
2113      * An entity path consists of one or more elements composed of a kind and a
2114      * string or numerical identifier, which identify entities. The first
2115      * element identifies a _root entity_, the second element identifies
2116      * a _child_ of the root entity, the third element identifies a child of the
2117      * second entity, and so forth. The entities identified by all prefixes of
2118      * the path are called the element's _ancestors_.
2119      * A path can never be empty, and a path can have at most 100 elements.
2120      * </pre>
2121      *
2122      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2123      */
getPathList()2124     public java.util.List<com.google.privacy.dlp.v2.Key.PathElement> getPathList() {
2125       if (pathBuilder_ == null) {
2126         return java.util.Collections.unmodifiableList(path_);
2127       } else {
2128         return pathBuilder_.getMessageList();
2129       }
2130     }
2131     /**
2132      *
2133      *
2134      * <pre>
2135      * The entity path.
2136      * An entity path consists of one or more elements composed of a kind and a
2137      * string or numerical identifier, which identify entities. The first
2138      * element identifies a _root entity_, the second element identifies
2139      * a _child_ of the root entity, the third element identifies a child of the
2140      * second entity, and so forth. The entities identified by all prefixes of
2141      * the path are called the element's _ancestors_.
2142      * A path can never be empty, and a path can have at most 100 elements.
2143      * </pre>
2144      *
2145      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2146      */
getPathCount()2147     public int getPathCount() {
2148       if (pathBuilder_ == null) {
2149         return path_.size();
2150       } else {
2151         return pathBuilder_.getCount();
2152       }
2153     }
2154     /**
2155      *
2156      *
2157      * <pre>
2158      * The entity path.
2159      * An entity path consists of one or more elements composed of a kind and a
2160      * string or numerical identifier, which identify entities. The first
2161      * element identifies a _root entity_, the second element identifies
2162      * a _child_ of the root entity, the third element identifies a child of the
2163      * second entity, and so forth. The entities identified by all prefixes of
2164      * the path are called the element's _ancestors_.
2165      * A path can never be empty, and a path can have at most 100 elements.
2166      * </pre>
2167      *
2168      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2169      */
getPath(int index)2170     public com.google.privacy.dlp.v2.Key.PathElement getPath(int index) {
2171       if (pathBuilder_ == null) {
2172         return path_.get(index);
2173       } else {
2174         return pathBuilder_.getMessage(index);
2175       }
2176     }
2177     /**
2178      *
2179      *
2180      * <pre>
2181      * The entity path.
2182      * An entity path consists of one or more elements composed of a kind and a
2183      * string or numerical identifier, which identify entities. The first
2184      * element identifies a _root entity_, the second element identifies
2185      * a _child_ of the root entity, the third element identifies a child of the
2186      * second entity, and so forth. The entities identified by all prefixes of
2187      * the path are called the element's _ancestors_.
2188      * A path can never be empty, and a path can have at most 100 elements.
2189      * </pre>
2190      *
2191      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2192      */
setPath(int index, com.google.privacy.dlp.v2.Key.PathElement value)2193     public Builder setPath(int index, com.google.privacy.dlp.v2.Key.PathElement value) {
2194       if (pathBuilder_ == null) {
2195         if (value == null) {
2196           throw new NullPointerException();
2197         }
2198         ensurePathIsMutable();
2199         path_.set(index, value);
2200         onChanged();
2201       } else {
2202         pathBuilder_.setMessage(index, value);
2203       }
2204       return this;
2205     }
2206     /**
2207      *
2208      *
2209      * <pre>
2210      * The entity path.
2211      * An entity path consists of one or more elements composed of a kind and a
2212      * string or numerical identifier, which identify entities. The first
2213      * element identifies a _root entity_, the second element identifies
2214      * a _child_ of the root entity, the third element identifies a child of the
2215      * second entity, and so forth. The entities identified by all prefixes of
2216      * the path are called the element's _ancestors_.
2217      * A path can never be empty, and a path can have at most 100 elements.
2218      * </pre>
2219      *
2220      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2221      */
setPath( int index, com.google.privacy.dlp.v2.Key.PathElement.Builder builderForValue)2222     public Builder setPath(
2223         int index, com.google.privacy.dlp.v2.Key.PathElement.Builder builderForValue) {
2224       if (pathBuilder_ == null) {
2225         ensurePathIsMutable();
2226         path_.set(index, builderForValue.build());
2227         onChanged();
2228       } else {
2229         pathBuilder_.setMessage(index, builderForValue.build());
2230       }
2231       return this;
2232     }
2233     /**
2234      *
2235      *
2236      * <pre>
2237      * The entity path.
2238      * An entity path consists of one or more elements composed of a kind and a
2239      * string or numerical identifier, which identify entities. The first
2240      * element identifies a _root entity_, the second element identifies
2241      * a _child_ of the root entity, the third element identifies a child of the
2242      * second entity, and so forth. The entities identified by all prefixes of
2243      * the path are called the element's _ancestors_.
2244      * A path can never be empty, and a path can have at most 100 elements.
2245      * </pre>
2246      *
2247      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2248      */
addPath(com.google.privacy.dlp.v2.Key.PathElement value)2249     public Builder addPath(com.google.privacy.dlp.v2.Key.PathElement value) {
2250       if (pathBuilder_ == null) {
2251         if (value == null) {
2252           throw new NullPointerException();
2253         }
2254         ensurePathIsMutable();
2255         path_.add(value);
2256         onChanged();
2257       } else {
2258         pathBuilder_.addMessage(value);
2259       }
2260       return this;
2261     }
2262     /**
2263      *
2264      *
2265      * <pre>
2266      * The entity path.
2267      * An entity path consists of one or more elements composed of a kind and a
2268      * string or numerical identifier, which identify entities. The first
2269      * element identifies a _root entity_, the second element identifies
2270      * a _child_ of the root entity, the third element identifies a child of the
2271      * second entity, and so forth. The entities identified by all prefixes of
2272      * the path are called the element's _ancestors_.
2273      * A path can never be empty, and a path can have at most 100 elements.
2274      * </pre>
2275      *
2276      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2277      */
addPath(int index, com.google.privacy.dlp.v2.Key.PathElement value)2278     public Builder addPath(int index, com.google.privacy.dlp.v2.Key.PathElement value) {
2279       if (pathBuilder_ == null) {
2280         if (value == null) {
2281           throw new NullPointerException();
2282         }
2283         ensurePathIsMutable();
2284         path_.add(index, value);
2285         onChanged();
2286       } else {
2287         pathBuilder_.addMessage(index, value);
2288       }
2289       return this;
2290     }
2291     /**
2292      *
2293      *
2294      * <pre>
2295      * The entity path.
2296      * An entity path consists of one or more elements composed of a kind and a
2297      * string or numerical identifier, which identify entities. The first
2298      * element identifies a _root entity_, the second element identifies
2299      * a _child_ of the root entity, the third element identifies a child of the
2300      * second entity, and so forth. The entities identified by all prefixes of
2301      * the path are called the element's _ancestors_.
2302      * A path can never be empty, and a path can have at most 100 elements.
2303      * </pre>
2304      *
2305      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2306      */
addPath(com.google.privacy.dlp.v2.Key.PathElement.Builder builderForValue)2307     public Builder addPath(com.google.privacy.dlp.v2.Key.PathElement.Builder builderForValue) {
2308       if (pathBuilder_ == null) {
2309         ensurePathIsMutable();
2310         path_.add(builderForValue.build());
2311         onChanged();
2312       } else {
2313         pathBuilder_.addMessage(builderForValue.build());
2314       }
2315       return this;
2316     }
2317     /**
2318      *
2319      *
2320      * <pre>
2321      * The entity path.
2322      * An entity path consists of one or more elements composed of a kind and a
2323      * string or numerical identifier, which identify entities. The first
2324      * element identifies a _root entity_, the second element identifies
2325      * a _child_ of the root entity, the third element identifies a child of the
2326      * second entity, and so forth. The entities identified by all prefixes of
2327      * the path are called the element's _ancestors_.
2328      * A path can never be empty, and a path can have at most 100 elements.
2329      * </pre>
2330      *
2331      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2332      */
addPath( int index, com.google.privacy.dlp.v2.Key.PathElement.Builder builderForValue)2333     public Builder addPath(
2334         int index, com.google.privacy.dlp.v2.Key.PathElement.Builder builderForValue) {
2335       if (pathBuilder_ == null) {
2336         ensurePathIsMutable();
2337         path_.add(index, builderForValue.build());
2338         onChanged();
2339       } else {
2340         pathBuilder_.addMessage(index, builderForValue.build());
2341       }
2342       return this;
2343     }
2344     /**
2345      *
2346      *
2347      * <pre>
2348      * The entity path.
2349      * An entity path consists of one or more elements composed of a kind and a
2350      * string or numerical identifier, which identify entities. The first
2351      * element identifies a _root entity_, the second element identifies
2352      * a _child_ of the root entity, the third element identifies a child of the
2353      * second entity, and so forth. The entities identified by all prefixes of
2354      * the path are called the element's _ancestors_.
2355      * A path can never be empty, and a path can have at most 100 elements.
2356      * </pre>
2357      *
2358      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2359      */
addAllPath( java.lang.Iterable<? extends com.google.privacy.dlp.v2.Key.PathElement> values)2360     public Builder addAllPath(
2361         java.lang.Iterable<? extends com.google.privacy.dlp.v2.Key.PathElement> values) {
2362       if (pathBuilder_ == null) {
2363         ensurePathIsMutable();
2364         com.google.protobuf.AbstractMessageLite.Builder.addAll(values, path_);
2365         onChanged();
2366       } else {
2367         pathBuilder_.addAllMessages(values);
2368       }
2369       return this;
2370     }
2371     /**
2372      *
2373      *
2374      * <pre>
2375      * The entity path.
2376      * An entity path consists of one or more elements composed of a kind and a
2377      * string or numerical identifier, which identify entities. The first
2378      * element identifies a _root entity_, the second element identifies
2379      * a _child_ of the root entity, the third element identifies a child of the
2380      * second entity, and so forth. The entities identified by all prefixes of
2381      * the path are called the element's _ancestors_.
2382      * A path can never be empty, and a path can have at most 100 elements.
2383      * </pre>
2384      *
2385      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2386      */
clearPath()2387     public Builder clearPath() {
2388       if (pathBuilder_ == null) {
2389         path_ = java.util.Collections.emptyList();
2390         bitField0_ = (bitField0_ & ~0x00000002);
2391         onChanged();
2392       } else {
2393         pathBuilder_.clear();
2394       }
2395       return this;
2396     }
2397     /**
2398      *
2399      *
2400      * <pre>
2401      * The entity path.
2402      * An entity path consists of one or more elements composed of a kind and a
2403      * string or numerical identifier, which identify entities. The first
2404      * element identifies a _root entity_, the second element identifies
2405      * a _child_ of the root entity, the third element identifies a child of the
2406      * second entity, and so forth. The entities identified by all prefixes of
2407      * the path are called the element's _ancestors_.
2408      * A path can never be empty, and a path can have at most 100 elements.
2409      * </pre>
2410      *
2411      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2412      */
removePath(int index)2413     public Builder removePath(int index) {
2414       if (pathBuilder_ == null) {
2415         ensurePathIsMutable();
2416         path_.remove(index);
2417         onChanged();
2418       } else {
2419         pathBuilder_.remove(index);
2420       }
2421       return this;
2422     }
2423     /**
2424      *
2425      *
2426      * <pre>
2427      * The entity path.
2428      * An entity path consists of one or more elements composed of a kind and a
2429      * string or numerical identifier, which identify entities. The first
2430      * element identifies a _root entity_, the second element identifies
2431      * a _child_ of the root entity, the third element identifies a child of the
2432      * second entity, and so forth. The entities identified by all prefixes of
2433      * the path are called the element's _ancestors_.
2434      * A path can never be empty, and a path can have at most 100 elements.
2435      * </pre>
2436      *
2437      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2438      */
getPathBuilder(int index)2439     public com.google.privacy.dlp.v2.Key.PathElement.Builder getPathBuilder(int index) {
2440       return getPathFieldBuilder().getBuilder(index);
2441     }
2442     /**
2443      *
2444      *
2445      * <pre>
2446      * The entity path.
2447      * An entity path consists of one or more elements composed of a kind and a
2448      * string or numerical identifier, which identify entities. The first
2449      * element identifies a _root entity_, the second element identifies
2450      * a _child_ of the root entity, the third element identifies a child of the
2451      * second entity, and so forth. The entities identified by all prefixes of
2452      * the path are called the element's _ancestors_.
2453      * A path can never be empty, and a path can have at most 100 elements.
2454      * </pre>
2455      *
2456      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2457      */
getPathOrBuilder(int index)2458     public com.google.privacy.dlp.v2.Key.PathElementOrBuilder getPathOrBuilder(int index) {
2459       if (pathBuilder_ == null) {
2460         return path_.get(index);
2461       } else {
2462         return pathBuilder_.getMessageOrBuilder(index);
2463       }
2464     }
2465     /**
2466      *
2467      *
2468      * <pre>
2469      * The entity path.
2470      * An entity path consists of one or more elements composed of a kind and a
2471      * string or numerical identifier, which identify entities. The first
2472      * element identifies a _root entity_, the second element identifies
2473      * a _child_ of the root entity, the third element identifies a child of the
2474      * second entity, and so forth. The entities identified by all prefixes of
2475      * the path are called the element's _ancestors_.
2476      * A path can never be empty, and a path can have at most 100 elements.
2477      * </pre>
2478      *
2479      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2480      */
2481     public java.util.List<? extends com.google.privacy.dlp.v2.Key.PathElementOrBuilder>
getPathOrBuilderList()2482         getPathOrBuilderList() {
2483       if (pathBuilder_ != null) {
2484         return pathBuilder_.getMessageOrBuilderList();
2485       } else {
2486         return java.util.Collections.unmodifiableList(path_);
2487       }
2488     }
2489     /**
2490      *
2491      *
2492      * <pre>
2493      * The entity path.
2494      * An entity path consists of one or more elements composed of a kind and a
2495      * string or numerical identifier, which identify entities. The first
2496      * element identifies a _root entity_, the second element identifies
2497      * a _child_ of the root entity, the third element identifies a child of the
2498      * second entity, and so forth. The entities identified by all prefixes of
2499      * the path are called the element's _ancestors_.
2500      * A path can never be empty, and a path can have at most 100 elements.
2501      * </pre>
2502      *
2503      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2504      */
addPathBuilder()2505     public com.google.privacy.dlp.v2.Key.PathElement.Builder addPathBuilder() {
2506       return getPathFieldBuilder()
2507           .addBuilder(com.google.privacy.dlp.v2.Key.PathElement.getDefaultInstance());
2508     }
2509     /**
2510      *
2511      *
2512      * <pre>
2513      * The entity path.
2514      * An entity path consists of one or more elements composed of a kind and a
2515      * string or numerical identifier, which identify entities. The first
2516      * element identifies a _root entity_, the second element identifies
2517      * a _child_ of the root entity, the third element identifies a child of the
2518      * second entity, and so forth. The entities identified by all prefixes of
2519      * the path are called the element's _ancestors_.
2520      * A path can never be empty, and a path can have at most 100 elements.
2521      * </pre>
2522      *
2523      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2524      */
addPathBuilder(int index)2525     public com.google.privacy.dlp.v2.Key.PathElement.Builder addPathBuilder(int index) {
2526       return getPathFieldBuilder()
2527           .addBuilder(index, com.google.privacy.dlp.v2.Key.PathElement.getDefaultInstance());
2528     }
2529     /**
2530      *
2531      *
2532      * <pre>
2533      * The entity path.
2534      * An entity path consists of one or more elements composed of a kind and a
2535      * string or numerical identifier, which identify entities. The first
2536      * element identifies a _root entity_, the second element identifies
2537      * a _child_ of the root entity, the third element identifies a child of the
2538      * second entity, and so forth. The entities identified by all prefixes of
2539      * the path are called the element's _ancestors_.
2540      * A path can never be empty, and a path can have at most 100 elements.
2541      * </pre>
2542      *
2543      * <code>repeated .google.privacy.dlp.v2.Key.PathElement path = 2;</code>
2544      */
getPathBuilderList()2545     public java.util.List<com.google.privacy.dlp.v2.Key.PathElement.Builder> getPathBuilderList() {
2546       return getPathFieldBuilder().getBuilderList();
2547     }
2548 
2549     private com.google.protobuf.RepeatedFieldBuilderV3<
2550             com.google.privacy.dlp.v2.Key.PathElement,
2551             com.google.privacy.dlp.v2.Key.PathElement.Builder,
2552             com.google.privacy.dlp.v2.Key.PathElementOrBuilder>
getPathFieldBuilder()2553         getPathFieldBuilder() {
2554       if (pathBuilder_ == null) {
2555         pathBuilder_ =
2556             new com.google.protobuf.RepeatedFieldBuilderV3<
2557                 com.google.privacy.dlp.v2.Key.PathElement,
2558                 com.google.privacy.dlp.v2.Key.PathElement.Builder,
2559                 com.google.privacy.dlp.v2.Key.PathElementOrBuilder>(
2560                 path_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean());
2561         path_ = null;
2562       }
2563       return pathBuilder_;
2564     }
2565 
2566     @java.lang.Override
setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields)2567     public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
2568       return super.setUnknownFields(unknownFields);
2569     }
2570 
2571     @java.lang.Override
mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields)2572     public final Builder mergeUnknownFields(
2573         final com.google.protobuf.UnknownFieldSet unknownFields) {
2574       return super.mergeUnknownFields(unknownFields);
2575     }
2576 
2577     // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2.Key)
2578   }
2579 
2580   // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2.Key)
2581   private static final com.google.privacy.dlp.v2.Key DEFAULT_INSTANCE;
2582 
2583   static {
2584     DEFAULT_INSTANCE = new com.google.privacy.dlp.v2.Key();
2585   }
2586 
getDefaultInstance()2587   public static com.google.privacy.dlp.v2.Key getDefaultInstance() {
2588     return DEFAULT_INSTANCE;
2589   }
2590 
2591   private static final com.google.protobuf.Parser<Key> PARSER =
2592       new com.google.protobuf.AbstractParser<Key>() {
2593         @java.lang.Override
2594         public Key parsePartialFrom(
2595             com.google.protobuf.CodedInputStream input,
2596             com.google.protobuf.ExtensionRegistryLite extensionRegistry)
2597             throws com.google.protobuf.InvalidProtocolBufferException {
2598           Builder builder = newBuilder();
2599           try {
2600             builder.mergeFrom(input, extensionRegistry);
2601           } catch (com.google.protobuf.InvalidProtocolBufferException e) {
2602             throw e.setUnfinishedMessage(builder.buildPartial());
2603           } catch (com.google.protobuf.UninitializedMessageException e) {
2604             throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
2605           } catch (java.io.IOException e) {
2606             throw new com.google.protobuf.InvalidProtocolBufferException(e)
2607                 .setUnfinishedMessage(builder.buildPartial());
2608           }
2609           return builder.buildPartial();
2610         }
2611       };
2612 
parser()2613   public static com.google.protobuf.Parser<Key> parser() {
2614     return PARSER;
2615   }
2616 
2617   @java.lang.Override
getParserForType()2618   public com.google.protobuf.Parser<Key> getParserForType() {
2619     return PARSER;
2620   }
2621 
2622   @java.lang.Override
getDefaultInstanceForType()2623   public com.google.privacy.dlp.v2.Key getDefaultInstanceForType() {
2624     return DEFAULT_INSTANCE;
2625   }
2626 }
2627