// Generated by the protocol buffer compiler. DO NOT EDIT! // source: src/test/protobuf/test.proto package org.apache.avro.protobuf; public final class Test { private Test() {} public static void registerAllExtensions( com.google.protobuf.ExtensionRegistry registry) { } /** * Protobuf enum {@code org.apache.avro.protobuf.A} * * <pre> * an enum * </pre> */ public enum A implements com.google.protobuf.ProtocolMessageEnum { /** * <code>X = 1;</code> */ X(0, 1), /** * <code>Y = 2;</code> */ Y(1, 2), /** * <code>Z = 3;</code> */ Z(2, 3), ; /** * <code>X = 1;</code> */ public static final int X_VALUE = 1; /** * <code>Y = 2;</code> */ public static final int Y_VALUE = 2; /** * <code>Z = 3;</code> */ public static final int Z_VALUE = 3; public final int getNumber() { return value; } public static A valueOf(int value) { switch (value) { case 1: return X; case 2: return Y; case 3: return Z; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap<A> internalGetValueMap() { return internalValueMap; } private static com.google.protobuf.Internal.EnumLiteMap<A> internalValueMap = new com.google.protobuf.Internal.EnumLiteMap<A>() { public A findValueByNumber(int number) { return A.valueOf(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { return getDescriptor().getValues().get(index); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return org.apache.avro.protobuf.Test.getDescriptor().getEnumTypes().get(0); } private static final A[] VALUES = values(); public static A valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException( "EnumValueDescriptor is not for this type."); } return VALUES[desc.getIndex()]; } private final int index; private final int value; private A(int index, int value) { this.index = index; this.value = value; } // @@protoc_insertion_point(enum_scope:org.apache.avro.protobuf.A) } public interface FooOrBuilder extends com.google.protobuf.MessageOrBuilder { // required int32 int32 = 1; /** * <code>required int32 int32 = 1;</code> * * <pre> * all the primitive types * </pre> */ boolean hasInt32(); /** * <code>required int32 int32 = 1;</code> * * <pre> * all the primitive types * </pre> */ int getInt32(); // optional int64 int64 = 2; /** * <code>optional int64 int64 = 2;</code> */ boolean hasInt64(); /** * <code>optional int64 int64 = 2;</code> */ long getInt64(); // optional uint32 uint32 = 3; /** * <code>optional uint32 uint32 = 3;</code> */ boolean hasUint32(); /** * <code>optional uint32 uint32 = 3;</code> */ int getUint32(); // optional uint64 uint64 = 4; /** * <code>optional uint64 uint64 = 4;</code> */ boolean hasUint64(); /** * <code>optional uint64 uint64 = 4;</code> */ long getUint64(); // optional sint32 sint32 = 5; /** * <code>optional sint32 sint32 = 5;</code> */ boolean hasSint32(); /** * <code>optional sint32 sint32 = 5;</code> */ int getSint32(); // optional sint64 sint64 = 6; /** * <code>optional sint64 sint64 = 6;</code> */ boolean hasSint64(); /** * <code>optional sint64 sint64 = 6;</code> */ long getSint64(); // optional fixed32 fixed32 = 7; /** * <code>optional fixed32 fixed32 = 7;</code> */ boolean hasFixed32(); /** * <code>optional fixed32 fixed32 = 7;</code> */ int getFixed32(); // optional fixed64 fixed64 = 8; /** * <code>optional fixed64 fixed64 = 8;</code> */ boolean hasFixed64(); /** * <code>optional fixed64 fixed64 = 8;</code> */ long getFixed64(); // optional sfixed32 sfixed32 = 9; /** * <code>optional sfixed32 sfixed32 = 9;</code> */ boolean hasSfixed32(); /** * <code>optional sfixed32 sfixed32 = 9;</code> */ int getSfixed32(); // optional sfixed64 sfixed64 = 10; /** * <code>optional sfixed64 sfixed64 = 10;</code> */ boolean hasSfixed64(); /** * <code>optional sfixed64 sfixed64 = 10;</code> */ long getSfixed64(); // optional float float = 11; /** * <code>optional float float = 11;</code> */ boolean hasFloat(); /** * <code>optional float float = 11;</code> */ float getFloat(); // optional double double = 12; /** * <code>optional double double = 12;</code> */ boolean hasDouble(); /** * <code>optional double double = 12;</code> */ double getDouble(); // optional bool bool = 13; /** * <code>optional bool bool = 13;</code> */ boolean hasBool(); /** * <code>optional bool bool = 13;</code> */ boolean getBool(); // optional string string = 14; /** * <code>optional string string = 14;</code> */ boolean hasString(); /** * <code>optional string string = 14;</code> */ java.lang.String getString(); /** * <code>optional string string = 14;</code> */ com.google.protobuf.ByteString getStringBytes(); // optional bytes bytes = 15; /** * <code>optional bytes bytes = 15;</code> */ boolean hasBytes(); /** * <code>optional bytes bytes = 15;</code> */ com.google.protobuf.ByteString getBytes(); // optional .org.apache.avro.protobuf.A enum = 16 [default = Z]; /** * <code>optional .org.apache.avro.protobuf.A enum = 16 [default = Z];</code> */ boolean hasEnum(); /** * <code>optional .org.apache.avro.protobuf.A enum = 16 [default = Z];</code> */ org.apache.avro.protobuf.Test.A getEnum(); // repeated int32 intArray = 17; /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ java.util.List<java.lang.Integer> getIntArrayList(); /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ int getIntArrayCount(); /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ int getIntArray(int index); // repeated .org.apache.avro.protobuf.Foo fooArray = 20; /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ java.util.List<org.apache.avro.protobuf.Test.Foo> getFooArrayList(); /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ org.apache.avro.protobuf.Test.Foo getFooArray(int index); /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ int getFooArrayCount(); /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ java.util.List<? extends org.apache.avro.protobuf.Test.FooOrBuilder> getFooArrayOrBuilderList(); /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ org.apache.avro.protobuf.Test.FooOrBuilder getFooArrayOrBuilder( int index); // repeated .org.apache.avro.protobuf.A syms = 19; /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ java.util.List<org.apache.avro.protobuf.Test.A> getSymsList(); /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ int getSymsCount(); /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ org.apache.avro.protobuf.Test.A getSyms(int index); // optional .org.apache.avro.protobuf.Foo foo = 18; /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ boolean hasFoo(); /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ org.apache.avro.protobuf.Test.Foo getFoo(); /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ org.apache.avro.protobuf.Test.FooOrBuilder getFooOrBuilder(); } /** * Protobuf type {@code org.apache.avro.protobuf.Foo} */ public static final class Foo extends com.google.protobuf.GeneratedMessage implements FooOrBuilder { // Use Foo.newBuilder() to construct. private Foo(com.google.protobuf.GeneratedMessage.Builder<?> builder) { super(builder); this.unknownFields = builder.getUnknownFields(); } private Foo(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private static final Foo defaultInstance; public static Foo getDefaultInstance() { return defaultInstance; } public Foo getDefaultInstanceForType() { return defaultInstance; } private final com.google.protobuf.UnknownFieldSet unknownFields; @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } private Foo( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { initFields(); int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; } case 8: { bitField0_ |= 0x00000001; int32_ = input.readInt32(); break; } case 16: { bitField0_ |= 0x00000002; int64_ = input.readInt64(); break; } case 24: { bitField0_ |= 0x00000004; uint32_ = input.readUInt32(); break; } case 32: { bitField0_ |= 0x00000008; uint64_ = input.readUInt64(); break; } case 40: { bitField0_ |= 0x00000010; sint32_ = input.readSInt32(); break; } case 48: { bitField0_ |= 0x00000020; sint64_ = input.readSInt64(); break; } case 61: { bitField0_ |= 0x00000040; fixed32_ = input.readFixed32(); break; } case 65: { bitField0_ |= 0x00000080; fixed64_ = input.readFixed64(); break; } case 77: { bitField0_ |= 0x00000100; sfixed32_ = input.readSFixed32(); break; } case 81: { bitField0_ |= 0x00000200; sfixed64_ = input.readSFixed64(); break; } case 93: { bitField0_ |= 0x00000400; float_ = input.readFloat(); break; } case 97: { bitField0_ |= 0x00000800; double_ = input.readDouble(); break; } case 104: { bitField0_ |= 0x00001000; bool_ = input.readBool(); break; } case 114: { bitField0_ |= 0x00002000; string_ = input.readBytes(); break; } case 122: { bitField0_ |= 0x00004000; bytes_ = input.readBytes(); break; } case 128: { int rawValue = input.readEnum(); org.apache.avro.protobuf.Test.A value = org.apache.avro.protobuf.Test.A.valueOf(rawValue); if (value == null) { unknownFields.mergeVarintField(16, rawValue); } else { bitField0_ |= 0x00008000; enum_ = value; } break; } case 136: { if (!((mutable_bitField0_ & 0x00010000) == 0x00010000)) { intArray_ = new java.util.ArrayList<java.lang.Integer>(); mutable_bitField0_ |= 0x00010000; } intArray_.add(input.readInt32()); break; } case 138: { int length = input.readRawVarint32(); int limit = input.pushLimit(length); if (!((mutable_bitField0_ & 0x00010000) == 0x00010000) && input.getBytesUntilLimit() > 0) { intArray_ = new java.util.ArrayList<java.lang.Integer>(); mutable_bitField0_ |= 0x00010000; } while (input.getBytesUntilLimit() > 0) { intArray_.add(input.readInt32()); } input.popLimit(limit); break; } case 146: { org.apache.avro.protobuf.Test.Foo.Builder subBuilder = null; if (((bitField0_ & 0x00010000) == 0x00010000)) { subBuilder = foo_.toBuilder(); } foo_ = input.readMessage(org.apache.avro.protobuf.Test.Foo.PARSER, extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(foo_); foo_ = subBuilder.buildPartial(); } bitField0_ |= 0x00010000; break; } case 152: { int rawValue = input.readEnum(); org.apache.avro.protobuf.Test.A value = org.apache.avro.protobuf.Test.A.valueOf(rawValue); if (value == null) { unknownFields.mergeVarintField(19, rawValue); } else { if (!((mutable_bitField0_ & 0x00040000) == 0x00040000)) { syms_ = new java.util.ArrayList<org.apache.avro.protobuf.Test.A>(); mutable_bitField0_ |= 0x00040000; } syms_.add(value); } break; } case 154: { int length = input.readRawVarint32(); int oldLimit = input.pushLimit(length); while(input.getBytesUntilLimit() > 0) { int rawValue = input.readEnum(); org.apache.avro.protobuf.Test.A value = org.apache.avro.protobuf.Test.A.valueOf(rawValue); if (value == null) { unknownFields.mergeVarintField(19, rawValue); } else { if (!((mutable_bitField0_ & 0x00040000) == 0x00040000)) { syms_ = new java.util.ArrayList<org.apache.avro.protobuf.Test.A>(); mutable_bitField0_ |= 0x00040000; } syms_.add(value); } } input.popLimit(oldLimit); break; } case 162: { if (!((mutable_bitField0_ & 0x00020000) == 0x00020000)) { fooArray_ = new java.util.ArrayList<org.apache.avro.protobuf.Test.Foo>(); mutable_bitField0_ |= 0x00020000; } fooArray_.add(input.readMessage(org.apache.avro.protobuf.Test.Foo.PARSER, extensionRegistry)); break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e.getMessage()).setUnfinishedMessage(this); } finally { if (((mutable_bitField0_ & 0x00010000) == 0x00010000)) { intArray_ = java.util.Collections.unmodifiableList(intArray_); } if (((mutable_bitField0_ & 0x00040000) == 0x00040000)) { syms_ = java.util.Collections.unmodifiableList(syms_); } if (((mutable_bitField0_ & 0x00020000) == 0x00020000)) { fooArray_ = java.util.Collections.unmodifiableList(fooArray_); } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.apache.avro.protobuf.Test.internal_static_org_apache_avro_protobuf_Foo_descriptor; } protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { return org.apache.avro.protobuf.Test.internal_static_org_apache_avro_protobuf_Foo_fieldAccessorTable .ensureFieldAccessorsInitialized( org.apache.avro.protobuf.Test.Foo.class, org.apache.avro.protobuf.Test.Foo.Builder.class); } public static com.google.protobuf.Parser<Foo> PARSER = new com.google.protobuf.AbstractParser<Foo>() { public Foo parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new Foo(input, extensionRegistry); } }; @java.lang.Override public com.google.protobuf.Parser<Foo> getParserForType() { return PARSER; } private int bitField0_; // required int32 int32 = 1; public static final int INT32_FIELD_NUMBER = 1; private int int32_; /** * <code>required int32 int32 = 1;</code> * * <pre> * all the primitive types * </pre> */ public boolean hasInt32() { return ((bitField0_ & 0x00000001) == 0x00000001); } /** * <code>required int32 int32 = 1;</code> * * <pre> * all the primitive types * </pre> */ public int getInt32() { return int32_; } // optional int64 int64 = 2; public static final int INT64_FIELD_NUMBER = 2; private long int64_; /** * <code>optional int64 int64 = 2;</code> */ public boolean hasInt64() { return ((bitField0_ & 0x00000002) == 0x00000002); } /** * <code>optional int64 int64 = 2;</code> */ public long getInt64() { return int64_; } // optional uint32 uint32 = 3; public static final int UINT32_FIELD_NUMBER = 3; private int uint32_; /** * <code>optional uint32 uint32 = 3;</code> */ public boolean hasUint32() { return ((bitField0_ & 0x00000004) == 0x00000004); } /** * <code>optional uint32 uint32 = 3;</code> */ public int getUint32() { return uint32_; } // optional uint64 uint64 = 4; public static final int UINT64_FIELD_NUMBER = 4; private long uint64_; /** * <code>optional uint64 uint64 = 4;</code> */ public boolean hasUint64() { return ((bitField0_ & 0x00000008) == 0x00000008); } /** * <code>optional uint64 uint64 = 4;</code> */ public long getUint64() { return uint64_; } // optional sint32 sint32 = 5; public static final int SINT32_FIELD_NUMBER = 5; private int sint32_; /** * <code>optional sint32 sint32 = 5;</code> */ public boolean hasSint32() { return ((bitField0_ & 0x00000010) == 0x00000010); } /** * <code>optional sint32 sint32 = 5;</code> */ public int getSint32() { return sint32_; } // optional sint64 sint64 = 6; public static final int SINT64_FIELD_NUMBER = 6; private long sint64_; /** * <code>optional sint64 sint64 = 6;</code> */ public boolean hasSint64() { return ((bitField0_ & 0x00000020) == 0x00000020); } /** * <code>optional sint64 sint64 = 6;</code> */ public long getSint64() { return sint64_; } // optional fixed32 fixed32 = 7; public static final int FIXED32_FIELD_NUMBER = 7; private int fixed32_; /** * <code>optional fixed32 fixed32 = 7;</code> */ public boolean hasFixed32() { return ((bitField0_ & 0x00000040) == 0x00000040); } /** * <code>optional fixed32 fixed32 = 7;</code> */ public int getFixed32() { return fixed32_; } // optional fixed64 fixed64 = 8; public static final int FIXED64_FIELD_NUMBER = 8; private long fixed64_; /** * <code>optional fixed64 fixed64 = 8;</code> */ public boolean hasFixed64() { return ((bitField0_ & 0x00000080) == 0x00000080); } /** * <code>optional fixed64 fixed64 = 8;</code> */ public long getFixed64() { return fixed64_; } // optional sfixed32 sfixed32 = 9; public static final int SFIXED32_FIELD_NUMBER = 9; private int sfixed32_; /** * <code>optional sfixed32 sfixed32 = 9;</code> */ public boolean hasSfixed32() { return ((bitField0_ & 0x00000100) == 0x00000100); } /** * <code>optional sfixed32 sfixed32 = 9;</code> */ public int getSfixed32() { return sfixed32_; } // optional sfixed64 sfixed64 = 10; public static final int SFIXED64_FIELD_NUMBER = 10; private long sfixed64_; /** * <code>optional sfixed64 sfixed64 = 10;</code> */ public boolean hasSfixed64() { return ((bitField0_ & 0x00000200) == 0x00000200); } /** * <code>optional sfixed64 sfixed64 = 10;</code> */ public long getSfixed64() { return sfixed64_; } // optional float float = 11; public static final int FLOAT_FIELD_NUMBER = 11; private float float_; /** * <code>optional float float = 11;</code> */ public boolean hasFloat() { return ((bitField0_ & 0x00000400) == 0x00000400); } /** * <code>optional float float = 11;</code> */ public float getFloat() { return float_; } // optional double double = 12; public static final int DOUBLE_FIELD_NUMBER = 12; private double double_; /** * <code>optional double double = 12;</code> */ public boolean hasDouble() { return ((bitField0_ & 0x00000800) == 0x00000800); } /** * <code>optional double double = 12;</code> */ public double getDouble() { return double_; } // optional bool bool = 13; public static final int BOOL_FIELD_NUMBER = 13; private boolean bool_; /** * <code>optional bool bool = 13;</code> */ public boolean hasBool() { return ((bitField0_ & 0x00001000) == 0x00001000); } /** * <code>optional bool bool = 13;</code> */ public boolean getBool() { return bool_; } // optional string string = 14; public static final int STRING_FIELD_NUMBER = 14; private java.lang.Object string_; /** * <code>optional string string = 14;</code> */ public boolean hasString() { return ((bitField0_ & 0x00002000) == 0x00002000); } /** * <code>optional string string = 14;</code> */ public java.lang.String getString() { java.lang.Object ref = string_; if (ref instanceof java.lang.String) { return (java.lang.String) ref; } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); if (bs.isValidUtf8()) { string_ = s; } return s; } } /** * <code>optional string string = 14;</code> */ public com.google.protobuf.ByteString getStringBytes() { java.lang.Object ref = string_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); string_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } // optional bytes bytes = 15; public static final int BYTES_FIELD_NUMBER = 15; private com.google.protobuf.ByteString bytes_; /** * <code>optional bytes bytes = 15;</code> */ public boolean hasBytes() { return ((bitField0_ & 0x00004000) == 0x00004000); } /** * <code>optional bytes bytes = 15;</code> */ public com.google.protobuf.ByteString getBytes() { return bytes_; } // optional .org.apache.avro.protobuf.A enum = 16 [default = Z]; public static final int ENUM_FIELD_NUMBER = 16; private org.apache.avro.protobuf.Test.A enum_; /** * <code>optional .org.apache.avro.protobuf.A enum = 16 [default = Z];</code> */ public boolean hasEnum() { return ((bitField0_ & 0x00008000) == 0x00008000); } /** * <code>optional .org.apache.avro.protobuf.A enum = 16 [default = Z];</code> */ public org.apache.avro.protobuf.Test.A getEnum() { return enum_; } // repeated int32 intArray = 17; public static final int INTARRAY_FIELD_NUMBER = 17; private java.util.List<java.lang.Integer> intArray_; /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ public java.util.List<java.lang.Integer> getIntArrayList() { return intArray_; } /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ public int getIntArrayCount() { return intArray_.size(); } /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ public int getIntArray(int index) { return intArray_.get(index); } // repeated .org.apache.avro.protobuf.Foo fooArray = 20; public static final int FOOARRAY_FIELD_NUMBER = 20; private java.util.List<org.apache.avro.protobuf.Test.Foo> fooArray_; /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public java.util.List<org.apache.avro.protobuf.Test.Foo> getFooArrayList() { return fooArray_; } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public java.util.List<? extends org.apache.avro.protobuf.Test.FooOrBuilder> getFooArrayOrBuilderList() { return fooArray_; } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public int getFooArrayCount() { return fooArray_.size(); } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public org.apache.avro.protobuf.Test.Foo getFooArray(int index) { return fooArray_.get(index); } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public org.apache.avro.protobuf.Test.FooOrBuilder getFooArrayOrBuilder( int index) { return fooArray_.get(index); } // repeated .org.apache.avro.protobuf.A syms = 19; public static final int SYMS_FIELD_NUMBER = 19; private java.util.List<org.apache.avro.protobuf.Test.A> syms_; /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ public java.util.List<org.apache.avro.protobuf.Test.A> getSymsList() { return syms_; } /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ public int getSymsCount() { return syms_.size(); } /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ public org.apache.avro.protobuf.Test.A getSyms(int index) { return syms_.get(index); } // optional .org.apache.avro.protobuf.Foo foo = 18; public static final int FOO_FIELD_NUMBER = 18; private org.apache.avro.protobuf.Test.Foo foo_; /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ public boolean hasFoo() { return ((bitField0_ & 0x00010000) == 0x00010000); } /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ public org.apache.avro.protobuf.Test.Foo getFoo() { return foo_; } /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ public org.apache.avro.protobuf.Test.FooOrBuilder getFooOrBuilder() { return foo_; } private void initFields() { int32_ = 0; int64_ = 0L; uint32_ = 0; uint64_ = 0L; sint32_ = 0; sint64_ = 0L; fixed32_ = 0; fixed64_ = 0L; sfixed32_ = 0; sfixed64_ = 0L; float_ = 0F; double_ = 0D; bool_ = false; string_ = ""; bytes_ = com.google.protobuf.ByteString.EMPTY; enum_ = org.apache.avro.protobuf.Test.A.Z; intArray_ = java.util.Collections.emptyList(); fooArray_ = java.util.Collections.emptyList(); syms_ = java.util.Collections.emptyList(); foo_ = org.apache.avro.protobuf.Test.Foo.getDefaultInstance(); } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized != -1) return isInitialized == 1; if (!hasInt32()) { memoizedIsInitialized = 0; return false; } for (int i = 0; i < getFooArrayCount(); i++) { if (!getFooArray(i).isInitialized()) { memoizedIsInitialized = 0; return false; } } if (hasFoo()) { if (!getFoo().isInitialized()) { memoizedIsInitialized = 0; return false; } } memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { getSerializedSize(); if (((bitField0_ & 0x00000001) == 0x00000001)) { output.writeInt32(1, int32_); } if (((bitField0_ & 0x00000002) == 0x00000002)) { output.writeInt64(2, int64_); } if (((bitField0_ & 0x00000004) == 0x00000004)) { output.writeUInt32(3, uint32_); } if (((bitField0_ & 0x00000008) == 0x00000008)) { output.writeUInt64(4, uint64_); } if (((bitField0_ & 0x00000010) == 0x00000010)) { output.writeSInt32(5, sint32_); } if (((bitField0_ & 0x00000020) == 0x00000020)) { output.writeSInt64(6, sint64_); } if (((bitField0_ & 0x00000040) == 0x00000040)) { output.writeFixed32(7, fixed32_); } if (((bitField0_ & 0x00000080) == 0x00000080)) { output.writeFixed64(8, fixed64_); } if (((bitField0_ & 0x00000100) == 0x00000100)) { output.writeSFixed32(9, sfixed32_); } if (((bitField0_ & 0x00000200) == 0x00000200)) { output.writeSFixed64(10, sfixed64_); } if (((bitField0_ & 0x00000400) == 0x00000400)) { output.writeFloat(11, float_); } if (((bitField0_ & 0x00000800) == 0x00000800)) { output.writeDouble(12, double_); } if (((bitField0_ & 0x00001000) == 0x00001000)) { output.writeBool(13, bool_); } if (((bitField0_ & 0x00002000) == 0x00002000)) { output.writeBytes(14, getStringBytes()); } if (((bitField0_ & 0x00004000) == 0x00004000)) { output.writeBytes(15, bytes_); } if (((bitField0_ & 0x00008000) == 0x00008000)) { output.writeEnum(16, enum_.getNumber()); } for (int i = 0; i < intArray_.size(); i++) { output.writeInt32(17, intArray_.get(i)); } if (((bitField0_ & 0x00010000) == 0x00010000)) { output.writeMessage(18, foo_); } for (int i = 0; i < syms_.size(); i++) { output.writeEnum(19, syms_.get(i).getNumber()); } for (int i = 0; i < fooArray_.size(); i++) { output.writeMessage(20, fooArray_.get(i)); } getUnknownFields().writeTo(output); } private int memoizedSerializedSize = -1; public int getSerializedSize() { int size = memoizedSerializedSize; if (size != -1) return size; size = 0; if (((bitField0_ & 0x00000001) == 0x00000001)) { size += com.google.protobuf.CodedOutputStream .computeInt32Size(1, int32_); } if (((bitField0_ & 0x00000002) == 0x00000002)) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(2, int64_); } if (((bitField0_ & 0x00000004) == 0x00000004)) { size += com.google.protobuf.CodedOutputStream .computeUInt32Size(3, uint32_); } if (((bitField0_ & 0x00000008) == 0x00000008)) { size += com.google.protobuf.CodedOutputStream .computeUInt64Size(4, uint64_); } if (((bitField0_ & 0x00000010) == 0x00000010)) { size += com.google.protobuf.CodedOutputStream .computeSInt32Size(5, sint32_); } if (((bitField0_ & 0x00000020) == 0x00000020)) { size += com.google.protobuf.CodedOutputStream .computeSInt64Size(6, sint64_); } if (((bitField0_ & 0x00000040) == 0x00000040)) { size += com.google.protobuf.CodedOutputStream .computeFixed32Size(7, fixed32_); } if (((bitField0_ & 0x00000080) == 0x00000080)) { size += com.google.protobuf.CodedOutputStream .computeFixed64Size(8, fixed64_); } if (((bitField0_ & 0x00000100) == 0x00000100)) { size += com.google.protobuf.CodedOutputStream .computeSFixed32Size(9, sfixed32_); } if (((bitField0_ & 0x00000200) == 0x00000200)) { size += com.google.protobuf.CodedOutputStream .computeSFixed64Size(10, sfixed64_); } if (((bitField0_ & 0x00000400) == 0x00000400)) { size += com.google.protobuf.CodedOutputStream .computeFloatSize(11, float_); } if (((bitField0_ & 0x00000800) == 0x00000800)) { size += com.google.protobuf.CodedOutputStream .computeDoubleSize(12, double_); } if (((bitField0_ & 0x00001000) == 0x00001000)) { size += com.google.protobuf.CodedOutputStream .computeBoolSize(13, bool_); } if (((bitField0_ & 0x00002000) == 0x00002000)) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(14, getStringBytes()); } if (((bitField0_ & 0x00004000) == 0x00004000)) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(15, bytes_); } if (((bitField0_ & 0x00008000) == 0x00008000)) { size += com.google.protobuf.CodedOutputStream .computeEnumSize(16, enum_.getNumber()); } { int dataSize = 0; for (int i = 0; i < intArray_.size(); i++) { dataSize += com.google.protobuf.CodedOutputStream .computeInt32SizeNoTag(intArray_.get(i)); } size += dataSize; size += 2 * getIntArrayList().size(); } if (((bitField0_ & 0x00010000) == 0x00010000)) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(18, foo_); } { int dataSize = 0; for (int i = 0; i < syms_.size(); i++) { dataSize += com.google.protobuf.CodedOutputStream .computeEnumSizeNoTag(syms_.get(i).getNumber()); } size += dataSize; size += 2 * syms_.size(); } for (int i = 0; i < fooArray_.size(); i++) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(20, fooArray_.get(i)); } size += getUnknownFields().getSerializedSize(); memoizedSerializedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override protected java.lang.Object writeReplace() throws java.io.ObjectStreamException { return super.writeReplace(); } public static org.apache.avro.protobuf.Test.Foo parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.apache.avro.protobuf.Test.Foo parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.apache.avro.protobuf.Test.Foo parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.apache.avro.protobuf.Test.Foo parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.apache.avro.protobuf.Test.Foo parseFrom(java.io.InputStream input) throws java.io.IOException { return PARSER.parseFrom(input); } public static org.apache.avro.protobuf.Test.Foo parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return PARSER.parseFrom(input, extensionRegistry); } public static org.apache.avro.protobuf.Test.Foo parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return PARSER.parseDelimitedFrom(input); } public static org.apache.avro.protobuf.Test.Foo parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return PARSER.parseDelimitedFrom(input, extensionRegistry); } public static org.apache.avro.protobuf.Test.Foo parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return PARSER.parseFrom(input); } public static org.apache.avro.protobuf.Test.Foo parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return PARSER.parseFrom(input, extensionRegistry); } public static Builder newBuilder() { return Builder.create(); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder(org.apache.avro.protobuf.Test.Foo prototype) { return newBuilder().mergeFrom(prototype); } public Builder toBuilder() { return newBuilder(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessage.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.apache.avro.protobuf.Foo} */ public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder<Builder> implements org.apache.avro.protobuf.Test.FooOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.apache.avro.protobuf.Test.internal_static_org_apache_avro_protobuf_Foo_descriptor; } protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { return org.apache.avro.protobuf.Test.internal_static_org_apache_avro_protobuf_Foo_fieldAccessorTable .ensureFieldAccessorsInitialized( org.apache.avro.protobuf.Test.Foo.class, org.apache.avro.protobuf.Test.Foo.Builder.class); } // Construct using org.apache.avro.protobuf.Test.Foo.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessage.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { getFooArrayFieldBuilder(); getFooFieldBuilder(); } } private static Builder create() { return new Builder(); } public Builder clear() { super.clear(); int32_ = 0; bitField0_ = (bitField0_ & ~0x00000001); int64_ = 0L; bitField0_ = (bitField0_ & ~0x00000002); uint32_ = 0; bitField0_ = (bitField0_ & ~0x00000004); uint64_ = 0L; bitField0_ = (bitField0_ & ~0x00000008); sint32_ = 0; bitField0_ = (bitField0_ & ~0x00000010); sint64_ = 0L; bitField0_ = (bitField0_ & ~0x00000020); fixed32_ = 0; bitField0_ = (bitField0_ & ~0x00000040); fixed64_ = 0L; bitField0_ = (bitField0_ & ~0x00000080); sfixed32_ = 0; bitField0_ = (bitField0_ & ~0x00000100); sfixed64_ = 0L; bitField0_ = (bitField0_ & ~0x00000200); float_ = 0F; bitField0_ = (bitField0_ & ~0x00000400); double_ = 0D; bitField0_ = (bitField0_ & ~0x00000800); bool_ = false; bitField0_ = (bitField0_ & ~0x00001000); string_ = ""; bitField0_ = (bitField0_ & ~0x00002000); bytes_ = com.google.protobuf.ByteString.EMPTY; bitField0_ = (bitField0_ & ~0x00004000); enum_ = org.apache.avro.protobuf.Test.A.Z; bitField0_ = (bitField0_ & ~0x00008000); intArray_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00010000); if (fooArrayBuilder_ == null) { fooArray_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00020000); } else { fooArrayBuilder_.clear(); } syms_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00040000); if (fooBuilder_ == null) { foo_ = org.apache.avro.protobuf.Test.Foo.getDefaultInstance(); } else { fooBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00080000); return this; } public Builder clone() { return create().mergeFrom(buildPartial()); } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.apache.avro.protobuf.Test.internal_static_org_apache_avro_protobuf_Foo_descriptor; } public org.apache.avro.protobuf.Test.Foo getDefaultInstanceForType() { return org.apache.avro.protobuf.Test.Foo.getDefaultInstance(); } public org.apache.avro.protobuf.Test.Foo build() { org.apache.avro.protobuf.Test.Foo result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.apache.avro.protobuf.Test.Foo buildPartial() { org.apache.avro.protobuf.Test.Foo result = new org.apache.avro.protobuf.Test.Foo(this); int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (((from_bitField0_ & 0x00000001) == 0x00000001)) { to_bitField0_ |= 0x00000001; } result.int32_ = int32_; if (((from_bitField0_ & 0x00000002) == 0x00000002)) { to_bitField0_ |= 0x00000002; } result.int64_ = int64_; if (((from_bitField0_ & 0x00000004) == 0x00000004)) { to_bitField0_ |= 0x00000004; } result.uint32_ = uint32_; if (((from_bitField0_ & 0x00000008) == 0x00000008)) { to_bitField0_ |= 0x00000008; } result.uint64_ = uint64_; if (((from_bitField0_ & 0x00000010) == 0x00000010)) { to_bitField0_ |= 0x00000010; } result.sint32_ = sint32_; if (((from_bitField0_ & 0x00000020) == 0x00000020)) { to_bitField0_ |= 0x00000020; } result.sint64_ = sint64_; if (((from_bitField0_ & 0x00000040) == 0x00000040)) { to_bitField0_ |= 0x00000040; } result.fixed32_ = fixed32_; if (((from_bitField0_ & 0x00000080) == 0x00000080)) { to_bitField0_ |= 0x00000080; } result.fixed64_ = fixed64_; if (((from_bitField0_ & 0x00000100) == 0x00000100)) { to_bitField0_ |= 0x00000100; } result.sfixed32_ = sfixed32_; if (((from_bitField0_ & 0x00000200) == 0x00000200)) { to_bitField0_ |= 0x00000200; } result.sfixed64_ = sfixed64_; if (((from_bitField0_ & 0x00000400) == 0x00000400)) { to_bitField0_ |= 0x00000400; } result.float_ = float_; if (((from_bitField0_ & 0x00000800) == 0x00000800)) { to_bitField0_ |= 0x00000800; } result.double_ = double_; if (((from_bitField0_ & 0x00001000) == 0x00001000)) { to_bitField0_ |= 0x00001000; } result.bool_ = bool_; if (((from_bitField0_ & 0x00002000) == 0x00002000)) { to_bitField0_ |= 0x00002000; } result.string_ = string_; if (((from_bitField0_ & 0x00004000) == 0x00004000)) { to_bitField0_ |= 0x00004000; } result.bytes_ = bytes_; if (((from_bitField0_ & 0x00008000) == 0x00008000)) { to_bitField0_ |= 0x00008000; } result.enum_ = enum_; if (((bitField0_ & 0x00010000) == 0x00010000)) { intArray_ = java.util.Collections.unmodifiableList(intArray_); bitField0_ = (bitField0_ & ~0x00010000); } result.intArray_ = intArray_; if (fooArrayBuilder_ == null) { if (((bitField0_ & 0x00020000) == 0x00020000)) { fooArray_ = java.util.Collections.unmodifiableList(fooArray_); bitField0_ = (bitField0_ & ~0x00020000); } result.fooArray_ = fooArray_; } else { result.fooArray_ = fooArrayBuilder_.build(); } if (((bitField0_ & 0x00040000) == 0x00040000)) { syms_ = java.util.Collections.unmodifiableList(syms_); bitField0_ = (bitField0_ & ~0x00040000); } result.syms_ = syms_; if (((from_bitField0_ & 0x00080000) == 0x00080000)) { to_bitField0_ |= 0x00010000; } if (fooBuilder_ == null) { result.foo_ = foo_; } else { result.foo_ = fooBuilder_.build(); } result.bitField0_ = to_bitField0_; onBuilt(); return result; } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.apache.avro.protobuf.Test.Foo) { return mergeFrom((org.apache.avro.protobuf.Test.Foo)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.apache.avro.protobuf.Test.Foo other) { if (other == org.apache.avro.protobuf.Test.Foo.getDefaultInstance()) return this; if (other.hasInt32()) { setInt32(other.getInt32()); } if (other.hasInt64()) { setInt64(other.getInt64()); } if (other.hasUint32()) { setUint32(other.getUint32()); } if (other.hasUint64()) { setUint64(other.getUint64()); } if (other.hasSint32()) { setSint32(other.getSint32()); } if (other.hasSint64()) { setSint64(other.getSint64()); } if (other.hasFixed32()) { setFixed32(other.getFixed32()); } if (other.hasFixed64()) { setFixed64(other.getFixed64()); } if (other.hasSfixed32()) { setSfixed32(other.getSfixed32()); } if (other.hasSfixed64()) { setSfixed64(other.getSfixed64()); } if (other.hasFloat()) { setFloat(other.getFloat()); } if (other.hasDouble()) { setDouble(other.getDouble()); } if (other.hasBool()) { setBool(other.getBool()); } if (other.hasString()) { bitField0_ |= 0x00002000; string_ = other.string_; onChanged(); } if (other.hasBytes()) { setBytes(other.getBytes()); } if (other.hasEnum()) { setEnum(other.getEnum()); } if (!other.intArray_.isEmpty()) { if (intArray_.isEmpty()) { intArray_ = other.intArray_; bitField0_ = (bitField0_ & ~0x00010000); } else { ensureIntArrayIsMutable(); intArray_.addAll(other.intArray_); } onChanged(); } if (fooArrayBuilder_ == null) { if (!other.fooArray_.isEmpty()) { if (fooArray_.isEmpty()) { fooArray_ = other.fooArray_; bitField0_ = (bitField0_ & ~0x00020000); } else { ensureFooArrayIsMutable(); fooArray_.addAll(other.fooArray_); } onChanged(); } } else { if (!other.fooArray_.isEmpty()) { if (fooArrayBuilder_.isEmpty()) { fooArrayBuilder_.dispose(); fooArrayBuilder_ = null; fooArray_ = other.fooArray_; bitField0_ = (bitField0_ & ~0x00020000); fooArrayBuilder_ = com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? getFooArrayFieldBuilder() : null; } else { fooArrayBuilder_.addAllMessages(other.fooArray_); } } } if (!other.syms_.isEmpty()) { if (syms_.isEmpty()) { syms_ = other.syms_; bitField0_ = (bitField0_ & ~0x00040000); } else { ensureSymsIsMutable(); syms_.addAll(other.syms_); } onChanged(); } if (other.hasFoo()) { mergeFoo(other.getFoo()); } this.mergeUnknownFields(other.getUnknownFields()); return this; } public final boolean isInitialized() { if (!hasInt32()) { return false; } for (int i = 0; i < getFooArrayCount(); i++) { if (!getFooArray(i).isInitialized()) { return false; } } if (hasFoo()) { if (!getFoo().isInitialized()) { return false; } } return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.apache.avro.protobuf.Test.Foo parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.apache.avro.protobuf.Test.Foo) e.getUnfinishedMessage(); throw e; } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int bitField0_; // required int32 int32 = 1; private int int32_ ; /** * <code>required int32 int32 = 1;</code> * * <pre> * all the primitive types * </pre> */ public boolean hasInt32() { return ((bitField0_ & 0x00000001) == 0x00000001); } /** * <code>required int32 int32 = 1;</code> * * <pre> * all the primitive types * </pre> */ public int getInt32() { return int32_; } /** * <code>required int32 int32 = 1;</code> * * <pre> * all the primitive types * </pre> */ public Builder setInt32(int value) { bitField0_ |= 0x00000001; int32_ = value; onChanged(); return this; } /** * <code>required int32 int32 = 1;</code> * * <pre> * all the primitive types * </pre> */ public Builder clearInt32() { bitField0_ = (bitField0_ & ~0x00000001); int32_ = 0; onChanged(); return this; } // optional int64 int64 = 2; private long int64_ ; /** * <code>optional int64 int64 = 2;</code> */ public boolean hasInt64() { return ((bitField0_ & 0x00000002) == 0x00000002); } /** * <code>optional int64 int64 = 2;</code> */ public long getInt64() { return int64_; } /** * <code>optional int64 int64 = 2;</code> */ public Builder setInt64(long value) { bitField0_ |= 0x00000002; int64_ = value; onChanged(); return this; } /** * <code>optional int64 int64 = 2;</code> */ public Builder clearInt64() { bitField0_ = (bitField0_ & ~0x00000002); int64_ = 0L; onChanged(); return this; } // optional uint32 uint32 = 3; private int uint32_ ; /** * <code>optional uint32 uint32 = 3;</code> */ public boolean hasUint32() { return ((bitField0_ & 0x00000004) == 0x00000004); } /** * <code>optional uint32 uint32 = 3;</code> */ public int getUint32() { return uint32_; } /** * <code>optional uint32 uint32 = 3;</code> */ public Builder setUint32(int value) { bitField0_ |= 0x00000004; uint32_ = value; onChanged(); return this; } /** * <code>optional uint32 uint32 = 3;</code> */ public Builder clearUint32() { bitField0_ = (bitField0_ & ~0x00000004); uint32_ = 0; onChanged(); return this; } // optional uint64 uint64 = 4; private long uint64_ ; /** * <code>optional uint64 uint64 = 4;</code> */ public boolean hasUint64() { return ((bitField0_ & 0x00000008) == 0x00000008); } /** * <code>optional uint64 uint64 = 4;</code> */ public long getUint64() { return uint64_; } /** * <code>optional uint64 uint64 = 4;</code> */ public Builder setUint64(long value) { bitField0_ |= 0x00000008; uint64_ = value; onChanged(); return this; } /** * <code>optional uint64 uint64 = 4;</code> */ public Builder clearUint64() { bitField0_ = (bitField0_ & ~0x00000008); uint64_ = 0L; onChanged(); return this; } // optional sint32 sint32 = 5; private int sint32_ ; /** * <code>optional sint32 sint32 = 5;</code> */ public boolean hasSint32() { return ((bitField0_ & 0x00000010) == 0x00000010); } /** * <code>optional sint32 sint32 = 5;</code> */ public int getSint32() { return sint32_; } /** * <code>optional sint32 sint32 = 5;</code> */ public Builder setSint32(int value) { bitField0_ |= 0x00000010; sint32_ = value; onChanged(); return this; } /** * <code>optional sint32 sint32 = 5;</code> */ public Builder clearSint32() { bitField0_ = (bitField0_ & ~0x00000010); sint32_ = 0; onChanged(); return this; } // optional sint64 sint64 = 6; private long sint64_ ; /** * <code>optional sint64 sint64 = 6;</code> */ public boolean hasSint64() { return ((bitField0_ & 0x00000020) == 0x00000020); } /** * <code>optional sint64 sint64 = 6;</code> */ public long getSint64() { return sint64_; } /** * <code>optional sint64 sint64 = 6;</code> */ public Builder setSint64(long value) { bitField0_ |= 0x00000020; sint64_ = value; onChanged(); return this; } /** * <code>optional sint64 sint64 = 6;</code> */ public Builder clearSint64() { bitField0_ = (bitField0_ & ~0x00000020); sint64_ = 0L; onChanged(); return this; } // optional fixed32 fixed32 = 7; private int fixed32_ ; /** * <code>optional fixed32 fixed32 = 7;</code> */ public boolean hasFixed32() { return ((bitField0_ & 0x00000040) == 0x00000040); } /** * <code>optional fixed32 fixed32 = 7;</code> */ public int getFixed32() { return fixed32_; } /** * <code>optional fixed32 fixed32 = 7;</code> */ public Builder setFixed32(int value) { bitField0_ |= 0x00000040; fixed32_ = value; onChanged(); return this; } /** * <code>optional fixed32 fixed32 = 7;</code> */ public Builder clearFixed32() { bitField0_ = (bitField0_ & ~0x00000040); fixed32_ = 0; onChanged(); return this; } // optional fixed64 fixed64 = 8; private long fixed64_ ; /** * <code>optional fixed64 fixed64 = 8;</code> */ public boolean hasFixed64() { return ((bitField0_ & 0x00000080) == 0x00000080); } /** * <code>optional fixed64 fixed64 = 8;</code> */ public long getFixed64() { return fixed64_; } /** * <code>optional fixed64 fixed64 = 8;</code> */ public Builder setFixed64(long value) { bitField0_ |= 0x00000080; fixed64_ = value; onChanged(); return this; } /** * <code>optional fixed64 fixed64 = 8;</code> */ public Builder clearFixed64() { bitField0_ = (bitField0_ & ~0x00000080); fixed64_ = 0L; onChanged(); return this; } // optional sfixed32 sfixed32 = 9; private int sfixed32_ ; /** * <code>optional sfixed32 sfixed32 = 9;</code> */ public boolean hasSfixed32() { return ((bitField0_ & 0x00000100) == 0x00000100); } /** * <code>optional sfixed32 sfixed32 = 9;</code> */ public int getSfixed32() { return sfixed32_; } /** * <code>optional sfixed32 sfixed32 = 9;</code> */ public Builder setSfixed32(int value) { bitField0_ |= 0x00000100; sfixed32_ = value; onChanged(); return this; } /** * <code>optional sfixed32 sfixed32 = 9;</code> */ public Builder clearSfixed32() { bitField0_ = (bitField0_ & ~0x00000100); sfixed32_ = 0; onChanged(); return this; } // optional sfixed64 sfixed64 = 10; private long sfixed64_ ; /** * <code>optional sfixed64 sfixed64 = 10;</code> */ public boolean hasSfixed64() { return ((bitField0_ & 0x00000200) == 0x00000200); } /** * <code>optional sfixed64 sfixed64 = 10;</code> */ public long getSfixed64() { return sfixed64_; } /** * <code>optional sfixed64 sfixed64 = 10;</code> */ public Builder setSfixed64(long value) { bitField0_ |= 0x00000200; sfixed64_ = value; onChanged(); return this; } /** * <code>optional sfixed64 sfixed64 = 10;</code> */ public Builder clearSfixed64() { bitField0_ = (bitField0_ & ~0x00000200); sfixed64_ = 0L; onChanged(); return this; } // optional float float = 11; private float float_ ; /** * <code>optional float float = 11;</code> */ public boolean hasFloat() { return ((bitField0_ & 0x00000400) == 0x00000400); } /** * <code>optional float float = 11;</code> */ public float getFloat() { return float_; } /** * <code>optional float float = 11;</code> */ public Builder setFloat(float value) { bitField0_ |= 0x00000400; float_ = value; onChanged(); return this; } /** * <code>optional float float = 11;</code> */ public Builder clearFloat() { bitField0_ = (bitField0_ & ~0x00000400); float_ = 0F; onChanged(); return this; } // optional double double = 12; private double double_ ; /** * <code>optional double double = 12;</code> */ public boolean hasDouble() { return ((bitField0_ & 0x00000800) == 0x00000800); } /** * <code>optional double double = 12;</code> */ public double getDouble() { return double_; } /** * <code>optional double double = 12;</code> */ public Builder setDouble(double value) { bitField0_ |= 0x00000800; double_ = value; onChanged(); return this; } /** * <code>optional double double = 12;</code> */ public Builder clearDouble() { bitField0_ = (bitField0_ & ~0x00000800); double_ = 0D; onChanged(); return this; } // optional bool bool = 13; private boolean bool_ ; /** * <code>optional bool bool = 13;</code> */ public boolean hasBool() { return ((bitField0_ & 0x00001000) == 0x00001000); } /** * <code>optional bool bool = 13;</code> */ public boolean getBool() { return bool_; } /** * <code>optional bool bool = 13;</code> */ public Builder setBool(boolean value) { bitField0_ |= 0x00001000; bool_ = value; onChanged(); return this; } /** * <code>optional bool bool = 13;</code> */ public Builder clearBool() { bitField0_ = (bitField0_ & ~0x00001000); bool_ = false; onChanged(); return this; } // optional string string = 14; private java.lang.Object string_ = ""; /** * <code>optional string string = 14;</code> */ public boolean hasString() { return ((bitField0_ & 0x00002000) == 0x00002000); } /** * <code>optional string string = 14;</code> */ public java.lang.String getString() { java.lang.Object ref = string_; if (!(ref instanceof java.lang.String)) { java.lang.String s = ((com.google.protobuf.ByteString) ref) .toStringUtf8(); string_ = s; return s; } else { return (java.lang.String) ref; } } /** * <code>optional string string = 14;</code> */ public com.google.protobuf.ByteString getStringBytes() { java.lang.Object ref = string_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); string_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * <code>optional string string = 14;</code> */ public Builder setString( java.lang.String value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00002000; string_ = value; onChanged(); return this; } /** * <code>optional string string = 14;</code> */ public Builder clearString() { bitField0_ = (bitField0_ & ~0x00002000); string_ = getDefaultInstance().getString(); onChanged(); return this; } /** * <code>optional string string = 14;</code> */ public Builder setStringBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00002000; string_ = value; onChanged(); return this; } // optional bytes bytes = 15; private com.google.protobuf.ByteString bytes_ = com.google.protobuf.ByteString.EMPTY; /** * <code>optional bytes bytes = 15;</code> */ public boolean hasBytes() { return ((bitField0_ & 0x00004000) == 0x00004000); } /** * <code>optional bytes bytes = 15;</code> */ public com.google.protobuf.ByteString getBytes() { return bytes_; } /** * <code>optional bytes bytes = 15;</code> */ public Builder setBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00004000; bytes_ = value; onChanged(); return this; } /** * <code>optional bytes bytes = 15;</code> */ public Builder clearBytes() { bitField0_ = (bitField0_ & ~0x00004000); bytes_ = getDefaultInstance().getBytes(); onChanged(); return this; } // optional .org.apache.avro.protobuf.A enum = 16 [default = Z]; private org.apache.avro.protobuf.Test.A enum_ = org.apache.avro.protobuf.Test.A.Z; /** * <code>optional .org.apache.avro.protobuf.A enum = 16 [default = Z];</code> */ public boolean hasEnum() { return ((bitField0_ & 0x00008000) == 0x00008000); } /** * <code>optional .org.apache.avro.protobuf.A enum = 16 [default = Z];</code> */ public org.apache.avro.protobuf.Test.A getEnum() { return enum_; } /** * <code>optional .org.apache.avro.protobuf.A enum = 16 [default = Z];</code> */ public Builder setEnum(org.apache.avro.protobuf.Test.A value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00008000; enum_ = value; onChanged(); return this; } /** * <code>optional .org.apache.avro.protobuf.A enum = 16 [default = Z];</code> */ public Builder clearEnum() { bitField0_ = (bitField0_ & ~0x00008000); enum_ = org.apache.avro.protobuf.Test.A.Z; onChanged(); return this; } // repeated int32 intArray = 17; private java.util.List<java.lang.Integer> intArray_ = java.util.Collections.emptyList(); private void ensureIntArrayIsMutable() { if (!((bitField0_ & 0x00010000) == 0x00010000)) { intArray_ = new java.util.ArrayList<java.lang.Integer>(intArray_); bitField0_ |= 0x00010000; } } /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ public java.util.List<java.lang.Integer> getIntArrayList() { return java.util.Collections.unmodifiableList(intArray_); } /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ public int getIntArrayCount() { return intArray_.size(); } /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ public int getIntArray(int index) { return intArray_.get(index); } /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ public Builder setIntArray( int index, int value) { ensureIntArrayIsMutable(); intArray_.set(index, value); onChanged(); return this; } /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ public Builder addIntArray(int value) { ensureIntArrayIsMutable(); intArray_.add(value); onChanged(); return this; } /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ public Builder addAllIntArray( java.lang.Iterable<? extends java.lang.Integer> values) { ensureIntArrayIsMutable(); super.addAll(values, intArray_); onChanged(); return this; } /** * <code>repeated int32 intArray = 17;</code> * * <pre> * some repeated types * </pre> */ public Builder clearIntArray() { intArray_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00010000); onChanged(); return this; } // repeated .org.apache.avro.protobuf.Foo fooArray = 20; private java.util.List<org.apache.avro.protobuf.Test.Foo> fooArray_ = java.util.Collections.emptyList(); private void ensureFooArrayIsMutable() { if (!((bitField0_ & 0x00020000) == 0x00020000)) { fooArray_ = new java.util.ArrayList<org.apache.avro.protobuf.Test.Foo>(fooArray_); bitField0_ |= 0x00020000; } } private com.google.protobuf.RepeatedFieldBuilder< org.apache.avro.protobuf.Test.Foo, org.apache.avro.protobuf.Test.Foo.Builder, org.apache.avro.protobuf.Test.FooOrBuilder> fooArrayBuilder_; /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public java.util.List<org.apache.avro.protobuf.Test.Foo> getFooArrayList() { if (fooArrayBuilder_ == null) { return java.util.Collections.unmodifiableList(fooArray_); } else { return fooArrayBuilder_.getMessageList(); } } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public int getFooArrayCount() { if (fooArrayBuilder_ == null) { return fooArray_.size(); } else { return fooArrayBuilder_.getCount(); } } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public org.apache.avro.protobuf.Test.Foo getFooArray(int index) { if (fooArrayBuilder_ == null) { return fooArray_.get(index); } else { return fooArrayBuilder_.getMessage(index); } } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public Builder setFooArray( int index, org.apache.avro.protobuf.Test.Foo value) { if (fooArrayBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureFooArrayIsMutable(); fooArray_.set(index, value); onChanged(); } else { fooArrayBuilder_.setMessage(index, value); } return this; } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public Builder setFooArray( int index, org.apache.avro.protobuf.Test.Foo.Builder builderForValue) { if (fooArrayBuilder_ == null) { ensureFooArrayIsMutable(); fooArray_.set(index, builderForValue.build()); onChanged(); } else { fooArrayBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public Builder addFooArray(org.apache.avro.protobuf.Test.Foo value) { if (fooArrayBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureFooArrayIsMutable(); fooArray_.add(value); onChanged(); } else { fooArrayBuilder_.addMessage(value); } return this; } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public Builder addFooArray( int index, org.apache.avro.protobuf.Test.Foo value) { if (fooArrayBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureFooArrayIsMutable(); fooArray_.add(index, value); onChanged(); } else { fooArrayBuilder_.addMessage(index, value); } return this; } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public Builder addFooArray( org.apache.avro.protobuf.Test.Foo.Builder builderForValue) { if (fooArrayBuilder_ == null) { ensureFooArrayIsMutable(); fooArray_.add(builderForValue.build()); onChanged(); } else { fooArrayBuilder_.addMessage(builderForValue.build()); } return this; } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public Builder addFooArray( int index, org.apache.avro.protobuf.Test.Foo.Builder builderForValue) { if (fooArrayBuilder_ == null) { ensureFooArrayIsMutable(); fooArray_.add(index, builderForValue.build()); onChanged(); } else { fooArrayBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public Builder addAllFooArray( java.lang.Iterable<? extends org.apache.avro.protobuf.Test.Foo> values) { if (fooArrayBuilder_ == null) { ensureFooArrayIsMutable(); super.addAll(values, fooArray_); onChanged(); } else { fooArrayBuilder_.addAllMessages(values); } return this; } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public Builder clearFooArray() { if (fooArrayBuilder_ == null) { fooArray_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00020000); onChanged(); } else { fooArrayBuilder_.clear(); } return this; } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public Builder removeFooArray(int index) { if (fooArrayBuilder_ == null) { ensureFooArrayIsMutable(); fooArray_.remove(index); onChanged(); } else { fooArrayBuilder_.remove(index); } return this; } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public org.apache.avro.protobuf.Test.Foo.Builder getFooArrayBuilder( int index) { return getFooArrayFieldBuilder().getBuilder(index); } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public org.apache.avro.protobuf.Test.FooOrBuilder getFooArrayOrBuilder( int index) { if (fooArrayBuilder_ == null) { return fooArray_.get(index); } else { return fooArrayBuilder_.getMessageOrBuilder(index); } } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public java.util.List<? extends org.apache.avro.protobuf.Test.FooOrBuilder> getFooArrayOrBuilderList() { if (fooArrayBuilder_ != null) { return fooArrayBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(fooArray_); } } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public org.apache.avro.protobuf.Test.Foo.Builder addFooArrayBuilder() { return getFooArrayFieldBuilder().addBuilder( org.apache.avro.protobuf.Test.Foo.getDefaultInstance()); } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public org.apache.avro.protobuf.Test.Foo.Builder addFooArrayBuilder( int index) { return getFooArrayFieldBuilder().addBuilder( index, org.apache.avro.protobuf.Test.Foo.getDefaultInstance()); } /** * <code>repeated .org.apache.avro.protobuf.Foo fooArray = 20;</code> */ public java.util.List<org.apache.avro.protobuf.Test.Foo.Builder> getFooArrayBuilderList() { return getFooArrayFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilder< org.apache.avro.protobuf.Test.Foo, org.apache.avro.protobuf.Test.Foo.Builder, org.apache.avro.protobuf.Test.FooOrBuilder> getFooArrayFieldBuilder() { if (fooArrayBuilder_ == null) { fooArrayBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< org.apache.avro.protobuf.Test.Foo, org.apache.avro.protobuf.Test.Foo.Builder, org.apache.avro.protobuf.Test.FooOrBuilder>( fooArray_, ((bitField0_ & 0x00020000) == 0x00020000), getParentForChildren(), isClean()); fooArray_ = null; } return fooArrayBuilder_; } // repeated .org.apache.avro.protobuf.A syms = 19; private java.util.List<org.apache.avro.protobuf.Test.A> syms_ = java.util.Collections.emptyList(); private void ensureSymsIsMutable() { if (!((bitField0_ & 0x00040000) == 0x00040000)) { syms_ = new java.util.ArrayList<org.apache.avro.protobuf.Test.A>(syms_); bitField0_ |= 0x00040000; } } /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ public java.util.List<org.apache.avro.protobuf.Test.A> getSymsList() { return java.util.Collections.unmodifiableList(syms_); } /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ public int getSymsCount() { return syms_.size(); } /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ public org.apache.avro.protobuf.Test.A getSyms(int index) { return syms_.get(index); } /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ public Builder setSyms( int index, org.apache.avro.protobuf.Test.A value) { if (value == null) { throw new NullPointerException(); } ensureSymsIsMutable(); syms_.set(index, value); onChanged(); return this; } /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ public Builder addSyms(org.apache.avro.protobuf.Test.A value) { if (value == null) { throw new NullPointerException(); } ensureSymsIsMutable(); syms_.add(value); onChanged(); return this; } /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ public Builder addAllSyms( java.lang.Iterable<? extends org.apache.avro.protobuf.Test.A> values) { ensureSymsIsMutable(); super.addAll(values, syms_); onChanged(); return this; } /** * <code>repeated .org.apache.avro.protobuf.A syms = 19;</code> */ public Builder clearSyms() { syms_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00040000); onChanged(); return this; } // optional .org.apache.avro.protobuf.Foo foo = 18; private org.apache.avro.protobuf.Test.Foo foo_ = org.apache.avro.protobuf.Test.Foo.getDefaultInstance(); private com.google.protobuf.SingleFieldBuilder< org.apache.avro.protobuf.Test.Foo, org.apache.avro.protobuf.Test.Foo.Builder, org.apache.avro.protobuf.Test.FooOrBuilder> fooBuilder_; /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ public boolean hasFoo() { return ((bitField0_ & 0x00080000) == 0x00080000); } /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ public org.apache.avro.protobuf.Test.Foo getFoo() { if (fooBuilder_ == null) { return foo_; } else { return fooBuilder_.getMessage(); } } /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ public Builder setFoo(org.apache.avro.protobuf.Test.Foo value) { if (fooBuilder_ == null) { if (value == null) { throw new NullPointerException(); } foo_ = value; onChanged(); } else { fooBuilder_.setMessage(value); } bitField0_ |= 0x00080000; return this; } /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ public Builder setFoo( org.apache.avro.protobuf.Test.Foo.Builder builderForValue) { if (fooBuilder_ == null) { foo_ = builderForValue.build(); onChanged(); } else { fooBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00080000; return this; } /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ public Builder mergeFoo(org.apache.avro.protobuf.Test.Foo value) { if (fooBuilder_ == null) { if (((bitField0_ & 0x00080000) == 0x00080000) && foo_ != org.apache.avro.protobuf.Test.Foo.getDefaultInstance()) { foo_ = org.apache.avro.protobuf.Test.Foo.newBuilder(foo_).mergeFrom(value).buildPartial(); } else { foo_ = value; } onChanged(); } else { fooBuilder_.mergeFrom(value); } bitField0_ |= 0x00080000; return this; } /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ public Builder clearFoo() { if (fooBuilder_ == null) { foo_ = org.apache.avro.protobuf.Test.Foo.getDefaultInstance(); onChanged(); } else { fooBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00080000); return this; } /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ public org.apache.avro.protobuf.Test.Foo.Builder getFooBuilder() { bitField0_ |= 0x00080000; onChanged(); return getFooFieldBuilder().getBuilder(); } /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ public org.apache.avro.protobuf.Test.FooOrBuilder getFooOrBuilder() { if (fooBuilder_ != null) { return fooBuilder_.getMessageOrBuilder(); } else { return foo_; } } /** * <code>optional .org.apache.avro.protobuf.Foo foo = 18;</code> * * <pre> * a recursive type * </pre> */ private com.google.protobuf.SingleFieldBuilder< org.apache.avro.protobuf.Test.Foo, org.apache.avro.protobuf.Test.Foo.Builder, org.apache.avro.protobuf.Test.FooOrBuilder> getFooFieldBuilder() { if (fooBuilder_ == null) { fooBuilder_ = new com.google.protobuf.SingleFieldBuilder< org.apache.avro.protobuf.Test.Foo, org.apache.avro.protobuf.Test.Foo.Builder, org.apache.avro.protobuf.Test.FooOrBuilder>( foo_, getParentForChildren(), isClean()); foo_ = null; } return fooBuilder_; } // @@protoc_insertion_point(builder_scope:org.apache.avro.protobuf.Foo) } static { defaultInstance = new Foo(true); defaultInstance.initFields(); } // @@protoc_insertion_point(class_scope:org.apache.avro.protobuf.Foo) } public interface MOrBuilder extends com.google.protobuf.MessageOrBuilder { } /** * Protobuf type {@code org.apache.avro.protobuf.M} * * <pre> * a nested enum * </pre> */ public static final class M extends com.google.protobuf.GeneratedMessage implements MOrBuilder { // Use M.newBuilder() to construct. private M(com.google.protobuf.GeneratedMessage.Builder<?> builder) { super(builder); this.unknownFields = builder.getUnknownFields(); } private M(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } private static final M defaultInstance; public static M getDefaultInstance() { return defaultInstance; } public M getDefaultInstanceForType() { return defaultInstance; } private final com.google.protobuf.UnknownFieldSet unknownFields; @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } private M( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { initFields(); com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; default: { if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException( e.getMessage()).setUnfinishedMessage(this); } finally { this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.apache.avro.protobuf.Test.internal_static_org_apache_avro_protobuf_M_descriptor; } protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { return org.apache.avro.protobuf.Test.internal_static_org_apache_avro_protobuf_M_fieldAccessorTable .ensureFieldAccessorsInitialized( org.apache.avro.protobuf.Test.M.class, org.apache.avro.protobuf.Test.M.Builder.class); } public static com.google.protobuf.Parser<M> PARSER = new com.google.protobuf.AbstractParser<M>() { public M parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new M(input, extensionRegistry); } }; @java.lang.Override public com.google.protobuf.Parser<M> getParserForType() { return PARSER; } /** * Protobuf enum {@code org.apache.avro.protobuf.M.N} */ public enum N implements com.google.protobuf.ProtocolMessageEnum { /** * <code>A = 1;</code> */ A(0, 1), ; /** * <code>A = 1;</code> */ public static final int A_VALUE = 1; public final int getNumber() { return value; } public static N valueOf(int value) { switch (value) { case 1: return A; default: return null; } } public static com.google.protobuf.Internal.EnumLiteMap<N> internalGetValueMap() { return internalValueMap; } private static com.google.protobuf.Internal.EnumLiteMap<N> internalValueMap = new com.google.protobuf.Internal.EnumLiteMap<N>() { public N findValueByNumber(int number) { return N.valueOf(number); } }; public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { return getDescriptor().getValues().get(index); } public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { return org.apache.avro.protobuf.Test.M.getDescriptor().getEnumTypes().get(0); } private static final N[] VALUES = values(); public static N valueOf( com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { throw new java.lang.IllegalArgumentException( "EnumValueDescriptor is not for this type."); } return VALUES[desc.getIndex()]; } private final int index; private final int value; private N(int index, int value) { this.index = index; this.value = value; } // @@protoc_insertion_point(enum_scope:org.apache.avro.protobuf.M.N) } private void initFields() { } private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized != -1) return isInitialized == 1; memoizedIsInitialized = 1; return true; } public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { getSerializedSize(); getUnknownFields().writeTo(output); } private int memoizedSerializedSize = -1; public int getSerializedSize() { int size = memoizedSerializedSize; if (size != -1) return size; size = 0; size += getUnknownFields().getSerializedSize(); memoizedSerializedSize = size; return size; } private static final long serialVersionUID = 0L; @java.lang.Override protected java.lang.Object writeReplace() throws java.io.ObjectStreamException { return super.writeReplace(); } public static org.apache.avro.protobuf.Test.M parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.apache.avro.protobuf.Test.M parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.apache.avro.protobuf.Test.M parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static org.apache.avro.protobuf.Test.M parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static org.apache.avro.protobuf.Test.M parseFrom(java.io.InputStream input) throws java.io.IOException { return PARSER.parseFrom(input); } public static org.apache.avro.protobuf.Test.M parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return PARSER.parseFrom(input, extensionRegistry); } public static org.apache.avro.protobuf.Test.M parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return PARSER.parseDelimitedFrom(input); } public static org.apache.avro.protobuf.Test.M parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return PARSER.parseDelimitedFrom(input, extensionRegistry); } public static org.apache.avro.protobuf.Test.M parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return PARSER.parseFrom(input); } public static org.apache.avro.protobuf.Test.M parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return PARSER.parseFrom(input, extensionRegistry); } public static Builder newBuilder() { return Builder.create(); } public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder(org.apache.avro.protobuf.Test.M prototype) { return newBuilder().mergeFrom(prototype); } public Builder toBuilder() { return newBuilder(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessage.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * Protobuf type {@code org.apache.avro.protobuf.M} * * <pre> * a nested enum * </pre> */ public static final class Builder extends com.google.protobuf.GeneratedMessage.Builder<Builder> implements org.apache.avro.protobuf.Test.MOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return org.apache.avro.protobuf.Test.internal_static_org_apache_avro_protobuf_M_descriptor; } protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable() { return org.apache.avro.protobuf.Test.internal_static_org_apache_avro_protobuf_M_fieldAccessorTable .ensureFieldAccessorsInitialized( org.apache.avro.protobuf.Test.M.class, org.apache.avro.protobuf.Test.M.Builder.class); } // Construct using org.apache.avro.protobuf.Test.M.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessage.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { } } private static Builder create() { return new Builder(); } public Builder clear() { super.clear(); return this; } public Builder clone() { return create().mergeFrom(buildPartial()); } public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return org.apache.avro.protobuf.Test.internal_static_org_apache_avro_protobuf_M_descriptor; } public org.apache.avro.protobuf.Test.M getDefaultInstanceForType() { return org.apache.avro.protobuf.Test.M.getDefaultInstance(); } public org.apache.avro.protobuf.Test.M build() { org.apache.avro.protobuf.Test.M result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } public org.apache.avro.protobuf.Test.M buildPartial() { org.apache.avro.protobuf.Test.M result = new org.apache.avro.protobuf.Test.M(this); onBuilt(); return result; } public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof org.apache.avro.protobuf.Test.M) { return mergeFrom((org.apache.avro.protobuf.Test.M)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(org.apache.avro.protobuf.Test.M other) { if (other == org.apache.avro.protobuf.Test.M.getDefaultInstance()) return this; this.mergeUnknownFields(other.getUnknownFields()); return this; } public final boolean isInitialized() { return true; } public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { org.apache.avro.protobuf.Test.M parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (org.apache.avro.protobuf.Test.M) e.getUnfinishedMessage(); throw e; } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } // @@protoc_insertion_point(builder_scope:org.apache.avro.protobuf.M) } static { defaultInstance = new M(true); defaultInstance.initFields(); } // @@protoc_insertion_point(class_scope:org.apache.avro.protobuf.M) } private static com.google.protobuf.Descriptors.Descriptor internal_static_org_apache_avro_protobuf_Foo_descriptor; private static com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_org_apache_avro_protobuf_Foo_fieldAccessorTable; private static com.google.protobuf.Descriptors.Descriptor internal_static_org_apache_avro_protobuf_M_descriptor; private static com.google.protobuf.GeneratedMessage.FieldAccessorTable internal_static_org_apache_avro_protobuf_M_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; } private static com.google.protobuf.Descriptors.FileDescriptor descriptor; static { java.lang.String[] descriptorData = { "\n\034src/test/protobuf/test.proto\022\030org.apac" + "he.avro.protobuf\"\275\003\n\003Foo\022\r\n\005int32\030\001 \002(\005\022" + "\r\n\005int64\030\002 \001(\003\022\016\n\006uint32\030\003 \001(\r\022\016\n\006uint64" + "\030\004 \001(\004\022\016\n\006sint32\030\005 \001(\021\022\016\n\006sint64\030\006 \001(\022\022\017" + "\n\007fixed32\030\007 \001(\007\022\017\n\007fixed64\030\010 \001(\006\022\020\n\010sfix" + "ed32\030\t \001(\017\022\020\n\010sfixed64\030\n \001(\020\022\r\n\005float\030\013 " + "\001(\002\022\016\n\006double\030\014 \001(\001\022\014\n\004bool\030\r \001(\010\022\016\n\006str" + "ing\030\016 \001(\t\022\r\n\005bytes\030\017 \001(\014\022,\n\004enum\030\020 \001(\0162\033" + ".org.apache.avro.protobuf.A:\001Z\022\020\n\010intArr" + "ay\030\021 \003(\005\022/\n\010fooArray\030\024 \003(\0132\035.org.apache.", "avro.protobuf.Foo\022)\n\004syms\030\023 \003(\0162\033.org.ap" + "ache.avro.protobuf.A\022*\n\003foo\030\022 \001(\0132\035.org." + "apache.avro.protobuf.Foo\"\017\n\001M\"\n\n\001N\022\005\n\001A\020" + "\001*\030\n\001A\022\005\n\001X\020\001\022\005\n\001Y\020\002\022\005\n\001Z\020\003" }; com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = new com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner() { public com.google.protobuf.ExtensionRegistry assignDescriptors( com.google.protobuf.Descriptors.FileDescriptor root) { descriptor = root; internal_static_org_apache_avro_protobuf_Foo_descriptor = getDescriptor().getMessageTypes().get(0); internal_static_org_apache_avro_protobuf_Foo_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_org_apache_avro_protobuf_Foo_descriptor, new java.lang.String[] { "Int32", "Int64", "Uint32", "Uint64", "Sint32", "Sint64", "Fixed32", "Fixed64", "Sfixed32", "Sfixed64", "Float", "Double", "Bool", "String", "Bytes", "Enum", "IntArray", "FooArray", "Syms", "Foo", }); internal_static_org_apache_avro_protobuf_M_descriptor = getDescriptor().getMessageTypes().get(1); internal_static_org_apache_avro_protobuf_M_fieldAccessorTable = new com.google.protobuf.GeneratedMessage.FieldAccessorTable( internal_static_org_apache_avro_protobuf_M_descriptor, new java.lang.String[] { }); return null; } }; com.google.protobuf.Descriptors.FileDescriptor .internalBuildGeneratedFileFrom(descriptorData, new com.google.protobuf.Descriptors.FileDescriptor[] { }, assigner); } // @@protoc_insertion_point(outer_class_scope) }