// Code generated by Wire protocol buffer compiler, do not edit.
// Source: squareup.protos.alltypes.AllTypes in all_types.proto
package com.squareup.wire.protos.alltypes;

import com.squareup.wire.EnumAdapter;
import com.squareup.wire.FieldEncoding;
import com.squareup.wire.Message;
import com.squareup.wire.ProtoAdapter;
import com.squareup.wire.ProtoReader;
import com.squareup.wire.ProtoWriter;
import com.squareup.wire.ReverseProtoWriter;
import com.squareup.wire.Syntax;
import com.squareup.wire.WireEnum;
import com.squareup.wire.WireField;
import com.squareup.wire.internal.Internal;
import java.io.IOException;
import java.lang.Boolean;
import java.lang.Double;
import java.lang.Float;
import java.lang.Integer;
import java.lang.Long;
import java.lang.Object;
import java.lang.Override;
import java.lang.String;
import java.lang.StringBuilder;
import java.util.List;
import java.util.Map;
import okio.ByteString;

public final class AllTypes extends Message<AllTypes, AllTypes.Builder> {
  public static final ProtoAdapter<AllTypes> ADAPTER = new ProtoAdapter_AllTypes();

  private static final long serialVersionUID = 0L;

  public static final Integer DEFAULT_OPT_INT32 = 0;

  public static final Integer DEFAULT_OPT_UINT32 = 0;

  public static final Integer DEFAULT_OPT_SINT32 = 0;

  public static final Integer DEFAULT_OPT_FIXED32 = 0;

  public static final Integer DEFAULT_OPT_SFIXED32 = 0;

  public static final Long DEFAULT_OPT_INT64 = 0L;

  public static final Long DEFAULT_OPT_UINT64 = 0L;

  public static final Long DEFAULT_OPT_SINT64 = 0L;

  public static final Long DEFAULT_OPT_FIXED64 = 0L;

  public static final Long DEFAULT_OPT_SFIXED64 = 0L;

  public static final Boolean DEFAULT_OPT_BOOL = false;

  public static final Float DEFAULT_OPT_FLOAT = 0.0f;

  public static final Double DEFAULT_OPT_DOUBLE = 0.0d;

  public static final String DEFAULT_OPT_STRING = "";

  public static final ByteString DEFAULT_OPT_BYTES = ByteString.EMPTY;

  public static final NestedEnum DEFAULT_OPT_NESTED_ENUM = NestedEnum.UNKNOWN;

  public static final Integer DEFAULT_REQ_INT32 = 0;

  public static final Integer DEFAULT_REQ_UINT32 = 0;

  public static final Integer DEFAULT_REQ_SINT32 = 0;

  public static final Integer DEFAULT_REQ_FIXED32 = 0;

  public static final Integer DEFAULT_REQ_SFIXED32 = 0;

  public static final Long DEFAULT_REQ_INT64 = 0L;

  public static final Long DEFAULT_REQ_UINT64 = 0L;

  public static final Long DEFAULT_REQ_SINT64 = 0L;

  public static final Long DEFAULT_REQ_FIXED64 = 0L;

  public static final Long DEFAULT_REQ_SFIXED64 = 0L;

  public static final Boolean DEFAULT_REQ_BOOL = false;

  public static final Float DEFAULT_REQ_FLOAT = 0.0f;

  public static final Double DEFAULT_REQ_DOUBLE = 0.0d;

  public static final String DEFAULT_REQ_STRING = "";

  public static final ByteString DEFAULT_REQ_BYTES = ByteString.EMPTY;

  public static final NestedEnum DEFAULT_REQ_NESTED_ENUM = NestedEnum.UNKNOWN;

  public static final Integer DEFAULT_DEFAULT_INT32 = 2147483647;

  public static final Integer DEFAULT_DEFAULT_UINT32 = -1;

  public static final Integer DEFAULT_DEFAULT_SINT32 = -2147483648;

  public static final Integer DEFAULT_DEFAULT_FIXED32 = -1;

  public static final Integer DEFAULT_DEFAULT_SFIXED32 = -2147483648;

  public static final Long DEFAULT_DEFAULT_INT64 = 9223372036854775807L;

  public static final Long DEFAULT_DEFAULT_UINT64 = -1L;

  public static final Long DEFAULT_DEFAULT_SINT64 = -9223372036854775808L;

  public static final Long DEFAULT_DEFAULT_FIXED64 = -1L;

  public static final Long DEFAULT_DEFAULT_SFIXED64 = -9223372036854775808L;

  public static final Boolean DEFAULT_DEFAULT_BOOL = true;

  public static final Float DEFAULT_DEFAULT_FLOAT = 123.456e7f;

  public static final Double DEFAULT_DEFAULT_DOUBLE = 123.456e78d;

  public static final String DEFAULT_DEFAULT_STRING = "çok\u0007\b\f\n"
      + "\r\t\u000b\u0001\u0001\u0001\u000f\u000f~\u0001\u0001\u0011\u0001\u0001\u0011güzel";

  public static final ByteString DEFAULT_DEFAULT_BYTES = ByteString.decodeBase64("529rBwgMCg0JCwEBAQ8PfgEBEQEBEWf8emVs");

  public static final NestedEnum DEFAULT_DEFAULT_NESTED_ENUM = NestedEnum.A;

  public static final Integer DEFAULT_EXT_OPT_INT32 = 0;

  public static final Integer DEFAULT_EXT_OPT_UINT32 = 0;

  public static final Integer DEFAULT_EXT_OPT_SINT32 = 0;

  public static final Integer DEFAULT_EXT_OPT_FIXED32 = 0;

  public static final Integer DEFAULT_EXT_OPT_SFIXED32 = 0;

  public static final Long DEFAULT_EXT_OPT_INT64 = 0L;

  public static final Long DEFAULT_EXT_OPT_UINT64 = 0L;

  public static final Long DEFAULT_EXT_OPT_SINT64 = 0L;

  public static final Long DEFAULT_EXT_OPT_FIXED64 = 0L;

  public static final Long DEFAULT_EXT_OPT_SFIXED64 = 0L;

  public static final Boolean DEFAULT_EXT_OPT_BOOL = false;

  public static final Float DEFAULT_EXT_OPT_FLOAT = 0.0f;

  public static final Double DEFAULT_EXT_OPT_DOUBLE = 0.0d;

  public static final String DEFAULT_EXT_OPT_STRING = "";

  public static final ByteString DEFAULT_EXT_OPT_BYTES = ByteString.EMPTY;

  public static final NestedEnum DEFAULT_EXT_OPT_NESTED_ENUM = NestedEnum.UNKNOWN;

  @WireField(
      tag = 1,
      adapter = "com.squareup.wire.ProtoAdapter#INT32"
  )
  public final Integer opt_int32;

  @WireField(
      tag = 2,
      adapter = "com.squareup.wire.ProtoAdapter#UINT32"
  )
  public final Integer opt_uint32;

  @WireField(
      tag = 3,
      adapter = "com.squareup.wire.ProtoAdapter#SINT32"
  )
  public final Integer opt_sint32;

  @WireField(
      tag = 4,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED32"
  )
  public final Integer opt_fixed32;

  @WireField(
      tag = 5,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED32"
  )
  public final Integer opt_sfixed32;

  @WireField(
      tag = 6,
      adapter = "com.squareup.wire.ProtoAdapter#INT64"
  )
  public final Long opt_int64;

  @WireField(
      tag = 7,
      adapter = "com.squareup.wire.ProtoAdapter#UINT64"
  )
  public final Long opt_uint64;

  @WireField(
      tag = 8,
      adapter = "com.squareup.wire.ProtoAdapter#SINT64"
  )
  public final Long opt_sint64;

  @WireField(
      tag = 9,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED64"
  )
  public final Long opt_fixed64;

  @WireField(
      tag = 10,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED64"
  )
  public final Long opt_sfixed64;

  @WireField(
      tag = 11,
      adapter = "com.squareup.wire.ProtoAdapter#BOOL"
  )
  public final Boolean opt_bool;

  @WireField(
      tag = 12,
      adapter = "com.squareup.wire.ProtoAdapter#FLOAT"
  )
  public final Float opt_float;

  @WireField(
      tag = 13,
      adapter = "com.squareup.wire.ProtoAdapter#DOUBLE"
  )
  public final Double opt_double;

  @WireField(
      tag = 14,
      adapter = "com.squareup.wire.ProtoAdapter#STRING"
  )
  public final String opt_string;

  @WireField(
      tag = 15,
      adapter = "com.squareup.wire.ProtoAdapter#BYTES"
  )
  public final ByteString opt_bytes;

  @WireField(
      tag = 16,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedEnum#ADAPTER"
  )
  public final NestedEnum opt_nested_enum;

  @WireField(
      tag = 17,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedMessage#ADAPTER"
  )
  public final NestedMessage opt_nested_message;

  @WireField(
      tag = 101,
      adapter = "com.squareup.wire.ProtoAdapter#INT32",
      label = WireField.Label.REQUIRED
  )
  public final Integer req_int32;

  @WireField(
      tag = 102,
      adapter = "com.squareup.wire.ProtoAdapter#UINT32",
      label = WireField.Label.REQUIRED
  )
  public final Integer req_uint32;

  @WireField(
      tag = 103,
      adapter = "com.squareup.wire.ProtoAdapter#SINT32",
      label = WireField.Label.REQUIRED
  )
  public final Integer req_sint32;

  @WireField(
      tag = 104,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED32",
      label = WireField.Label.REQUIRED
  )
  public final Integer req_fixed32;

  @WireField(
      tag = 105,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED32",
      label = WireField.Label.REQUIRED
  )
  public final Integer req_sfixed32;

  @WireField(
      tag = 106,
      adapter = "com.squareup.wire.ProtoAdapter#INT64",
      label = WireField.Label.REQUIRED
  )
  public final Long req_int64;

  @WireField(
      tag = 107,
      adapter = "com.squareup.wire.ProtoAdapter#UINT64",
      label = WireField.Label.REQUIRED
  )
  public final Long req_uint64;

  @WireField(
      tag = 108,
      adapter = "com.squareup.wire.ProtoAdapter#SINT64",
      label = WireField.Label.REQUIRED
  )
  public final Long req_sint64;

  @WireField(
      tag = 109,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED64",
      label = WireField.Label.REQUIRED
  )
  public final Long req_fixed64;

  @WireField(
      tag = 110,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED64",
      label = WireField.Label.REQUIRED
  )
  public final Long req_sfixed64;

  @WireField(
      tag = 111,
      adapter = "com.squareup.wire.ProtoAdapter#BOOL",
      label = WireField.Label.REQUIRED
  )
  public final Boolean req_bool;

  @WireField(
      tag = 112,
      adapter = "com.squareup.wire.ProtoAdapter#FLOAT",
      label = WireField.Label.REQUIRED
  )
  public final Float req_float;

  @WireField(
      tag = 113,
      adapter = "com.squareup.wire.ProtoAdapter#DOUBLE",
      label = WireField.Label.REQUIRED
  )
  public final Double req_double;

  @WireField(
      tag = 114,
      adapter = "com.squareup.wire.ProtoAdapter#STRING",
      label = WireField.Label.REQUIRED
  )
  public final String req_string;

  @WireField(
      tag = 115,
      adapter = "com.squareup.wire.ProtoAdapter#BYTES",
      label = WireField.Label.REQUIRED
  )
  public final ByteString req_bytes;

  @WireField(
      tag = 116,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedEnum#ADAPTER",
      label = WireField.Label.REQUIRED
  )
  public final NestedEnum req_nested_enum;

  @WireField(
      tag = 117,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedMessage#ADAPTER",
      label = WireField.Label.REQUIRED
  )
  public final NestedMessage req_nested_message;

  @WireField(
      tag = 201,
      adapter = "com.squareup.wire.ProtoAdapter#INT32",
      label = WireField.Label.REPEATED
  )
  public final List<Integer> rep_int32;

  @WireField(
      tag = 202,
      adapter = "com.squareup.wire.ProtoAdapter#UINT32",
      label = WireField.Label.REPEATED
  )
  public final List<Integer> rep_uint32;

  @WireField(
      tag = 203,
      adapter = "com.squareup.wire.ProtoAdapter#SINT32",
      label = WireField.Label.REPEATED
  )
  public final List<Integer> rep_sint32;

  @WireField(
      tag = 204,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED32",
      label = WireField.Label.REPEATED
  )
  public final List<Integer> rep_fixed32;

  @WireField(
      tag = 205,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED32",
      label = WireField.Label.REPEATED
  )
  public final List<Integer> rep_sfixed32;

  @WireField(
      tag = 206,
      adapter = "com.squareup.wire.ProtoAdapter#INT64",
      label = WireField.Label.REPEATED
  )
  public final List<Long> rep_int64;

  @WireField(
      tag = 207,
      adapter = "com.squareup.wire.ProtoAdapter#UINT64",
      label = WireField.Label.REPEATED
  )
  public final List<Long> rep_uint64;

  @WireField(
      tag = 208,
      adapter = "com.squareup.wire.ProtoAdapter#SINT64",
      label = WireField.Label.REPEATED
  )
  public final List<Long> rep_sint64;

  @WireField(
      tag = 209,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED64",
      label = WireField.Label.REPEATED
  )
  public final List<Long> rep_fixed64;

  @WireField(
      tag = 210,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED64",
      label = WireField.Label.REPEATED
  )
  public final List<Long> rep_sfixed64;

  @WireField(
      tag = 211,
      adapter = "com.squareup.wire.ProtoAdapter#BOOL",
      label = WireField.Label.REPEATED
  )
  public final List<Boolean> rep_bool;

  @WireField(
      tag = 212,
      adapter = "com.squareup.wire.ProtoAdapter#FLOAT",
      label = WireField.Label.REPEATED
  )
  public final List<Float> rep_float;

  @WireField(
      tag = 213,
      adapter = "com.squareup.wire.ProtoAdapter#DOUBLE",
      label = WireField.Label.REPEATED
  )
  public final List<Double> rep_double;

  @WireField(
      tag = 214,
      adapter = "com.squareup.wire.ProtoAdapter#STRING",
      label = WireField.Label.REPEATED
  )
  public final List<String> rep_string;

  @WireField(
      tag = 215,
      adapter = "com.squareup.wire.ProtoAdapter#BYTES",
      label = WireField.Label.REPEATED
  )
  public final List<ByteString> rep_bytes;

  @WireField(
      tag = 216,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedEnum#ADAPTER",
      label = WireField.Label.REPEATED
  )
  public final List<NestedEnum> rep_nested_enum;

  @WireField(
      tag = 217,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedMessage#ADAPTER",
      label = WireField.Label.REPEATED
  )
  public final List<NestedMessage> rep_nested_message;

  @WireField(
      tag = 301,
      adapter = "com.squareup.wire.ProtoAdapter#INT32",
      label = WireField.Label.PACKED
  )
  public final List<Integer> pack_int32;

  @WireField(
      tag = 302,
      adapter = "com.squareup.wire.ProtoAdapter#UINT32",
      label = WireField.Label.PACKED
  )
  public final List<Integer> pack_uint32;

  @WireField(
      tag = 303,
      adapter = "com.squareup.wire.ProtoAdapter#SINT32",
      label = WireField.Label.PACKED
  )
  public final List<Integer> pack_sint32;

  @WireField(
      tag = 304,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED32",
      label = WireField.Label.PACKED
  )
  public final List<Integer> pack_fixed32;

  @WireField(
      tag = 305,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED32",
      label = WireField.Label.PACKED
  )
  public final List<Integer> pack_sfixed32;

  @WireField(
      tag = 306,
      adapter = "com.squareup.wire.ProtoAdapter#INT64",
      label = WireField.Label.PACKED
  )
  public final List<Long> pack_int64;

  @WireField(
      tag = 307,
      adapter = "com.squareup.wire.ProtoAdapter#UINT64",
      label = WireField.Label.PACKED
  )
  public final List<Long> pack_uint64;

  @WireField(
      tag = 308,
      adapter = "com.squareup.wire.ProtoAdapter#SINT64",
      label = WireField.Label.PACKED
  )
  public final List<Long> pack_sint64;

  @WireField(
      tag = 309,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED64",
      label = WireField.Label.PACKED
  )
  public final List<Long> pack_fixed64;

  @WireField(
      tag = 310,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED64",
      label = WireField.Label.PACKED
  )
  public final List<Long> pack_sfixed64;

  @WireField(
      tag = 311,
      adapter = "com.squareup.wire.ProtoAdapter#BOOL",
      label = WireField.Label.PACKED
  )
  public final List<Boolean> pack_bool;

  @WireField(
      tag = 312,
      adapter = "com.squareup.wire.ProtoAdapter#FLOAT",
      label = WireField.Label.PACKED
  )
  public final List<Float> pack_float;

  @WireField(
      tag = 313,
      adapter = "com.squareup.wire.ProtoAdapter#DOUBLE",
      label = WireField.Label.PACKED
  )
  public final List<Double> pack_double;

  @WireField(
      tag = 316,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedEnum#ADAPTER",
      label = WireField.Label.PACKED
  )
  public final List<NestedEnum> pack_nested_enum;

  @WireField(
      tag = 401,
      adapter = "com.squareup.wire.ProtoAdapter#INT32"
  )
  public final Integer default_int32;

  @WireField(
      tag = 402,
      adapter = "com.squareup.wire.ProtoAdapter#UINT32"
  )
  public final Integer default_uint32;

  @WireField(
      tag = 403,
      adapter = "com.squareup.wire.ProtoAdapter#SINT32"
  )
  public final Integer default_sint32;

  @WireField(
      tag = 404,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED32"
  )
  public final Integer default_fixed32;

  @WireField(
      tag = 405,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED32"
  )
  public final Integer default_sfixed32;

  @WireField(
      tag = 406,
      adapter = "com.squareup.wire.ProtoAdapter#INT64"
  )
  public final Long default_int64;

  @WireField(
      tag = 407,
      adapter = "com.squareup.wire.ProtoAdapter#UINT64"
  )
  public final Long default_uint64;

  @WireField(
      tag = 408,
      adapter = "com.squareup.wire.ProtoAdapter#SINT64"
  )
  public final Long default_sint64;

  @WireField(
      tag = 409,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED64"
  )
  public final Long default_fixed64;

  @WireField(
      tag = 410,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED64"
  )
  public final Long default_sfixed64;

  @WireField(
      tag = 411,
      adapter = "com.squareup.wire.ProtoAdapter#BOOL"
  )
  public final Boolean default_bool;

  @WireField(
      tag = 412,
      adapter = "com.squareup.wire.ProtoAdapter#FLOAT"
  )
  public final Float default_float;

  @WireField(
      tag = 413,
      adapter = "com.squareup.wire.ProtoAdapter#DOUBLE"
  )
  public final Double default_double;

  /**
   * Note: protoc doesn't allow some characters of the default value.
   */
  @WireField(
      tag = 414,
      adapter = "com.squareup.wire.ProtoAdapter#STRING"
  )
  public final String default_string;

  @WireField(
      tag = 415,
      adapter = "com.squareup.wire.ProtoAdapter#BYTES"
  )
  public final ByteString default_bytes;

  @WireField(
      tag = 416,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedEnum#ADAPTER"
  )
  public final NestedEnum default_nested_enum;

  @WireField(
      tag = 501,
      keyAdapter = "com.squareup.wire.ProtoAdapter#INT32",
      adapter = "com.squareup.wire.ProtoAdapter#INT32"
  )
  public final Map<Integer, Integer> map_int32_int32;

  @WireField(
      tag = 502,
      keyAdapter = "com.squareup.wire.ProtoAdapter#STRING",
      adapter = "com.squareup.wire.ProtoAdapter#STRING"
  )
  public final Map<String, String> map_string_string;

  @WireField(
      tag = 503,
      keyAdapter = "com.squareup.wire.ProtoAdapter#STRING",
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedMessage#ADAPTER"
  )
  public final Map<String, NestedMessage> map_string_message;

  @WireField(
      tag = 504,
      keyAdapter = "com.squareup.wire.ProtoAdapter#STRING",
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedEnum#ADAPTER"
  )
  public final Map<String, NestedEnum> map_string_enum;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1001,
      adapter = "com.squareup.wire.ProtoAdapter#INT32"
  )
  public final Integer ext_opt_int32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1002,
      adapter = "com.squareup.wire.ProtoAdapter#UINT32"
  )
  public final Integer ext_opt_uint32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1003,
      adapter = "com.squareup.wire.ProtoAdapter#SINT32"
  )
  public final Integer ext_opt_sint32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1004,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED32"
  )
  public final Integer ext_opt_fixed32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1005,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED32"
  )
  public final Integer ext_opt_sfixed32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1006,
      adapter = "com.squareup.wire.ProtoAdapter#INT64"
  )
  public final Long ext_opt_int64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1007,
      adapter = "com.squareup.wire.ProtoAdapter#UINT64"
  )
  public final Long ext_opt_uint64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1008,
      adapter = "com.squareup.wire.ProtoAdapter#SINT64"
  )
  public final Long ext_opt_sint64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1009,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED64"
  )
  public final Long ext_opt_fixed64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1010,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED64"
  )
  public final Long ext_opt_sfixed64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1011,
      adapter = "com.squareup.wire.ProtoAdapter#BOOL"
  )
  public final Boolean ext_opt_bool;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1012,
      adapter = "com.squareup.wire.ProtoAdapter#FLOAT"
  )
  public final Float ext_opt_float;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1013,
      adapter = "com.squareup.wire.ProtoAdapter#DOUBLE"
  )
  public final Double ext_opt_double;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1014,
      adapter = "com.squareup.wire.ProtoAdapter#STRING"
  )
  public final String ext_opt_string;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1015,
      adapter = "com.squareup.wire.ProtoAdapter#BYTES"
  )
  public final ByteString ext_opt_bytes;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1016,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedEnum#ADAPTER"
  )
  public final NestedEnum ext_opt_nested_enum;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1017,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedMessage#ADAPTER"
  )
  public final NestedMessage ext_opt_nested_message;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1101,
      adapter = "com.squareup.wire.ProtoAdapter#INT32",
      label = WireField.Label.REPEATED
  )
  public final List<Integer> ext_rep_int32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1102,
      adapter = "com.squareup.wire.ProtoAdapter#UINT32",
      label = WireField.Label.REPEATED
  )
  public final List<Integer> ext_rep_uint32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1103,
      adapter = "com.squareup.wire.ProtoAdapter#SINT32",
      label = WireField.Label.REPEATED
  )
  public final List<Integer> ext_rep_sint32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1104,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED32",
      label = WireField.Label.REPEATED
  )
  public final List<Integer> ext_rep_fixed32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1105,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED32",
      label = WireField.Label.REPEATED
  )
  public final List<Integer> ext_rep_sfixed32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1106,
      adapter = "com.squareup.wire.ProtoAdapter#INT64",
      label = WireField.Label.REPEATED
  )
  public final List<Long> ext_rep_int64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1107,
      adapter = "com.squareup.wire.ProtoAdapter#UINT64",
      label = WireField.Label.REPEATED
  )
  public final List<Long> ext_rep_uint64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1108,
      adapter = "com.squareup.wire.ProtoAdapter#SINT64",
      label = WireField.Label.REPEATED
  )
  public final List<Long> ext_rep_sint64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1109,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED64",
      label = WireField.Label.REPEATED
  )
  public final List<Long> ext_rep_fixed64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1110,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED64",
      label = WireField.Label.REPEATED
  )
  public final List<Long> ext_rep_sfixed64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1111,
      adapter = "com.squareup.wire.ProtoAdapter#BOOL",
      label = WireField.Label.REPEATED
  )
  public final List<Boolean> ext_rep_bool;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1112,
      adapter = "com.squareup.wire.ProtoAdapter#FLOAT",
      label = WireField.Label.REPEATED
  )
  public final List<Float> ext_rep_float;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1113,
      adapter = "com.squareup.wire.ProtoAdapter#DOUBLE",
      label = WireField.Label.REPEATED
  )
  public final List<Double> ext_rep_double;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1114,
      adapter = "com.squareup.wire.ProtoAdapter#STRING",
      label = WireField.Label.REPEATED
  )
  public final List<String> ext_rep_string;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1115,
      adapter = "com.squareup.wire.ProtoAdapter#BYTES",
      label = WireField.Label.REPEATED
  )
  public final List<ByteString> ext_rep_bytes;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1116,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedEnum#ADAPTER",
      label = WireField.Label.REPEATED
  )
  public final List<NestedEnum> ext_rep_nested_enum;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1117,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedMessage#ADAPTER",
      label = WireField.Label.REPEATED
  )
  public final List<NestedMessage> ext_rep_nested_message;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1201,
      adapter = "com.squareup.wire.ProtoAdapter#INT32",
      label = WireField.Label.PACKED
  )
  public final List<Integer> ext_pack_int32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1202,
      adapter = "com.squareup.wire.ProtoAdapter#UINT32",
      label = WireField.Label.PACKED
  )
  public final List<Integer> ext_pack_uint32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1203,
      adapter = "com.squareup.wire.ProtoAdapter#SINT32",
      label = WireField.Label.PACKED
  )
  public final List<Integer> ext_pack_sint32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1204,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED32",
      label = WireField.Label.PACKED
  )
  public final List<Integer> ext_pack_fixed32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1205,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED32",
      label = WireField.Label.PACKED
  )
  public final List<Integer> ext_pack_sfixed32;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1206,
      adapter = "com.squareup.wire.ProtoAdapter#INT64",
      label = WireField.Label.PACKED
  )
  public final List<Long> ext_pack_int64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1207,
      adapter = "com.squareup.wire.ProtoAdapter#UINT64",
      label = WireField.Label.PACKED
  )
  public final List<Long> ext_pack_uint64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1208,
      adapter = "com.squareup.wire.ProtoAdapter#SINT64",
      label = WireField.Label.PACKED
  )
  public final List<Long> ext_pack_sint64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1209,
      adapter = "com.squareup.wire.ProtoAdapter#FIXED64",
      label = WireField.Label.PACKED
  )
  public final List<Long> ext_pack_fixed64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1210,
      adapter = "com.squareup.wire.ProtoAdapter#SFIXED64",
      label = WireField.Label.PACKED
  )
  public final List<Long> ext_pack_sfixed64;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1211,
      adapter = "com.squareup.wire.ProtoAdapter#BOOL",
      label = WireField.Label.PACKED
  )
  public final List<Boolean> ext_pack_bool;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1212,
      adapter = "com.squareup.wire.ProtoAdapter#FLOAT",
      label = WireField.Label.PACKED
  )
  public final List<Float> ext_pack_float;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1213,
      adapter = "com.squareup.wire.ProtoAdapter#DOUBLE",
      label = WireField.Label.PACKED
  )
  public final List<Double> ext_pack_double;

  /**
   * Extension source: all_types.proto
   */
  @WireField(
      tag = 1216,
      adapter = "com.squareup.wire.protos.alltypes.AllTypes$NestedEnum#ADAPTER",
      label = WireField.Label.PACKED
  )
  public final List<NestedEnum> ext_pack_nested_enum;

  public AllTypes(Builder builder, ByteString unknownFields) {
    super(ADAPTER, unknownFields);
    this.opt_int32 = builder.opt_int32;
    this.opt_uint32 = builder.opt_uint32;
    this.opt_sint32 = builder.opt_sint32;
    this.opt_fixed32 = builder.opt_fixed32;
    this.opt_sfixed32 = builder.opt_sfixed32;
    this.opt_int64 = builder.opt_int64;
    this.opt_uint64 = builder.opt_uint64;
    this.opt_sint64 = builder.opt_sint64;
    this.opt_fixed64 = builder.opt_fixed64;
    this.opt_sfixed64 = builder.opt_sfixed64;
    this.opt_bool = builder.opt_bool;
    this.opt_float = builder.opt_float;
    this.opt_double = builder.opt_double;
    this.opt_string = builder.opt_string;
    this.opt_bytes = builder.opt_bytes;
    this.opt_nested_enum = builder.opt_nested_enum;
    this.opt_nested_message = builder.opt_nested_message;
    this.req_int32 = builder.req_int32;
    this.req_uint32 = builder.req_uint32;
    this.req_sint32 = builder.req_sint32;
    this.req_fixed32 = builder.req_fixed32;
    this.req_sfixed32 = builder.req_sfixed32;
    this.req_int64 = builder.req_int64;
    this.req_uint64 = builder.req_uint64;
    this.req_sint64 = builder.req_sint64;
    this.req_fixed64 = builder.req_fixed64;
    this.req_sfixed64 = builder.req_sfixed64;
    this.req_bool = builder.req_bool;
    this.req_float = builder.req_float;
    this.req_double = builder.req_double;
    this.req_string = builder.req_string;
    this.req_bytes = builder.req_bytes;
    this.req_nested_enum = builder.req_nested_enum;
    this.req_nested_message = builder.req_nested_message;
    this.rep_int32 = Internal.immutableCopyOf("rep_int32", builder.rep_int32);
    this.rep_uint32 = Internal.immutableCopyOf("rep_uint32", builder.rep_uint32);
    this.rep_sint32 = Internal.immutableCopyOf("rep_sint32", builder.rep_sint32);
    this.rep_fixed32 = Internal.immutableCopyOf("rep_fixed32", builder.rep_fixed32);
    this.rep_sfixed32 = Internal.immutableCopyOf("rep_sfixed32", builder.rep_sfixed32);
    this.rep_int64 = Internal.immutableCopyOf("rep_int64", builder.rep_int64);
    this.rep_uint64 = Internal.immutableCopyOf("rep_uint64", builder.rep_uint64);
    this.rep_sint64 = Internal.immutableCopyOf("rep_sint64", builder.rep_sint64);
    this.rep_fixed64 = Internal.immutableCopyOf("rep_fixed64", builder.rep_fixed64);
    this.rep_sfixed64 = Internal.immutableCopyOf("rep_sfixed64", builder.rep_sfixed64);
    this.rep_bool = Internal.immutableCopyOf("rep_bool", builder.rep_bool);
    this.rep_float = Internal.immutableCopyOf("rep_float", builder.rep_float);
    this.rep_double = Internal.immutableCopyOf("rep_double", builder.rep_double);
    this.rep_string = Internal.immutableCopyOf("rep_string", builder.rep_string);
    this.rep_bytes = Internal.immutableCopyOf("rep_bytes", builder.rep_bytes);
    this.rep_nested_enum = Internal.immutableCopyOf("rep_nested_enum", builder.rep_nested_enum);
    this.rep_nested_message = Internal.immutableCopyOf("rep_nested_message", builder.rep_nested_message);
    this.pack_int32 = Internal.immutableCopyOf("pack_int32", builder.pack_int32);
    this.pack_uint32 = Internal.immutableCopyOf("pack_uint32", builder.pack_uint32);
    this.pack_sint32 = Internal.immutableCopyOf("pack_sint32", builder.pack_sint32);
    this.pack_fixed32 = Internal.immutableCopyOf("pack_fixed32", builder.pack_fixed32);
    this.pack_sfixed32 = Internal.immutableCopyOf("pack_sfixed32", builder.pack_sfixed32);
    this.pack_int64 = Internal.immutableCopyOf("pack_int64", builder.pack_int64);
    this.pack_uint64 = Internal.immutableCopyOf("pack_uint64", builder.pack_uint64);
    this.pack_sint64 = Internal.immutableCopyOf("pack_sint64", builder.pack_sint64);
    this.pack_fixed64 = Internal.immutableCopyOf("pack_fixed64", builder.pack_fixed64);
    this.pack_sfixed64 = Internal.immutableCopyOf("pack_sfixed64", builder.pack_sfixed64);
    this.pack_bool = Internal.immutableCopyOf("pack_bool", builder.pack_bool);
    this.pack_float = Internal.immutableCopyOf("pack_float", builder.pack_float);
    this.pack_double = Internal.immutableCopyOf("pack_double", builder.pack_double);
    this.pack_nested_enum = Internal.immutableCopyOf("pack_nested_enum", builder.pack_nested_enum);
    this.default_int32 = builder.default_int32;
    this.default_uint32 = builder.default_uint32;
    this.default_sint32 = builder.default_sint32;
    this.default_fixed32 = builder.default_fixed32;
    this.default_sfixed32 = builder.default_sfixed32;
    this.default_int64 = builder.default_int64;
    this.default_uint64 = builder.default_uint64;
    this.default_sint64 = builder.default_sint64;
    this.default_fixed64 = builder.default_fixed64;
    this.default_sfixed64 = builder.default_sfixed64;
    this.default_bool = builder.default_bool;
    this.default_float = builder.default_float;
    this.default_double = builder.default_double;
    this.default_string = builder.default_string;
    this.default_bytes = builder.default_bytes;
    this.default_nested_enum = builder.default_nested_enum;
    this.map_int32_int32 = Internal.immutableCopyOf("map_int32_int32", builder.map_int32_int32);
    this.map_string_string = Internal.immutableCopyOf("map_string_string", builder.map_string_string);
    this.map_string_message = Internal.immutableCopyOf("map_string_message", builder.map_string_message);
    this.map_string_enum = Internal.immutableCopyOf("map_string_enum", builder.map_string_enum);
    this.ext_opt_int32 = builder.ext_opt_int32;
    this.ext_opt_uint32 = builder.ext_opt_uint32;
    this.ext_opt_sint32 = builder.ext_opt_sint32;
    this.ext_opt_fixed32 = builder.ext_opt_fixed32;
    this.ext_opt_sfixed32 = builder.ext_opt_sfixed32;
    this.ext_opt_int64 = builder.ext_opt_int64;
    this.ext_opt_uint64 = builder.ext_opt_uint64;
    this.ext_opt_sint64 = builder.ext_opt_sint64;
    this.ext_opt_fixed64 = builder.ext_opt_fixed64;
    this.ext_opt_sfixed64 = builder.ext_opt_sfixed64;
    this.ext_opt_bool = builder.ext_opt_bool;
    this.ext_opt_float = builder.ext_opt_float;
    this.ext_opt_double = builder.ext_opt_double;
    this.ext_opt_string = builder.ext_opt_string;
    this.ext_opt_bytes = builder.ext_opt_bytes;
    this.ext_opt_nested_enum = builder.ext_opt_nested_enum;
    this.ext_opt_nested_message = builder.ext_opt_nested_message;
    this.ext_rep_int32 = Internal.immutableCopyOf("ext_rep_int32", builder.ext_rep_int32);
    this.ext_rep_uint32 = Internal.immutableCopyOf("ext_rep_uint32", builder.ext_rep_uint32);
    this.ext_rep_sint32 = Internal.immutableCopyOf("ext_rep_sint32", builder.ext_rep_sint32);
    this.ext_rep_fixed32 = Internal.immutableCopyOf("ext_rep_fixed32", builder.ext_rep_fixed32);
    this.ext_rep_sfixed32 = Internal.immutableCopyOf("ext_rep_sfixed32", builder.ext_rep_sfixed32);
    this.ext_rep_int64 = Internal.immutableCopyOf("ext_rep_int64", builder.ext_rep_int64);
    this.ext_rep_uint64 = Internal.immutableCopyOf("ext_rep_uint64", builder.ext_rep_uint64);
    this.ext_rep_sint64 = Internal.immutableCopyOf("ext_rep_sint64", builder.ext_rep_sint64);
    this.ext_rep_fixed64 = Internal.immutableCopyOf("ext_rep_fixed64", builder.ext_rep_fixed64);
    this.ext_rep_sfixed64 = Internal.immutableCopyOf("ext_rep_sfixed64", builder.ext_rep_sfixed64);
    this.ext_rep_bool = Internal.immutableCopyOf("ext_rep_bool", builder.ext_rep_bool);
    this.ext_rep_float = Internal.immutableCopyOf("ext_rep_float", builder.ext_rep_float);
    this.ext_rep_double = Internal.immutableCopyOf("ext_rep_double", builder.ext_rep_double);
    this.ext_rep_string = Internal.immutableCopyOf("ext_rep_string", builder.ext_rep_string);
    this.ext_rep_bytes = Internal.immutableCopyOf("ext_rep_bytes", builder.ext_rep_bytes);
    this.ext_rep_nested_enum = Internal.immutableCopyOf("ext_rep_nested_enum", builder.ext_rep_nested_enum);
    this.ext_rep_nested_message = Internal.immutableCopyOf("ext_rep_nested_message", builder.ext_rep_nested_message);
    this.ext_pack_int32 = Internal.immutableCopyOf("ext_pack_int32", builder.ext_pack_int32);
    this.ext_pack_uint32 = Internal.immutableCopyOf("ext_pack_uint32", builder.ext_pack_uint32);
    this.ext_pack_sint32 = Internal.immutableCopyOf("ext_pack_sint32", builder.ext_pack_sint32);
    this.ext_pack_fixed32 = Internal.immutableCopyOf("ext_pack_fixed32", builder.ext_pack_fixed32);
    this.ext_pack_sfixed32 = Internal.immutableCopyOf("ext_pack_sfixed32", builder.ext_pack_sfixed32);
    this.ext_pack_int64 = Internal.immutableCopyOf("ext_pack_int64", builder.ext_pack_int64);
    this.ext_pack_uint64 = Internal.immutableCopyOf("ext_pack_uint64", builder.ext_pack_uint64);
    this.ext_pack_sint64 = Internal.immutableCopyOf("ext_pack_sint64", builder.ext_pack_sint64);
    this.ext_pack_fixed64 = Internal.immutableCopyOf("ext_pack_fixed64", builder.ext_pack_fixed64);
    this.ext_pack_sfixed64 = Internal.immutableCopyOf("ext_pack_sfixed64", builder.ext_pack_sfixed64);
    this.ext_pack_bool = Internal.immutableCopyOf("ext_pack_bool", builder.ext_pack_bool);
    this.ext_pack_float = Internal.immutableCopyOf("ext_pack_float", builder.ext_pack_float);
    this.ext_pack_double = Internal.immutableCopyOf("ext_pack_double", builder.ext_pack_double);
    this.ext_pack_nested_enum = Internal.immutableCopyOf("ext_pack_nested_enum", builder.ext_pack_nested_enum);
  }

  @Override
  public Builder newBuilder() {
    Builder builder = new Builder();
    builder.opt_int32 = opt_int32;
    builder.opt_uint32 = opt_uint32;
    builder.opt_sint32 = opt_sint32;
    builder.opt_fixed32 = opt_fixed32;
    builder.opt_sfixed32 = opt_sfixed32;
    builder.opt_int64 = opt_int64;
    builder.opt_uint64 = opt_uint64;
    builder.opt_sint64 = opt_sint64;
    builder.opt_fixed64 = opt_fixed64;
    builder.opt_sfixed64 = opt_sfixed64;
    builder.opt_bool = opt_bool;
    builder.opt_float = opt_float;
    builder.opt_double = opt_double;
    builder.opt_string = opt_string;
    builder.opt_bytes = opt_bytes;
    builder.opt_nested_enum = opt_nested_enum;
    builder.opt_nested_message = opt_nested_message;
    builder.req_int32 = req_int32;
    builder.req_uint32 = req_uint32;
    builder.req_sint32 = req_sint32;
    builder.req_fixed32 = req_fixed32;
    builder.req_sfixed32 = req_sfixed32;
    builder.req_int64 = req_int64;
    builder.req_uint64 = req_uint64;
    builder.req_sint64 = req_sint64;
    builder.req_fixed64 = req_fixed64;
    builder.req_sfixed64 = req_sfixed64;
    builder.req_bool = req_bool;
    builder.req_float = req_float;
    builder.req_double = req_double;
    builder.req_string = req_string;
    builder.req_bytes = req_bytes;
    builder.req_nested_enum = req_nested_enum;
    builder.req_nested_message = req_nested_message;
    builder.rep_int32 = Internal.copyOf(rep_int32);
    builder.rep_uint32 = Internal.copyOf(rep_uint32);
    builder.rep_sint32 = Internal.copyOf(rep_sint32);
    builder.rep_fixed32 = Internal.copyOf(rep_fixed32);
    builder.rep_sfixed32 = Internal.copyOf(rep_sfixed32);
    builder.rep_int64 = Internal.copyOf(rep_int64);
    builder.rep_uint64 = Internal.copyOf(rep_uint64);
    builder.rep_sint64 = Internal.copyOf(rep_sint64);
    builder.rep_fixed64 = Internal.copyOf(rep_fixed64);
    builder.rep_sfixed64 = Internal.copyOf(rep_sfixed64);
    builder.rep_bool = Internal.copyOf(rep_bool);
    builder.rep_float = Internal.copyOf(rep_float);
    builder.rep_double = Internal.copyOf(rep_double);
    builder.rep_string = Internal.copyOf(rep_string);
    builder.rep_bytes = Internal.copyOf(rep_bytes);
    builder.rep_nested_enum = Internal.copyOf(rep_nested_enum);
    builder.rep_nested_message = Internal.copyOf(rep_nested_message);
    builder.pack_int32 = Internal.copyOf(pack_int32);
    builder.pack_uint32 = Internal.copyOf(pack_uint32);
    builder.pack_sint32 = Internal.copyOf(pack_sint32);
    builder.pack_fixed32 = Internal.copyOf(pack_fixed32);
    builder.pack_sfixed32 = Internal.copyOf(pack_sfixed32);
    builder.pack_int64 = Internal.copyOf(pack_int64);
    builder.pack_uint64 = Internal.copyOf(pack_uint64);
    builder.pack_sint64 = Internal.copyOf(pack_sint64);
    builder.pack_fixed64 = Internal.copyOf(pack_fixed64);
    builder.pack_sfixed64 = Internal.copyOf(pack_sfixed64);
    builder.pack_bool = Internal.copyOf(pack_bool);
    builder.pack_float = Internal.copyOf(pack_float);
    builder.pack_double = Internal.copyOf(pack_double);
    builder.pack_nested_enum = Internal.copyOf(pack_nested_enum);
    builder.default_int32 = default_int32;
    builder.default_uint32 = default_uint32;
    builder.default_sint32 = default_sint32;
    builder.default_fixed32 = default_fixed32;
    builder.default_sfixed32 = default_sfixed32;
    builder.default_int64 = default_int64;
    builder.default_uint64 = default_uint64;
    builder.default_sint64 = default_sint64;
    builder.default_fixed64 = default_fixed64;
    builder.default_sfixed64 = default_sfixed64;
    builder.default_bool = default_bool;
    builder.default_float = default_float;
    builder.default_double = default_double;
    builder.default_string = default_string;
    builder.default_bytes = default_bytes;
    builder.default_nested_enum = default_nested_enum;
    builder.map_int32_int32 = Internal.copyOf(map_int32_int32);
    builder.map_string_string = Internal.copyOf(map_string_string);
    builder.map_string_message = Internal.copyOf(map_string_message);
    builder.map_string_enum = Internal.copyOf(map_string_enum);
    builder.ext_opt_int32 = ext_opt_int32;
    builder.ext_opt_uint32 = ext_opt_uint32;
    builder.ext_opt_sint32 = ext_opt_sint32;
    builder.ext_opt_fixed32 = ext_opt_fixed32;
    builder.ext_opt_sfixed32 = ext_opt_sfixed32;
    builder.ext_opt_int64 = ext_opt_int64;
    builder.ext_opt_uint64 = ext_opt_uint64;
    builder.ext_opt_sint64 = ext_opt_sint64;
    builder.ext_opt_fixed64 = ext_opt_fixed64;
    builder.ext_opt_sfixed64 = ext_opt_sfixed64;
    builder.ext_opt_bool = ext_opt_bool;
    builder.ext_opt_float = ext_opt_float;
    builder.ext_opt_double = ext_opt_double;
    builder.ext_opt_string = ext_opt_string;
    builder.ext_opt_bytes = ext_opt_bytes;
    builder.ext_opt_nested_enum = ext_opt_nested_enum;
    builder.ext_opt_nested_message = ext_opt_nested_message;
    builder.ext_rep_int32 = Internal.copyOf(ext_rep_int32);
    builder.ext_rep_uint32 = Internal.copyOf(ext_rep_uint32);
    builder.ext_rep_sint32 = Internal.copyOf(ext_rep_sint32);
    builder.ext_rep_fixed32 = Internal.copyOf(ext_rep_fixed32);
    builder.ext_rep_sfixed32 = Internal.copyOf(ext_rep_sfixed32);
    builder.ext_rep_int64 = Internal.copyOf(ext_rep_int64);
    builder.ext_rep_uint64 = Internal.copyOf(ext_rep_uint64);
    builder.ext_rep_sint64 = Internal.copyOf(ext_rep_sint64);
    builder.ext_rep_fixed64 = Internal.copyOf(ext_rep_fixed64);
    builder.ext_rep_sfixed64 = Internal.copyOf(ext_rep_sfixed64);
    builder.ext_rep_bool = Internal.copyOf(ext_rep_bool);
    builder.ext_rep_float = Internal.copyOf(ext_rep_float);
    builder.ext_rep_double = Internal.copyOf(ext_rep_double);
    builder.ext_rep_string = Internal.copyOf(ext_rep_string);
    builder.ext_rep_bytes = Internal.copyOf(ext_rep_bytes);
    builder.ext_rep_nested_enum = Internal.copyOf(ext_rep_nested_enum);
    builder.ext_rep_nested_message = Internal.copyOf(ext_rep_nested_message);
    builder.ext_pack_int32 = Internal.copyOf(ext_pack_int32);
    builder.ext_pack_uint32 = Internal.copyOf(ext_pack_uint32);
    builder.ext_pack_sint32 = Internal.copyOf(ext_pack_sint32);
    builder.ext_pack_fixed32 = Internal.copyOf(ext_pack_fixed32);
    builder.ext_pack_sfixed32 = Internal.copyOf(ext_pack_sfixed32);
    builder.ext_pack_int64 = Internal.copyOf(ext_pack_int64);
    builder.ext_pack_uint64 = Internal.copyOf(ext_pack_uint64);
    builder.ext_pack_sint64 = Internal.copyOf(ext_pack_sint64);
    builder.ext_pack_fixed64 = Internal.copyOf(ext_pack_fixed64);
    builder.ext_pack_sfixed64 = Internal.copyOf(ext_pack_sfixed64);
    builder.ext_pack_bool = Internal.copyOf(ext_pack_bool);
    builder.ext_pack_float = Internal.copyOf(ext_pack_float);
    builder.ext_pack_double = Internal.copyOf(ext_pack_double);
    builder.ext_pack_nested_enum = Internal.copyOf(ext_pack_nested_enum);
    builder.addUnknownFields(unknownFields());
    return builder;
  }

  @Override
  public boolean equals(Object other) {
    if (other == this) return true;
    if (!(other instanceof AllTypes)) return false;
    AllTypes o = (AllTypes) other;
    return unknownFields().equals(o.unknownFields())
        && Internal.equals(opt_int32, o.opt_int32)
        && Internal.equals(opt_uint32, o.opt_uint32)
        && Internal.equals(opt_sint32, o.opt_sint32)
        && Internal.equals(opt_fixed32, o.opt_fixed32)
        && Internal.equals(opt_sfixed32, o.opt_sfixed32)
        && Internal.equals(opt_int64, o.opt_int64)
        && Internal.equals(opt_uint64, o.opt_uint64)
        && Internal.equals(opt_sint64, o.opt_sint64)
        && Internal.equals(opt_fixed64, o.opt_fixed64)
        && Internal.equals(opt_sfixed64, o.opt_sfixed64)
        && Internal.equals(opt_bool, o.opt_bool)
        && Internal.equals(opt_float, o.opt_float)
        && Internal.equals(opt_double, o.opt_double)
        && Internal.equals(opt_string, o.opt_string)
        && Internal.equals(opt_bytes, o.opt_bytes)
        && Internal.equals(opt_nested_enum, o.opt_nested_enum)
        && Internal.equals(opt_nested_message, o.opt_nested_message)
        && req_int32.equals(o.req_int32)
        && req_uint32.equals(o.req_uint32)
        && req_sint32.equals(o.req_sint32)
        && req_fixed32.equals(o.req_fixed32)
        && req_sfixed32.equals(o.req_sfixed32)
        && req_int64.equals(o.req_int64)
        && req_uint64.equals(o.req_uint64)
        && req_sint64.equals(o.req_sint64)
        && req_fixed64.equals(o.req_fixed64)
        && req_sfixed64.equals(o.req_sfixed64)
        && req_bool.equals(o.req_bool)
        && req_float.equals(o.req_float)
        && req_double.equals(o.req_double)
        && req_string.equals(o.req_string)
        && req_bytes.equals(o.req_bytes)
        && req_nested_enum.equals(o.req_nested_enum)
        && req_nested_message.equals(o.req_nested_message)
        && rep_int32.equals(o.rep_int32)
        && rep_uint32.equals(o.rep_uint32)
        && rep_sint32.equals(o.rep_sint32)
        && rep_fixed32.equals(o.rep_fixed32)
        && rep_sfixed32.equals(o.rep_sfixed32)
        && rep_int64.equals(o.rep_int64)
        && rep_uint64.equals(o.rep_uint64)
        && rep_sint64.equals(o.rep_sint64)
        && rep_fixed64.equals(o.rep_fixed64)
        && rep_sfixed64.equals(o.rep_sfixed64)
        && rep_bool.equals(o.rep_bool)
        && rep_float.equals(o.rep_float)
        && rep_double.equals(o.rep_double)
        && rep_string.equals(o.rep_string)
        && rep_bytes.equals(o.rep_bytes)
        && rep_nested_enum.equals(o.rep_nested_enum)
        && rep_nested_message.equals(o.rep_nested_message)
        && pack_int32.equals(o.pack_int32)
        && pack_uint32.equals(o.pack_uint32)
        && pack_sint32.equals(o.pack_sint32)
        && pack_fixed32.equals(o.pack_fixed32)
        && pack_sfixed32.equals(o.pack_sfixed32)
        && pack_int64.equals(o.pack_int64)
        && pack_uint64.equals(o.pack_uint64)
        && pack_sint64.equals(o.pack_sint64)
        && pack_fixed64.equals(o.pack_fixed64)
        && pack_sfixed64.equals(o.pack_sfixed64)
        && pack_bool.equals(o.pack_bool)
        && pack_float.equals(o.pack_float)
        && pack_double.equals(o.pack_double)
        && pack_nested_enum.equals(o.pack_nested_enum)
        && Internal.equals(default_int32, o.default_int32)
        && Internal.equals(default_uint32, o.default_uint32)
        && Internal.equals(default_sint32, o.default_sint32)
        && Internal.equals(default_fixed32, o.default_fixed32)
        && Internal.equals(default_sfixed32, o.default_sfixed32)
        && Internal.equals(default_int64, o.default_int64)
        && Internal.equals(default_uint64, o.default_uint64)
        && Internal.equals(default_sint64, o.default_sint64)
        && Internal.equals(default_fixed64, o.default_fixed64)
        && Internal.equals(default_sfixed64, o.default_sfixed64)
        && Internal.equals(default_bool, o.default_bool)
        && Internal.equals(default_float, o.default_float)
        && Internal.equals(default_double, o.default_double)
        && Internal.equals(default_string, o.default_string)
        && Internal.equals(default_bytes, o.default_bytes)
        && Internal.equals(default_nested_enum, o.default_nested_enum)
        && map_int32_int32.equals(o.map_int32_int32)
        && map_string_string.equals(o.map_string_string)
        && map_string_message.equals(o.map_string_message)
        && map_string_enum.equals(o.map_string_enum)
        && Internal.equals(ext_opt_int32, o.ext_opt_int32)
        && Internal.equals(ext_opt_uint32, o.ext_opt_uint32)
        && Internal.equals(ext_opt_sint32, o.ext_opt_sint32)
        && Internal.equals(ext_opt_fixed32, o.ext_opt_fixed32)
        && Internal.equals(ext_opt_sfixed32, o.ext_opt_sfixed32)
        && Internal.equals(ext_opt_int64, o.ext_opt_int64)
        && Internal.equals(ext_opt_uint64, o.ext_opt_uint64)
        && Internal.equals(ext_opt_sint64, o.ext_opt_sint64)
        && Internal.equals(ext_opt_fixed64, o.ext_opt_fixed64)
        && Internal.equals(ext_opt_sfixed64, o.ext_opt_sfixed64)
        && Internal.equals(ext_opt_bool, o.ext_opt_bool)
        && Internal.equals(ext_opt_float, o.ext_opt_float)
        && Internal.equals(ext_opt_double, o.ext_opt_double)
        && Internal.equals(ext_opt_string, o.ext_opt_string)
        && Internal.equals(ext_opt_bytes, o.ext_opt_bytes)
        && Internal.equals(ext_opt_nested_enum, o.ext_opt_nested_enum)
        && Internal.equals(ext_opt_nested_message, o.ext_opt_nested_message)
        && ext_rep_int32.equals(o.ext_rep_int32)
        && ext_rep_uint32.equals(o.ext_rep_uint32)
        && ext_rep_sint32.equals(o.ext_rep_sint32)
        && ext_rep_fixed32.equals(o.ext_rep_fixed32)
        && ext_rep_sfixed32.equals(o.ext_rep_sfixed32)
        && ext_rep_int64.equals(o.ext_rep_int64)
        && ext_rep_uint64.equals(o.ext_rep_uint64)
        && ext_rep_sint64.equals(o.ext_rep_sint64)
        && ext_rep_fixed64.equals(o.ext_rep_fixed64)
        && ext_rep_sfixed64.equals(o.ext_rep_sfixed64)
        && ext_rep_bool.equals(o.ext_rep_bool)
        && ext_rep_float.equals(o.ext_rep_float)
        && ext_rep_double.equals(o.ext_rep_double)
        && ext_rep_string.equals(o.ext_rep_string)
        && ext_rep_bytes.equals(o.ext_rep_bytes)
        && ext_rep_nested_enum.equals(o.ext_rep_nested_enum)
        && ext_rep_nested_message.equals(o.ext_rep_nested_message)
        && ext_pack_int32.equals(o.ext_pack_int32)
        && ext_pack_uint32.equals(o.ext_pack_uint32)
        && ext_pack_sint32.equals(o.ext_pack_sint32)
        && ext_pack_fixed32.equals(o.ext_pack_fixed32)
        && ext_pack_sfixed32.equals(o.ext_pack_sfixed32)
        && ext_pack_int64.equals(o.ext_pack_int64)
        && ext_pack_uint64.equals(o.ext_pack_uint64)
        && ext_pack_sint64.equals(o.ext_pack_sint64)
        && ext_pack_fixed64.equals(o.ext_pack_fixed64)
        && ext_pack_sfixed64.equals(o.ext_pack_sfixed64)
        && ext_pack_bool.equals(o.ext_pack_bool)
        && ext_pack_float.equals(o.ext_pack_float)
        && ext_pack_double.equals(o.ext_pack_double)
        && ext_pack_nested_enum.equals(o.ext_pack_nested_enum);
  }

  @Override
  public int hashCode() {
    int result = super.hashCode;
    if (result == 0) {
      result = unknownFields().hashCode();
      result = result * 37 + (opt_int32 != null ? opt_int32.hashCode() : 0);
      result = result * 37 + (opt_uint32 != null ? opt_uint32.hashCode() : 0);
      result = result * 37 + (opt_sint32 != null ? opt_sint32.hashCode() : 0);
      result = result * 37 + (opt_fixed32 != null ? opt_fixed32.hashCode() : 0);
      result = result * 37 + (opt_sfixed32 != null ? opt_sfixed32.hashCode() : 0);
      result = result * 37 + (opt_int64 != null ? opt_int64.hashCode() : 0);
      result = result * 37 + (opt_uint64 != null ? opt_uint64.hashCode() : 0);
      result = result * 37 + (opt_sint64 != null ? opt_sint64.hashCode() : 0);
      result = result * 37 + (opt_fixed64 != null ? opt_fixed64.hashCode() : 0);
      result = result * 37 + (opt_sfixed64 != null ? opt_sfixed64.hashCode() : 0);
      result = result * 37 + (opt_bool != null ? opt_bool.hashCode() : 0);
      result = result * 37 + (opt_float != null ? opt_float.hashCode() : 0);
      result = result * 37 + (opt_double != null ? opt_double.hashCode() : 0);
      result = result * 37 + (opt_string != null ? opt_string.hashCode() : 0);
      result = result * 37 + (opt_bytes != null ? opt_bytes.hashCode() : 0);
      result = result * 37 + (opt_nested_enum != null ? opt_nested_enum.hashCode() : 0);
      result = result * 37 + (opt_nested_message != null ? opt_nested_message.hashCode() : 0);
      result = result * 37 + req_int32.hashCode();
      result = result * 37 + req_uint32.hashCode();
      result = result * 37 + req_sint32.hashCode();
      result = result * 37 + req_fixed32.hashCode();
      result = result * 37 + req_sfixed32.hashCode();
      result = result * 37 + req_int64.hashCode();
      result = result * 37 + req_uint64.hashCode();
      result = result * 37 + req_sint64.hashCode();
      result = result * 37 + req_fixed64.hashCode();
      result = result * 37 + req_sfixed64.hashCode();
      result = result * 37 + req_bool.hashCode();
      result = result * 37 + req_float.hashCode();
      result = result * 37 + req_double.hashCode();
      result = result * 37 + req_string.hashCode();
      result = result * 37 + req_bytes.hashCode();
      result = result * 37 + req_nested_enum.hashCode();
      result = result * 37 + req_nested_message.hashCode();
      result = result * 37 + rep_int32.hashCode();
      result = result * 37 + rep_uint32.hashCode();
      result = result * 37 + rep_sint32.hashCode();
      result = result * 37 + rep_fixed32.hashCode();
      result = result * 37 + rep_sfixed32.hashCode();
      result = result * 37 + rep_int64.hashCode();
      result = result * 37 + rep_uint64.hashCode();
      result = result * 37 + rep_sint64.hashCode();
      result = result * 37 + rep_fixed64.hashCode();
      result = result * 37 + rep_sfixed64.hashCode();
      result = result * 37 + rep_bool.hashCode();
      result = result * 37 + rep_float.hashCode();
      result = result * 37 + rep_double.hashCode();
      result = result * 37 + rep_string.hashCode();
      result = result * 37 + rep_bytes.hashCode();
      result = result * 37 + rep_nested_enum.hashCode();
      result = result * 37 + rep_nested_message.hashCode();
      result = result * 37 + pack_int32.hashCode();
      result = result * 37 + pack_uint32.hashCode();
      result = result * 37 + pack_sint32.hashCode();
      result = result * 37 + pack_fixed32.hashCode();
      result = result * 37 + pack_sfixed32.hashCode();
      result = result * 37 + pack_int64.hashCode();
      result = result * 37 + pack_uint64.hashCode();
      result = result * 37 + pack_sint64.hashCode();
      result = result * 37 + pack_fixed64.hashCode();
      result = result * 37 + pack_sfixed64.hashCode();
      result = result * 37 + pack_bool.hashCode();
      result = result * 37 + pack_float.hashCode();
      result = result * 37 + pack_double.hashCode();
      result = result * 37 + pack_nested_enum.hashCode();
      result = result * 37 + (default_int32 != null ? default_int32.hashCode() : 0);
      result = result * 37 + (default_uint32 != null ? default_uint32.hashCode() : 0);
      result = result * 37 + (default_sint32 != null ? default_sint32.hashCode() : 0);
      result = result * 37 + (default_fixed32 != null ? default_fixed32.hashCode() : 0);
      result = result * 37 + (default_sfixed32 != null ? default_sfixed32.hashCode() : 0);
      result = result * 37 + (default_int64 != null ? default_int64.hashCode() : 0);
      result = result * 37 + (default_uint64 != null ? default_uint64.hashCode() : 0);
      result = result * 37 + (default_sint64 != null ? default_sint64.hashCode() : 0);
      result = result * 37 + (default_fixed64 != null ? default_fixed64.hashCode() : 0);
      result = result * 37 + (default_sfixed64 != null ? default_sfixed64.hashCode() : 0);
      result = result * 37 + (default_bool != null ? default_bool.hashCode() : 0);
      result = result * 37 + (default_float != null ? default_float.hashCode() : 0);
      result = result * 37 + (default_double != null ? default_double.hashCode() : 0);
      result = result * 37 + (default_string != null ? default_string.hashCode() : 0);
      result = result * 37 + (default_bytes != null ? default_bytes.hashCode() : 0);
      result = result * 37 + (default_nested_enum != null ? default_nested_enum.hashCode() : 0);
      result = result * 37 + map_int32_int32.hashCode();
      result = result * 37 + map_string_string.hashCode();
      result = result * 37 + map_string_message.hashCode();
      result = result * 37 + map_string_enum.hashCode();
      result = result * 37 + (ext_opt_int32 != null ? ext_opt_int32.hashCode() : 0);
      result = result * 37 + (ext_opt_uint32 != null ? ext_opt_uint32.hashCode() : 0);
      result = result * 37 + (ext_opt_sint32 != null ? ext_opt_sint32.hashCode() : 0);
      result = result * 37 + (ext_opt_fixed32 != null ? ext_opt_fixed32.hashCode() : 0);
      result = result * 37 + (ext_opt_sfixed32 != null ? ext_opt_sfixed32.hashCode() : 0);
      result = result * 37 + (ext_opt_int64 != null ? ext_opt_int64.hashCode() : 0);
      result = result * 37 + (ext_opt_uint64 != null ? ext_opt_uint64.hashCode() : 0);
      result = result * 37 + (ext_opt_sint64 != null ? ext_opt_sint64.hashCode() : 0);
      result = result * 37 + (ext_opt_fixed64 != null ? ext_opt_fixed64.hashCode() : 0);
      result = result * 37 + (ext_opt_sfixed64 != null ? ext_opt_sfixed64.hashCode() : 0);
      result = result * 37 + (ext_opt_bool != null ? ext_opt_bool.hashCode() : 0);
      result = result * 37 + (ext_opt_float != null ? ext_opt_float.hashCode() : 0);
      result = result * 37 + (ext_opt_double != null ? ext_opt_double.hashCode() : 0);
      result = result * 37 + (ext_opt_string != null ? ext_opt_string.hashCode() : 0);
      result = result * 37 + (ext_opt_bytes != null ? ext_opt_bytes.hashCode() : 0);
      result = result * 37 + (ext_opt_nested_enum != null ? ext_opt_nested_enum.hashCode() : 0);
      result = result * 37 + (ext_opt_nested_message != null ? ext_opt_nested_message.hashCode() : 0);
      result = result * 37 + ext_rep_int32.hashCode();
      result = result * 37 + ext_rep_uint32.hashCode();
      result = result * 37 + ext_rep_sint32.hashCode();
      result = result * 37 + ext_rep_fixed32.hashCode();
      result = result * 37 + ext_rep_sfixed32.hashCode();
      result = result * 37 + ext_rep_int64.hashCode();
      result = result * 37 + ext_rep_uint64.hashCode();
      result = result * 37 + ext_rep_sint64.hashCode();
      result = result * 37 + ext_rep_fixed64.hashCode();
      result = result * 37 + ext_rep_sfixed64.hashCode();
      result = result * 37 + ext_rep_bool.hashCode();
      result = result * 37 + ext_rep_float.hashCode();
      result = result * 37 + ext_rep_double.hashCode();
      result = result * 37 + ext_rep_string.hashCode();
      result = result * 37 + ext_rep_bytes.hashCode();
      result = result * 37 + ext_rep_nested_enum.hashCode();
      result = result * 37 + ext_rep_nested_message.hashCode();
      result = result * 37 + ext_pack_int32.hashCode();
      result = result * 37 + ext_pack_uint32.hashCode();
      result = result * 37 + ext_pack_sint32.hashCode();
      result = result * 37 + ext_pack_fixed32.hashCode();
      result = result * 37 + ext_pack_sfixed32.hashCode();
      result = result * 37 + ext_pack_int64.hashCode();
      result = result * 37 + ext_pack_uint64.hashCode();
      result = result * 37 + ext_pack_sint64.hashCode();
      result = result * 37 + ext_pack_fixed64.hashCode();
      result = result * 37 + ext_pack_sfixed64.hashCode();
      result = result * 37 + ext_pack_bool.hashCode();
      result = result * 37 + ext_pack_float.hashCode();
      result = result * 37 + ext_pack_double.hashCode();
      result = result * 37 + ext_pack_nested_enum.hashCode();
      super.hashCode = result;
    }
    return result;
  }

  @Override
  public String toString() {
    StringBuilder builder = new StringBuilder();
    if (opt_int32 != null) builder.append(", opt_int32=").append(opt_int32);
    if (opt_uint32 != null) builder.append(", opt_uint32=").append(opt_uint32);
    if (opt_sint32 != null) builder.append(", opt_sint32=").append(opt_sint32);
    if (opt_fixed32 != null) builder.append(", opt_fixed32=").append(opt_fixed32);
    if (opt_sfixed32 != null) builder.append(", opt_sfixed32=").append(opt_sfixed32);
    if (opt_int64 != null) builder.append(", opt_int64=").append(opt_int64);
    if (opt_uint64 != null) builder.append(", opt_uint64=").append(opt_uint64);
    if (opt_sint64 != null) builder.append(", opt_sint64=").append(opt_sint64);
    if (opt_fixed64 != null) builder.append(", opt_fixed64=").append(opt_fixed64);
    if (opt_sfixed64 != null) builder.append(", opt_sfixed64=").append(opt_sfixed64);
    if (opt_bool != null) builder.append(", opt_bool=").append(opt_bool);
    if (opt_float != null) builder.append(", opt_float=").append(opt_float);
    if (opt_double != null) builder.append(", opt_double=").append(opt_double);
    if (opt_string != null) builder.append(", opt_string=").append(Internal.sanitize(opt_string));
    if (opt_bytes != null) builder.append(", opt_bytes=").append(opt_bytes);
    if (opt_nested_enum != null) builder.append(", opt_nested_enum=").append(opt_nested_enum);
    if (opt_nested_message != null) builder.append(", opt_nested_message=").append(opt_nested_message);
    builder.append(", req_int32=").append(req_int32);
    builder.append(", req_uint32=").append(req_uint32);
    builder.append(", req_sint32=").append(req_sint32);
    builder.append(", req_fixed32=").append(req_fixed32);
    builder.append(", req_sfixed32=").append(req_sfixed32);
    builder.append(", req_int64=").append(req_int64);
    builder.append(", req_uint64=").append(req_uint64);
    builder.append(", req_sint64=").append(req_sint64);
    builder.append(", req_fixed64=").append(req_fixed64);
    builder.append(", req_sfixed64=").append(req_sfixed64);
    builder.append(", req_bool=").append(req_bool);
    builder.append(", req_float=").append(req_float);
    builder.append(", req_double=").append(req_double);
    builder.append(", req_string=").append(Internal.sanitize(req_string));
    builder.append(", req_bytes=").append(req_bytes);
    builder.append(", req_nested_enum=").append(req_nested_enum);
    builder.append(", req_nested_message=").append(req_nested_message);
    if (!rep_int32.isEmpty()) builder.append(", rep_int32=").append(rep_int32);
    if (!rep_uint32.isEmpty()) builder.append(", rep_uint32=").append(rep_uint32);
    if (!rep_sint32.isEmpty()) builder.append(", rep_sint32=").append(rep_sint32);
    if (!rep_fixed32.isEmpty()) builder.append(", rep_fixed32=").append(rep_fixed32);
    if (!rep_sfixed32.isEmpty()) builder.append(", rep_sfixed32=").append(rep_sfixed32);
    if (!rep_int64.isEmpty()) builder.append(", rep_int64=").append(rep_int64);
    if (!rep_uint64.isEmpty()) builder.append(", rep_uint64=").append(rep_uint64);
    if (!rep_sint64.isEmpty()) builder.append(", rep_sint64=").append(rep_sint64);
    if (!rep_fixed64.isEmpty()) builder.append(", rep_fixed64=").append(rep_fixed64);
    if (!rep_sfixed64.isEmpty()) builder.append(", rep_sfixed64=").append(rep_sfixed64);
    if (!rep_bool.isEmpty()) builder.append(", rep_bool=").append(rep_bool);
    if (!rep_float.isEmpty()) builder.append(", rep_float=").append(rep_float);
    if (!rep_double.isEmpty()) builder.append(", rep_double=").append(rep_double);
    if (!rep_string.isEmpty()) builder.append(", rep_string=").append(Internal.sanitize(rep_string));
    if (!rep_bytes.isEmpty()) builder.append(", rep_bytes=").append(rep_bytes);
    if (!rep_nested_enum.isEmpty()) builder.append(", rep_nested_enum=").append(rep_nested_enum);
    if (!rep_nested_message.isEmpty()) builder.append(", rep_nested_message=").append(rep_nested_message);
    if (!pack_int32.isEmpty()) builder.append(", pack_int32=").append(pack_int32);
    if (!pack_uint32.isEmpty()) builder.append(", pack_uint32=").append(pack_uint32);
    if (!pack_sint32.isEmpty()) builder.append(", pack_sint32=").append(pack_sint32);
    if (!pack_fixed32.isEmpty()) builder.append(", pack_fixed32=").append(pack_fixed32);
    if (!pack_sfixed32.isEmpty()) builder.append(", pack_sfixed32=").append(pack_sfixed32);
    if (!pack_int64.isEmpty()) builder.append(", pack_int64=").append(pack_int64);
    if (!pack_uint64.isEmpty()) builder.append(", pack_uint64=").append(pack_uint64);
    if (!pack_sint64.isEmpty()) builder.append(", pack_sint64=").append(pack_sint64);
    if (!pack_fixed64.isEmpty()) builder.append(", pack_fixed64=").append(pack_fixed64);
    if (!pack_sfixed64.isEmpty()) builder.append(", pack_sfixed64=").append(pack_sfixed64);
    if (!pack_bool.isEmpty()) builder.append(", pack_bool=").append(pack_bool);
    if (!pack_float.isEmpty()) builder.append(", pack_float=").append(pack_float);
    if (!pack_double.isEmpty()) builder.append(", pack_double=").append(pack_double);
    if (!pack_nested_enum.isEmpty()) builder.append(", pack_nested_enum=").append(pack_nested_enum);
    if (default_int32 != null) builder.append(", default_int32=").append(default_int32);
    if (default_uint32 != null) builder.append(", default_uint32=").append(default_uint32);
    if (default_sint32 != null) builder.append(", default_sint32=").append(default_sint32);
    if (default_fixed32 != null) builder.append(", default_fixed32=").append(default_fixed32);
    if (default_sfixed32 != null) builder.append(", default_sfixed32=").append(default_sfixed32);
    if (default_int64 != null) builder.append(", default_int64=").append(default_int64);
    if (default_uint64 != null) builder.append(", default_uint64=").append(default_uint64);
    if (default_sint64 != null) builder.append(", default_sint64=").append(default_sint64);
    if (default_fixed64 != null) builder.append(", default_fixed64=").append(default_fixed64);
    if (default_sfixed64 != null) builder.append(", default_sfixed64=").append(default_sfixed64);
    if (default_bool != null) builder.append(", default_bool=").append(default_bool);
    if (default_float != null) builder.append(", default_float=").append(default_float);
    if (default_double != null) builder.append(", default_double=").append(default_double);
    if (default_string != null) builder.append(", default_string=").append(Internal.sanitize(default_string));
    if (default_bytes != null) builder.append(", default_bytes=").append(default_bytes);
    if (default_nested_enum != null) builder.append(", default_nested_enum=").append(default_nested_enum);
    if (!map_int32_int32.isEmpty()) builder.append(", map_int32_int32=").append(map_int32_int32);
    if (!map_string_string.isEmpty()) builder.append(", map_string_string=").append(map_string_string);
    if (!map_string_message.isEmpty()) builder.append(", map_string_message=").append(map_string_message);
    if (!map_string_enum.isEmpty()) builder.append(", map_string_enum=").append(map_string_enum);
    if (ext_opt_int32 != null) builder.append(", ext_opt_int32=").append(ext_opt_int32);
    if (ext_opt_uint32 != null) builder.append(", ext_opt_uint32=").append(ext_opt_uint32);
    if (ext_opt_sint32 != null) builder.append(", ext_opt_sint32=").append(ext_opt_sint32);
    if (ext_opt_fixed32 != null) builder.append(", ext_opt_fixed32=").append(ext_opt_fixed32);
    if (ext_opt_sfixed32 != null) builder.append(", ext_opt_sfixed32=").append(ext_opt_sfixed32);
    if (ext_opt_int64 != null) builder.append(", ext_opt_int64=").append(ext_opt_int64);
    if (ext_opt_uint64 != null) builder.append(", ext_opt_uint64=").append(ext_opt_uint64);
    if (ext_opt_sint64 != null) builder.append(", ext_opt_sint64=").append(ext_opt_sint64);
    if (ext_opt_fixed64 != null) builder.append(", ext_opt_fixed64=").append(ext_opt_fixed64);
    if (ext_opt_sfixed64 != null) builder.append(", ext_opt_sfixed64=").append(ext_opt_sfixed64);
    if (ext_opt_bool != null) builder.append(", ext_opt_bool=").append(ext_opt_bool);
    if (ext_opt_float != null) builder.append(", ext_opt_float=").append(ext_opt_float);
    if (ext_opt_double != null) builder.append(", ext_opt_double=").append(ext_opt_double);
    if (ext_opt_string != null) builder.append(", ext_opt_string=").append(Internal.sanitize(ext_opt_string));
    if (ext_opt_bytes != null) builder.append(", ext_opt_bytes=").append(ext_opt_bytes);
    if (ext_opt_nested_enum != null) builder.append(", ext_opt_nested_enum=").append(ext_opt_nested_enum);
    if (ext_opt_nested_message != null) builder.append(", ext_opt_nested_message=").append(ext_opt_nested_message);
    if (!ext_rep_int32.isEmpty()) builder.append(", ext_rep_int32=").append(ext_rep_int32);
    if (!ext_rep_uint32.isEmpty()) builder.append(", ext_rep_uint32=").append(ext_rep_uint32);
    if (!ext_rep_sint32.isEmpty()) builder.append(", ext_rep_sint32=").append(ext_rep_sint32);
    if (!ext_rep_fixed32.isEmpty()) builder.append(", ext_rep_fixed32=").append(ext_rep_fixed32);
    if (!ext_rep_sfixed32.isEmpty()) builder.append(", ext_rep_sfixed32=").append(ext_rep_sfixed32);
    if (!ext_rep_int64.isEmpty()) builder.append(", ext_rep_int64=").append(ext_rep_int64);
    if (!ext_rep_uint64.isEmpty()) builder.append(", ext_rep_uint64=").append(ext_rep_uint64);
    if (!ext_rep_sint64.isEmpty()) builder.append(", ext_rep_sint64=").append(ext_rep_sint64);
    if (!ext_rep_fixed64.isEmpty()) builder.append(", ext_rep_fixed64=").append(ext_rep_fixed64);
    if (!ext_rep_sfixed64.isEmpty()) builder.append(", ext_rep_sfixed64=").append(ext_rep_sfixed64);
    if (!ext_rep_bool.isEmpty()) builder.append(", ext_rep_bool=").append(ext_rep_bool);
    if (!ext_rep_float.isEmpty()) builder.append(", ext_rep_float=").append(ext_rep_float);
    if (!ext_rep_double.isEmpty()) builder.append(", ext_rep_double=").append(ext_rep_double);
    if (!ext_rep_string.isEmpty()) builder.append(", ext_rep_string=").append(Internal.sanitize(ext_rep_string));
    if (!ext_rep_bytes.isEmpty()) builder.append(", ext_rep_bytes=").append(ext_rep_bytes);
    if (!ext_rep_nested_enum.isEmpty()) builder.append(", ext_rep_nested_enum=").append(ext_rep_nested_enum);
    if (!ext_rep_nested_message.isEmpty()) builder.append(", ext_rep_nested_message=").append(ext_rep_nested_message);
    if (!ext_pack_int32.isEmpty()) builder.append(", ext_pack_int32=").append(ext_pack_int32);
    if (!ext_pack_uint32.isEmpty()) builder.append(", ext_pack_uint32=").append(ext_pack_uint32);
    if (!ext_pack_sint32.isEmpty()) builder.append(", ext_pack_sint32=").append(ext_pack_sint32);
    if (!ext_pack_fixed32.isEmpty()) builder.append(", ext_pack_fixed32=").append(ext_pack_fixed32);
    if (!ext_pack_sfixed32.isEmpty()) builder.append(", ext_pack_sfixed32=").append(ext_pack_sfixed32);
    if (!ext_pack_int64.isEmpty()) builder.append(", ext_pack_int64=").append(ext_pack_int64);
    if (!ext_pack_uint64.isEmpty()) builder.append(", ext_pack_uint64=").append(ext_pack_uint64);
    if (!ext_pack_sint64.isEmpty()) builder.append(", ext_pack_sint64=").append(ext_pack_sint64);
    if (!ext_pack_fixed64.isEmpty()) builder.append(", ext_pack_fixed64=").append(ext_pack_fixed64);
    if (!ext_pack_sfixed64.isEmpty()) builder.append(", ext_pack_sfixed64=").append(ext_pack_sfixed64);
    if (!ext_pack_bool.isEmpty()) builder.append(", ext_pack_bool=").append(ext_pack_bool);
    if (!ext_pack_float.isEmpty()) builder.append(", ext_pack_float=").append(ext_pack_float);
    if (!ext_pack_double.isEmpty()) builder.append(", ext_pack_double=").append(ext_pack_double);
    if (!ext_pack_nested_enum.isEmpty()) builder.append(", ext_pack_nested_enum=").append(ext_pack_nested_enum);
    return builder.replace(0, 2, "AllTypes{").append('}').toString();
  }

  public static final class Builder extends Message.Builder<AllTypes, Builder> {
    public Integer opt_int32;

    public Integer opt_uint32;

    public Integer opt_sint32;

    public Integer opt_fixed32;

    public Integer opt_sfixed32;

    public Long opt_int64;

    public Long opt_uint64;

    public Long opt_sint64;

    public Long opt_fixed64;

    public Long opt_sfixed64;

    public Boolean opt_bool;

    public Float opt_float;

    public Double opt_double;

    public String opt_string;

    public ByteString opt_bytes;

    public NestedEnum opt_nested_enum;

    public NestedMessage opt_nested_message;

    public Integer req_int32;

    public Integer req_uint32;

    public Integer req_sint32;

    public Integer req_fixed32;

    public Integer req_sfixed32;

    public Long req_int64;

    public Long req_uint64;

    public Long req_sint64;

    public Long req_fixed64;

    public Long req_sfixed64;

    public Boolean req_bool;

    public Float req_float;

    public Double req_double;

    public String req_string;

    public ByteString req_bytes;

    public NestedEnum req_nested_enum;

    public NestedMessage req_nested_message;

    public List<Integer> rep_int32;

    public List<Integer> rep_uint32;

    public List<Integer> rep_sint32;

    public List<Integer> rep_fixed32;

    public List<Integer> rep_sfixed32;

    public List<Long> rep_int64;

    public List<Long> rep_uint64;

    public List<Long> rep_sint64;

    public List<Long> rep_fixed64;

    public List<Long> rep_sfixed64;

    public List<Boolean> rep_bool;

    public List<Float> rep_float;

    public List<Double> rep_double;

    public List<String> rep_string;

    public List<ByteString> rep_bytes;

    public List<NestedEnum> rep_nested_enum;

    public List<NestedMessage> rep_nested_message;

    public List<Integer> pack_int32;

    public List<Integer> pack_uint32;

    public List<Integer> pack_sint32;

    public List<Integer> pack_fixed32;

    public List<Integer> pack_sfixed32;

    public List<Long> pack_int64;

    public List<Long> pack_uint64;

    public List<Long> pack_sint64;

    public List<Long> pack_fixed64;

    public List<Long> pack_sfixed64;

    public List<Boolean> pack_bool;

    public List<Float> pack_float;

    public List<Double> pack_double;

    public List<NestedEnum> pack_nested_enum;

    public Integer default_int32;

    public Integer default_uint32;

    public Integer default_sint32;

    public Integer default_fixed32;

    public Integer default_sfixed32;

    public Long default_int64;

    public Long default_uint64;

    public Long default_sint64;

    public Long default_fixed64;

    public Long default_sfixed64;

    public Boolean default_bool;

    public Float default_float;

    public Double default_double;

    public String default_string;

    public ByteString default_bytes;

    public NestedEnum default_nested_enum;

    public Map<Integer, Integer> map_int32_int32;

    public Map<String, String> map_string_string;

    public Map<String, NestedMessage> map_string_message;

    public Map<String, NestedEnum> map_string_enum;

    public Integer ext_opt_int32;

    public Integer ext_opt_uint32;

    public Integer ext_opt_sint32;

    public Integer ext_opt_fixed32;

    public Integer ext_opt_sfixed32;

    public Long ext_opt_int64;

    public Long ext_opt_uint64;

    public Long ext_opt_sint64;

    public Long ext_opt_fixed64;

    public Long ext_opt_sfixed64;

    public Boolean ext_opt_bool;

    public Float ext_opt_float;

    public Double ext_opt_double;

    public String ext_opt_string;

    public ByteString ext_opt_bytes;

    public NestedEnum ext_opt_nested_enum;

    public NestedMessage ext_opt_nested_message;

    public List<Integer> ext_rep_int32;

    public List<Integer> ext_rep_uint32;

    public List<Integer> ext_rep_sint32;

    public List<Integer> ext_rep_fixed32;

    public List<Integer> ext_rep_sfixed32;

    public List<Long> ext_rep_int64;

    public List<Long> ext_rep_uint64;

    public List<Long> ext_rep_sint64;

    public List<Long> ext_rep_fixed64;

    public List<Long> ext_rep_sfixed64;

    public List<Boolean> ext_rep_bool;

    public List<Float> ext_rep_float;

    public List<Double> ext_rep_double;

    public List<String> ext_rep_string;

    public List<ByteString> ext_rep_bytes;

    public List<NestedEnum> ext_rep_nested_enum;

    public List<NestedMessage> ext_rep_nested_message;

    public List<Integer> ext_pack_int32;

    public List<Integer> ext_pack_uint32;

    public List<Integer> ext_pack_sint32;

    public List<Integer> ext_pack_fixed32;

    public List<Integer> ext_pack_sfixed32;

    public List<Long> ext_pack_int64;

    public List<Long> ext_pack_uint64;

    public List<Long> ext_pack_sint64;

    public List<Long> ext_pack_fixed64;

    public List<Long> ext_pack_sfixed64;

    public List<Boolean> ext_pack_bool;

    public List<Float> ext_pack_float;

    public List<Double> ext_pack_double;

    public List<NestedEnum> ext_pack_nested_enum;

    public Builder() {
      rep_int32 = Internal.newMutableList();
      rep_uint32 = Internal.newMutableList();
      rep_sint32 = Internal.newMutableList();
      rep_fixed32 = Internal.newMutableList();
      rep_sfixed32 = Internal.newMutableList();
      rep_int64 = Internal.newMutableList();
      rep_uint64 = Internal.newMutableList();
      rep_sint64 = Internal.newMutableList();
      rep_fixed64 = Internal.newMutableList();
      rep_sfixed64 = Internal.newMutableList();
      rep_bool = Internal.newMutableList();
      rep_float = Internal.newMutableList();
      rep_double = Internal.newMutableList();
      rep_string = Internal.newMutableList();
      rep_bytes = Internal.newMutableList();
      rep_nested_enum = Internal.newMutableList();
      rep_nested_message = Internal.newMutableList();
      pack_int32 = Internal.newMutableList();
      pack_uint32 = Internal.newMutableList();
      pack_sint32 = Internal.newMutableList();
      pack_fixed32 = Internal.newMutableList();
      pack_sfixed32 = Internal.newMutableList();
      pack_int64 = Internal.newMutableList();
      pack_uint64 = Internal.newMutableList();
      pack_sint64 = Internal.newMutableList();
      pack_fixed64 = Internal.newMutableList();
      pack_sfixed64 = Internal.newMutableList();
      pack_bool = Internal.newMutableList();
      pack_float = Internal.newMutableList();
      pack_double = Internal.newMutableList();
      pack_nested_enum = Internal.newMutableList();
      map_int32_int32 = Internal.newMutableMap();
      map_string_string = Internal.newMutableMap();
      map_string_message = Internal.newMutableMap();
      map_string_enum = Internal.newMutableMap();
      ext_rep_int32 = Internal.newMutableList();
      ext_rep_uint32 = Internal.newMutableList();
      ext_rep_sint32 = Internal.newMutableList();
      ext_rep_fixed32 = Internal.newMutableList();
      ext_rep_sfixed32 = Internal.newMutableList();
      ext_rep_int64 = Internal.newMutableList();
      ext_rep_uint64 = Internal.newMutableList();
      ext_rep_sint64 = Internal.newMutableList();
      ext_rep_fixed64 = Internal.newMutableList();
      ext_rep_sfixed64 = Internal.newMutableList();
      ext_rep_bool = Internal.newMutableList();
      ext_rep_float = Internal.newMutableList();
      ext_rep_double = Internal.newMutableList();
      ext_rep_string = Internal.newMutableList();
      ext_rep_bytes = Internal.newMutableList();
      ext_rep_nested_enum = Internal.newMutableList();
      ext_rep_nested_message = Internal.newMutableList();
      ext_pack_int32 = Internal.newMutableList();
      ext_pack_uint32 = Internal.newMutableList();
      ext_pack_sint32 = Internal.newMutableList();
      ext_pack_fixed32 = Internal.newMutableList();
      ext_pack_sfixed32 = Internal.newMutableList();
      ext_pack_int64 = Internal.newMutableList();
      ext_pack_uint64 = Internal.newMutableList();
      ext_pack_sint64 = Internal.newMutableList();
      ext_pack_fixed64 = Internal.newMutableList();
      ext_pack_sfixed64 = Internal.newMutableList();
      ext_pack_bool = Internal.newMutableList();
      ext_pack_float = Internal.newMutableList();
      ext_pack_double = Internal.newMutableList();
      ext_pack_nested_enum = Internal.newMutableList();
    }

    public Builder opt_int32(Integer opt_int32) {
      this.opt_int32 = opt_int32;
      return this;
    }

    public Builder opt_uint32(Integer opt_uint32) {
      this.opt_uint32 = opt_uint32;
      return this;
    }

    public Builder opt_sint32(Integer opt_sint32) {
      this.opt_sint32 = opt_sint32;
      return this;
    }

    public Builder opt_fixed32(Integer opt_fixed32) {
      this.opt_fixed32 = opt_fixed32;
      return this;
    }

    public Builder opt_sfixed32(Integer opt_sfixed32) {
      this.opt_sfixed32 = opt_sfixed32;
      return this;
    }

    public Builder opt_int64(Long opt_int64) {
      this.opt_int64 = opt_int64;
      return this;
    }

    public Builder opt_uint64(Long opt_uint64) {
      this.opt_uint64 = opt_uint64;
      return this;
    }

    public Builder opt_sint64(Long opt_sint64) {
      this.opt_sint64 = opt_sint64;
      return this;
    }

    public Builder opt_fixed64(Long opt_fixed64) {
      this.opt_fixed64 = opt_fixed64;
      return this;
    }

    public Builder opt_sfixed64(Long opt_sfixed64) {
      this.opt_sfixed64 = opt_sfixed64;
      return this;
    }

    public Builder opt_bool(Boolean opt_bool) {
      this.opt_bool = opt_bool;
      return this;
    }

    public Builder opt_float(Float opt_float) {
      this.opt_float = opt_float;
      return this;
    }

    public Builder opt_double(Double opt_double) {
      this.opt_double = opt_double;
      return this;
    }

    public Builder opt_string(String opt_string) {
      this.opt_string = opt_string;
      return this;
    }

    public Builder opt_bytes(ByteString opt_bytes) {
      this.opt_bytes = opt_bytes;
      return this;
    }

    public Builder opt_nested_enum(NestedEnum opt_nested_enum) {
      this.opt_nested_enum = opt_nested_enum;
      return this;
    }

    public Builder opt_nested_message(NestedMessage opt_nested_message) {
      this.opt_nested_message = opt_nested_message;
      return this;
    }

    public Builder req_int32(Integer req_int32) {
      this.req_int32 = req_int32;
      return this;
    }

    public Builder req_uint32(Integer req_uint32) {
      this.req_uint32 = req_uint32;
      return this;
    }

    public Builder req_sint32(Integer req_sint32) {
      this.req_sint32 = req_sint32;
      return this;
    }

    public Builder req_fixed32(Integer req_fixed32) {
      this.req_fixed32 = req_fixed32;
      return this;
    }

    public Builder req_sfixed32(Integer req_sfixed32) {
      this.req_sfixed32 = req_sfixed32;
      return this;
    }

    public Builder req_int64(Long req_int64) {
      this.req_int64 = req_int64;
      return this;
    }

    public Builder req_uint64(Long req_uint64) {
      this.req_uint64 = req_uint64;
      return this;
    }

    public Builder req_sint64(Long req_sint64) {
      this.req_sint64 = req_sint64;
      return this;
    }

    public Builder req_fixed64(Long req_fixed64) {
      this.req_fixed64 = req_fixed64;
      return this;
    }

    public Builder req_sfixed64(Long req_sfixed64) {
      this.req_sfixed64 = req_sfixed64;
      return this;
    }

    public Builder req_bool(Boolean req_bool) {
      this.req_bool = req_bool;
      return this;
    }

    public Builder req_float(Float req_float) {
      this.req_float = req_float;
      return this;
    }

    public Builder req_double(Double req_double) {
      this.req_double = req_double;
      return this;
    }

    public Builder req_string(String req_string) {
      this.req_string = req_string;
      return this;
    }

    public Builder req_bytes(ByteString req_bytes) {
      this.req_bytes = req_bytes;
      return this;
    }

    public Builder req_nested_enum(NestedEnum req_nested_enum) {
      this.req_nested_enum = req_nested_enum;
      return this;
    }

    public Builder req_nested_message(NestedMessage req_nested_message) {
      this.req_nested_message = req_nested_message;
      return this;
    }

    public Builder rep_int32(List<Integer> rep_int32) {
      Internal.checkElementsNotNull(rep_int32);
      this.rep_int32 = rep_int32;
      return this;
    }

    public Builder rep_uint32(List<Integer> rep_uint32) {
      Internal.checkElementsNotNull(rep_uint32);
      this.rep_uint32 = rep_uint32;
      return this;
    }

    public Builder rep_sint32(List<Integer> rep_sint32) {
      Internal.checkElementsNotNull(rep_sint32);
      this.rep_sint32 = rep_sint32;
      return this;
    }

    public Builder rep_fixed32(List<Integer> rep_fixed32) {
      Internal.checkElementsNotNull(rep_fixed32);
      this.rep_fixed32 = rep_fixed32;
      return this;
    }

    public Builder rep_sfixed32(List<Integer> rep_sfixed32) {
      Internal.checkElementsNotNull(rep_sfixed32);
      this.rep_sfixed32 = rep_sfixed32;
      return this;
    }

    public Builder rep_int64(List<Long> rep_int64) {
      Internal.checkElementsNotNull(rep_int64);
      this.rep_int64 = rep_int64;
      return this;
    }

    public Builder rep_uint64(List<Long> rep_uint64) {
      Internal.checkElementsNotNull(rep_uint64);
      this.rep_uint64 = rep_uint64;
      return this;
    }

    public Builder rep_sint64(List<Long> rep_sint64) {
      Internal.checkElementsNotNull(rep_sint64);
      this.rep_sint64 = rep_sint64;
      return this;
    }

    public Builder rep_fixed64(List<Long> rep_fixed64) {
      Internal.checkElementsNotNull(rep_fixed64);
      this.rep_fixed64 = rep_fixed64;
      return this;
    }

    public Builder rep_sfixed64(List<Long> rep_sfixed64) {
      Internal.checkElementsNotNull(rep_sfixed64);
      this.rep_sfixed64 = rep_sfixed64;
      return this;
    }

    public Builder rep_bool(List<Boolean> rep_bool) {
      Internal.checkElementsNotNull(rep_bool);
      this.rep_bool = rep_bool;
      return this;
    }

    public Builder rep_float(List<Float> rep_float) {
      Internal.checkElementsNotNull(rep_float);
      this.rep_float = rep_float;
      return this;
    }

    public Builder rep_double(List<Double> rep_double) {
      Internal.checkElementsNotNull(rep_double);
      this.rep_double = rep_double;
      return this;
    }

    public Builder rep_string(List<String> rep_string) {
      Internal.checkElementsNotNull(rep_string);
      this.rep_string = rep_string;
      return this;
    }

    public Builder rep_bytes(List<ByteString> rep_bytes) {
      Internal.checkElementsNotNull(rep_bytes);
      this.rep_bytes = rep_bytes;
      return this;
    }

    public Builder rep_nested_enum(List<NestedEnum> rep_nested_enum) {
      Internal.checkElementsNotNull(rep_nested_enum);
      this.rep_nested_enum = rep_nested_enum;
      return this;
    }

    public Builder rep_nested_message(List<NestedMessage> rep_nested_message) {
      Internal.checkElementsNotNull(rep_nested_message);
      this.rep_nested_message = rep_nested_message;
      return this;
    }

    public Builder pack_int32(List<Integer> pack_int32) {
      Internal.checkElementsNotNull(pack_int32);
      this.pack_int32 = pack_int32;
      return this;
    }

    public Builder pack_uint32(List<Integer> pack_uint32) {
      Internal.checkElementsNotNull(pack_uint32);
      this.pack_uint32 = pack_uint32;
      return this;
    }

    public Builder pack_sint32(List<Integer> pack_sint32) {
      Internal.checkElementsNotNull(pack_sint32);
      this.pack_sint32 = pack_sint32;
      return this;
    }

    public Builder pack_fixed32(List<Integer> pack_fixed32) {
      Internal.checkElementsNotNull(pack_fixed32);
      this.pack_fixed32 = pack_fixed32;
      return this;
    }

    public Builder pack_sfixed32(List<Integer> pack_sfixed32) {
      Internal.checkElementsNotNull(pack_sfixed32);
      this.pack_sfixed32 = pack_sfixed32;
      return this;
    }

    public Builder pack_int64(List<Long> pack_int64) {
      Internal.checkElementsNotNull(pack_int64);
      this.pack_int64 = pack_int64;
      return this;
    }

    public Builder pack_uint64(List<Long> pack_uint64) {
      Internal.checkElementsNotNull(pack_uint64);
      this.pack_uint64 = pack_uint64;
      return this;
    }

    public Builder pack_sint64(List<Long> pack_sint64) {
      Internal.checkElementsNotNull(pack_sint64);
      this.pack_sint64 = pack_sint64;
      return this;
    }

    public Builder pack_fixed64(List<Long> pack_fixed64) {
      Internal.checkElementsNotNull(pack_fixed64);
      this.pack_fixed64 = pack_fixed64;
      return this;
    }

    public Builder pack_sfixed64(List<Long> pack_sfixed64) {
      Internal.checkElementsNotNull(pack_sfixed64);
      this.pack_sfixed64 = pack_sfixed64;
      return this;
    }

    public Builder pack_bool(List<Boolean> pack_bool) {
      Internal.checkElementsNotNull(pack_bool);
      this.pack_bool = pack_bool;
      return this;
    }

    public Builder pack_float(List<Float> pack_float) {
      Internal.checkElementsNotNull(pack_float);
      this.pack_float = pack_float;
      return this;
    }

    public Builder pack_double(List<Double> pack_double) {
      Internal.checkElementsNotNull(pack_double);
      this.pack_double = pack_double;
      return this;
    }

    public Builder pack_nested_enum(List<NestedEnum> pack_nested_enum) {
      Internal.checkElementsNotNull(pack_nested_enum);
      this.pack_nested_enum = pack_nested_enum;
      return this;
    }

    public Builder default_int32(Integer default_int32) {
      this.default_int32 = default_int32;
      return this;
    }

    public Builder default_uint32(Integer default_uint32) {
      this.default_uint32 = default_uint32;
      return this;
    }

    public Builder default_sint32(Integer default_sint32) {
      this.default_sint32 = default_sint32;
      return this;
    }

    public Builder default_fixed32(Integer default_fixed32) {
      this.default_fixed32 = default_fixed32;
      return this;
    }

    public Builder default_sfixed32(Integer default_sfixed32) {
      this.default_sfixed32 = default_sfixed32;
      return this;
    }

    public Builder default_int64(Long default_int64) {
      this.default_int64 = default_int64;
      return this;
    }

    public Builder default_uint64(Long default_uint64) {
      this.default_uint64 = default_uint64;
      return this;
    }

    public Builder default_sint64(Long default_sint64) {
      this.default_sint64 = default_sint64;
      return this;
    }

    public Builder default_fixed64(Long default_fixed64) {
      this.default_fixed64 = default_fixed64;
      return this;
    }

    public Builder default_sfixed64(Long default_sfixed64) {
      this.default_sfixed64 = default_sfixed64;
      return this;
    }

    public Builder default_bool(Boolean default_bool) {
      this.default_bool = default_bool;
      return this;
    }

    public Builder default_float(Float default_float) {
      this.default_float = default_float;
      return this;
    }

    public Builder default_double(Double default_double) {
      this.default_double = default_double;
      return this;
    }

    /**
     * Note: protoc doesn't allow some characters of the default value.
     */
    public Builder default_string(String default_string) {
      this.default_string = default_string;
      return this;
    }

    public Builder default_bytes(ByteString default_bytes) {
      this.default_bytes = default_bytes;
      return this;
    }

    public Builder default_nested_enum(NestedEnum default_nested_enum) {
      this.default_nested_enum = default_nested_enum;
      return this;
    }

    public Builder map_int32_int32(Map<Integer, Integer> map_int32_int32) {
      Internal.checkElementsNotNull(map_int32_int32);
      this.map_int32_int32 = map_int32_int32;
      return this;
    }

    public Builder map_string_string(Map<String, String> map_string_string) {
      Internal.checkElementsNotNull(map_string_string);
      this.map_string_string = map_string_string;
      return this;
    }

    public Builder map_string_message(Map<String, NestedMessage> map_string_message) {
      Internal.checkElementsNotNull(map_string_message);
      this.map_string_message = map_string_message;
      return this;
    }

    public Builder map_string_enum(Map<String, NestedEnum> map_string_enum) {
      Internal.checkElementsNotNull(map_string_enum);
      this.map_string_enum = map_string_enum;
      return this;
    }

    public Builder ext_opt_int32(Integer ext_opt_int32) {
      this.ext_opt_int32 = ext_opt_int32;
      return this;
    }

    public Builder ext_opt_uint32(Integer ext_opt_uint32) {
      this.ext_opt_uint32 = ext_opt_uint32;
      return this;
    }

    public Builder ext_opt_sint32(Integer ext_opt_sint32) {
      this.ext_opt_sint32 = ext_opt_sint32;
      return this;
    }

    public Builder ext_opt_fixed32(Integer ext_opt_fixed32) {
      this.ext_opt_fixed32 = ext_opt_fixed32;
      return this;
    }

    public Builder ext_opt_sfixed32(Integer ext_opt_sfixed32) {
      this.ext_opt_sfixed32 = ext_opt_sfixed32;
      return this;
    }

    public Builder ext_opt_int64(Long ext_opt_int64) {
      this.ext_opt_int64 = ext_opt_int64;
      return this;
    }

    public Builder ext_opt_uint64(Long ext_opt_uint64) {
      this.ext_opt_uint64 = ext_opt_uint64;
      return this;
    }

    public Builder ext_opt_sint64(Long ext_opt_sint64) {
      this.ext_opt_sint64 = ext_opt_sint64;
      return this;
    }

    public Builder ext_opt_fixed64(Long ext_opt_fixed64) {
      this.ext_opt_fixed64 = ext_opt_fixed64;
      return this;
    }

    public Builder ext_opt_sfixed64(Long ext_opt_sfixed64) {
      this.ext_opt_sfixed64 = ext_opt_sfixed64;
      return this;
    }

    public Builder ext_opt_bool(Boolean ext_opt_bool) {
      this.ext_opt_bool = ext_opt_bool;
      return this;
    }

    public Builder ext_opt_float(Float ext_opt_float) {
      this.ext_opt_float = ext_opt_float;
      return this;
    }

    public Builder ext_opt_double(Double ext_opt_double) {
      this.ext_opt_double = ext_opt_double;
      return this;
    }

    public Builder ext_opt_string(String ext_opt_string) {
      this.ext_opt_string = ext_opt_string;
      return this;
    }

    public Builder ext_opt_bytes(ByteString ext_opt_bytes) {
      this.ext_opt_bytes = ext_opt_bytes;
      return this;
    }

    public Builder ext_opt_nested_enum(NestedEnum ext_opt_nested_enum) {
      this.ext_opt_nested_enum = ext_opt_nested_enum;
      return this;
    }

    public Builder ext_opt_nested_message(NestedMessage ext_opt_nested_message) {
      this.ext_opt_nested_message = ext_opt_nested_message;
      return this;
    }

    public Builder ext_rep_int32(List<Integer> ext_rep_int32) {
      Internal.checkElementsNotNull(ext_rep_int32);
      this.ext_rep_int32 = ext_rep_int32;
      return this;
    }

    public Builder ext_rep_uint32(List<Integer> ext_rep_uint32) {
      Internal.checkElementsNotNull(ext_rep_uint32);
      this.ext_rep_uint32 = ext_rep_uint32;
      return this;
    }

    public Builder ext_rep_sint32(List<Integer> ext_rep_sint32) {
      Internal.checkElementsNotNull(ext_rep_sint32);
      this.ext_rep_sint32 = ext_rep_sint32;
      return this;
    }

    public Builder ext_rep_fixed32(List<Integer> ext_rep_fixed32) {
      Internal.checkElementsNotNull(ext_rep_fixed32);
      this.ext_rep_fixed32 = ext_rep_fixed32;
      return this;
    }

    public Builder ext_rep_sfixed32(List<Integer> ext_rep_sfixed32) {
      Internal.checkElementsNotNull(ext_rep_sfixed32);
      this.ext_rep_sfixed32 = ext_rep_sfixed32;
      return this;
    }

    public Builder ext_rep_int64(List<Long> ext_rep_int64) {
      Internal.checkElementsNotNull(ext_rep_int64);
      this.ext_rep_int64 = ext_rep_int64;
      return this;
    }

    public Builder ext_rep_uint64(List<Long> ext_rep_uint64) {
      Internal.checkElementsNotNull(ext_rep_uint64);
      this.ext_rep_uint64 = ext_rep_uint64;
      return this;
    }

    public Builder ext_rep_sint64(List<Long> ext_rep_sint64) {
      Internal.checkElementsNotNull(ext_rep_sint64);
      this.ext_rep_sint64 = ext_rep_sint64;
      return this;
    }

    public Builder ext_rep_fixed64(List<Long> ext_rep_fixed64) {
      Internal.checkElementsNotNull(ext_rep_fixed64);
      this.ext_rep_fixed64 = ext_rep_fixed64;
      return this;
    }

    public Builder ext_rep_sfixed64(List<Long> ext_rep_sfixed64) {
      Internal.checkElementsNotNull(ext_rep_sfixed64);
      this.ext_rep_sfixed64 = ext_rep_sfixed64;
      return this;
    }

    public Builder ext_rep_bool(List<Boolean> ext_rep_bool) {
      Internal.checkElementsNotNull(ext_rep_bool);
      this.ext_rep_bool = ext_rep_bool;
      return this;
    }

    public Builder ext_rep_float(List<Float> ext_rep_float) {
      Internal.checkElementsNotNull(ext_rep_float);
      this.ext_rep_float = ext_rep_float;
      return this;
    }

    public Builder ext_rep_double(List<Double> ext_rep_double) {
      Internal.checkElementsNotNull(ext_rep_double);
      this.ext_rep_double = ext_rep_double;
      return this;
    }

    public Builder ext_rep_string(List<String> ext_rep_string) {
      Internal.checkElementsNotNull(ext_rep_string);
      this.ext_rep_string = ext_rep_string;
      return this;
    }

    public Builder ext_rep_bytes(List<ByteString> ext_rep_bytes) {
      Internal.checkElementsNotNull(ext_rep_bytes);
      this.ext_rep_bytes = ext_rep_bytes;
      return this;
    }

    public Builder ext_rep_nested_enum(List<NestedEnum> ext_rep_nested_enum) {
      Internal.checkElementsNotNull(ext_rep_nested_enum);
      this.ext_rep_nested_enum = ext_rep_nested_enum;
      return this;
    }

    public Builder ext_rep_nested_message(List<NestedMessage> ext_rep_nested_message) {
      Internal.checkElementsNotNull(ext_rep_nested_message);
      this.ext_rep_nested_message = ext_rep_nested_message;
      return this;
    }

    public Builder ext_pack_int32(List<Integer> ext_pack_int32) {
      Internal.checkElementsNotNull(ext_pack_int32);
      this.ext_pack_int32 = ext_pack_int32;
      return this;
    }

    public Builder ext_pack_uint32(List<Integer> ext_pack_uint32) {
      Internal.checkElementsNotNull(ext_pack_uint32);
      this.ext_pack_uint32 = ext_pack_uint32;
      return this;
    }

    public Builder ext_pack_sint32(List<Integer> ext_pack_sint32) {
      Internal.checkElementsNotNull(ext_pack_sint32);
      this.ext_pack_sint32 = ext_pack_sint32;
      return this;
    }

    public Builder ext_pack_fixed32(List<Integer> ext_pack_fixed32) {
      Internal.checkElementsNotNull(ext_pack_fixed32);
      this.ext_pack_fixed32 = ext_pack_fixed32;
      return this;
    }

    public Builder ext_pack_sfixed32(List<Integer> ext_pack_sfixed32) {
      Internal.checkElementsNotNull(ext_pack_sfixed32);
      this.ext_pack_sfixed32 = ext_pack_sfixed32;
      return this;
    }

    public Builder ext_pack_int64(List<Long> ext_pack_int64) {
      Internal.checkElementsNotNull(ext_pack_int64);
      this.ext_pack_int64 = ext_pack_int64;
      return this;
    }

    public Builder ext_pack_uint64(List<Long> ext_pack_uint64) {
      Internal.checkElementsNotNull(ext_pack_uint64);
      this.ext_pack_uint64 = ext_pack_uint64;
      return this;
    }

    public Builder ext_pack_sint64(List<Long> ext_pack_sint64) {
      Internal.checkElementsNotNull(ext_pack_sint64);
      this.ext_pack_sint64 = ext_pack_sint64;
      return this;
    }

    public Builder ext_pack_fixed64(List<Long> ext_pack_fixed64) {
      Internal.checkElementsNotNull(ext_pack_fixed64);
      this.ext_pack_fixed64 = ext_pack_fixed64;
      return this;
    }

    public Builder ext_pack_sfixed64(List<Long> ext_pack_sfixed64) {
      Internal.checkElementsNotNull(ext_pack_sfixed64);
      this.ext_pack_sfixed64 = ext_pack_sfixed64;
      return this;
    }

    public Builder ext_pack_bool(List<Boolean> ext_pack_bool) {
      Internal.checkElementsNotNull(ext_pack_bool);
      this.ext_pack_bool = ext_pack_bool;
      return this;
    }

    public Builder ext_pack_float(List<Float> ext_pack_float) {
      Internal.checkElementsNotNull(ext_pack_float);
      this.ext_pack_float = ext_pack_float;
      return this;
    }

    public Builder ext_pack_double(List<Double> ext_pack_double) {
      Internal.checkElementsNotNull(ext_pack_double);
      this.ext_pack_double = ext_pack_double;
      return this;
    }

    public Builder ext_pack_nested_enum(List<NestedEnum> ext_pack_nested_enum) {
      Internal.checkElementsNotNull(ext_pack_nested_enum);
      this.ext_pack_nested_enum = ext_pack_nested_enum;
      return this;
    }

    @Override
    public AllTypes build() {
      if (req_int32 == null
          || req_uint32 == null
          || req_sint32 == null
          || req_fixed32 == null
          || req_sfixed32 == null
          || req_int64 == null
          || req_uint64 == null
          || req_sint64 == null
          || req_fixed64 == null
          || req_sfixed64 == null
          || req_bool == null
          || req_float == null
          || req_double == null
          || req_string == null
          || req_bytes == null
          || req_nested_enum == null
          || req_nested_message == null) {
        throw Internal.missingRequiredFields(req_int32, "req_int32",
            req_uint32, "req_uint32",
            req_sint32, "req_sint32",
            req_fixed32, "req_fixed32",
            req_sfixed32, "req_sfixed32",
            req_int64, "req_int64",
            req_uint64, "req_uint64",
            req_sint64, "req_sint64",
            req_fixed64, "req_fixed64",
            req_sfixed64, "req_sfixed64",
            req_bool, "req_bool",
            req_float, "req_float",
            req_double, "req_double",
            req_string, "req_string",
            req_bytes, "req_bytes",
            req_nested_enum, "req_nested_enum",
            req_nested_message, "req_nested_message");
      }
      return new AllTypes(this, super.buildUnknownFields());
    }
  }

  public enum NestedEnum implements WireEnum {
    UNKNOWN(0),

    A(1);

    public static final ProtoAdapter<NestedEnum> ADAPTER = new ProtoAdapter_NestedEnum();

    private final int value;

    NestedEnum(int value) {
      this.value = value;
    }

    /**
     * Return the constant for {@code value} or null.
     */
    public static NestedEnum fromValue(int value) {
      switch (value) {
        case 0: return UNKNOWN;
        case 1: return A;
        default: return null;
      }
    }

    @Override
    public int getValue() {
      return value;
    }

    private static final class ProtoAdapter_NestedEnum extends EnumAdapter<NestedEnum> {
      ProtoAdapter_NestedEnum() {
        super(NestedEnum.class, Syntax.PROTO_2, NestedEnum.UNKNOWN);
      }

      @Override
      protected NestedEnum fromValue(int value) {
        return NestedEnum.fromValue(value);
      }
    }
  }

  public static final class NestedMessage extends Message<NestedMessage, NestedMessage.Builder> {
    public static final ProtoAdapter<NestedMessage> ADAPTER = new ProtoAdapter_NestedMessage();

    private static final long serialVersionUID = 0L;

    public static final Integer DEFAULT_A = 0;

    @WireField(
        tag = 1,
        adapter = "com.squareup.wire.ProtoAdapter#INT32"
    )
    public final Integer a;

    public NestedMessage(Integer a) {
      this(a, ByteString.EMPTY);
    }

    public NestedMessage(Integer a, ByteString unknownFields) {
      super(ADAPTER, unknownFields);
      this.a = a;
    }

    @Override
    public Builder newBuilder() {
      Builder builder = new Builder();
      builder.a = a;
      builder.addUnknownFields(unknownFields());
      return builder;
    }

    @Override
    public boolean equals(Object other) {
      if (other == this) return true;
      if (!(other instanceof NestedMessage)) return false;
      NestedMessage o = (NestedMessage) other;
      return unknownFields().equals(o.unknownFields())
          && Internal.equals(a, o.a);
    }

    @Override
    public int hashCode() {
      int result = super.hashCode;
      if (result == 0) {
        result = unknownFields().hashCode();
        result = result * 37 + (a != null ? a.hashCode() : 0);
        super.hashCode = result;
      }
      return result;
    }

    @Override
    public String toString() {
      StringBuilder builder = new StringBuilder();
      if (a != null) builder.append(", a=").append(a);
      return builder.replace(0, 2, "NestedMessage{").append('}').toString();
    }

    public static final class Builder extends Message.Builder<NestedMessage, Builder> {
      public Integer a;

      public Builder() {
      }

      public Builder a(Integer a) {
        this.a = a;
        return this;
      }

      @Override
      public NestedMessage build() {
        return new NestedMessage(a, super.buildUnknownFields());
      }
    }

    private static final class ProtoAdapter_NestedMessage extends ProtoAdapter<NestedMessage> {
      public ProtoAdapter_NestedMessage() {
        super(FieldEncoding.LENGTH_DELIMITED, NestedMessage.class, "type.googleapis.com/squareup.protos.alltypes.AllTypes.NestedMessage", Syntax.PROTO_2, null, "all_types.proto");
      }

      @Override
      public int encodedSize(NestedMessage value) {
        int result = 0;
        result += ProtoAdapter.INT32.encodedSizeWithTag(1, value.a);
        result += value.unknownFields().size();
        return result;
      }

      @Override
      public void encode(ProtoWriter writer, NestedMessage value) throws IOException {
        ProtoAdapter.INT32.encodeWithTag(writer, 1, value.a);
        writer.writeBytes(value.unknownFields());
      }

      @Override
      public void encode(ReverseProtoWriter writer, NestedMessage value) throws IOException {
        writer.writeBytes(value.unknownFields());
        ProtoAdapter.INT32.encodeWithTag(writer, 1, value.a);
      }

      @Override
      public NestedMessage decode(ProtoReader reader) throws IOException {
        Builder builder = new Builder();
        long token = reader.beginMessage();
        for (int tag; (tag = reader.nextTag()) != -1;) {
          switch (tag) {
            case 1: builder.a(ProtoAdapter.INT32.decode(reader)); break;
            default: {
              reader.readUnknownField(tag);
            }
          }
        }
        builder.addUnknownFields(reader.endMessageAndGetUnknownFields(token));
        return builder.build();
      }

      @Override
      public NestedMessage redact(NestedMessage value) {
        Builder builder = value.newBuilder();
        builder.clearUnknownFields();
        return builder.build();
      }
    }
  }

  private static final class ProtoAdapter_AllTypes extends ProtoAdapter<AllTypes> {
    private ProtoAdapter<Map<Integer, Integer>> map_int32_int32;

    private ProtoAdapter<Map<String, String>> map_string_string;

    private ProtoAdapter<Map<String, NestedMessage>> map_string_message;

    private ProtoAdapter<Map<String, NestedEnum>> map_string_enum;

    public ProtoAdapter_AllTypes() {
      super(FieldEncoding.LENGTH_DELIMITED, AllTypes.class, "type.googleapis.com/squareup.protos.alltypes.AllTypes", Syntax.PROTO_2, null, "all_types.proto");
    }

    @Override
    public int encodedSize(AllTypes value) {
      int result = 0;
      result += ProtoAdapter.INT32.encodedSizeWithTag(1, value.opt_int32);
      result += ProtoAdapter.UINT32.encodedSizeWithTag(2, value.opt_uint32);
      result += ProtoAdapter.SINT32.encodedSizeWithTag(3, value.opt_sint32);
      result += ProtoAdapter.FIXED32.encodedSizeWithTag(4, value.opt_fixed32);
      result += ProtoAdapter.SFIXED32.encodedSizeWithTag(5, value.opt_sfixed32);
      result += ProtoAdapter.INT64.encodedSizeWithTag(6, value.opt_int64);
      result += ProtoAdapter.UINT64.encodedSizeWithTag(7, value.opt_uint64);
      result += ProtoAdapter.SINT64.encodedSizeWithTag(8, value.opt_sint64);
      result += ProtoAdapter.FIXED64.encodedSizeWithTag(9, value.opt_fixed64);
      result += ProtoAdapter.SFIXED64.encodedSizeWithTag(10, value.opt_sfixed64);
      result += ProtoAdapter.BOOL.encodedSizeWithTag(11, value.opt_bool);
      result += ProtoAdapter.FLOAT.encodedSizeWithTag(12, value.opt_float);
      result += ProtoAdapter.DOUBLE.encodedSizeWithTag(13, value.opt_double);
      result += ProtoAdapter.STRING.encodedSizeWithTag(14, value.opt_string);
      result += ProtoAdapter.BYTES.encodedSizeWithTag(15, value.opt_bytes);
      result += NestedEnum.ADAPTER.encodedSizeWithTag(16, value.opt_nested_enum);
      result += NestedMessage.ADAPTER.encodedSizeWithTag(17, value.opt_nested_message);
      result += ProtoAdapter.INT32.encodedSizeWithTag(101, value.req_int32);
      result += ProtoAdapter.UINT32.encodedSizeWithTag(102, value.req_uint32);
      result += ProtoAdapter.SINT32.encodedSizeWithTag(103, value.req_sint32);
      result += ProtoAdapter.FIXED32.encodedSizeWithTag(104, value.req_fixed32);
      result += ProtoAdapter.SFIXED32.encodedSizeWithTag(105, value.req_sfixed32);
      result += ProtoAdapter.INT64.encodedSizeWithTag(106, value.req_int64);
      result += ProtoAdapter.UINT64.encodedSizeWithTag(107, value.req_uint64);
      result += ProtoAdapter.SINT64.encodedSizeWithTag(108, value.req_sint64);
      result += ProtoAdapter.FIXED64.encodedSizeWithTag(109, value.req_fixed64);
      result += ProtoAdapter.SFIXED64.encodedSizeWithTag(110, value.req_sfixed64);
      result += ProtoAdapter.BOOL.encodedSizeWithTag(111, value.req_bool);
      result += ProtoAdapter.FLOAT.encodedSizeWithTag(112, value.req_float);
      result += ProtoAdapter.DOUBLE.encodedSizeWithTag(113, value.req_double);
      result += ProtoAdapter.STRING.encodedSizeWithTag(114, value.req_string);
      result += ProtoAdapter.BYTES.encodedSizeWithTag(115, value.req_bytes);
      result += NestedEnum.ADAPTER.encodedSizeWithTag(116, value.req_nested_enum);
      result += NestedMessage.ADAPTER.encodedSizeWithTag(117, value.req_nested_message);
      result += ProtoAdapter.INT32.asRepeated().encodedSizeWithTag(201, value.rep_int32);
      result += ProtoAdapter.UINT32.asRepeated().encodedSizeWithTag(202, value.rep_uint32);
      result += ProtoAdapter.SINT32.asRepeated().encodedSizeWithTag(203, value.rep_sint32);
      result += ProtoAdapter.FIXED32.asRepeated().encodedSizeWithTag(204, value.rep_fixed32);
      result += ProtoAdapter.SFIXED32.asRepeated().encodedSizeWithTag(205, value.rep_sfixed32);
      result += ProtoAdapter.INT64.asRepeated().encodedSizeWithTag(206, value.rep_int64);
      result += ProtoAdapter.UINT64.asRepeated().encodedSizeWithTag(207, value.rep_uint64);
      result += ProtoAdapter.SINT64.asRepeated().encodedSizeWithTag(208, value.rep_sint64);
      result += ProtoAdapter.FIXED64.asRepeated().encodedSizeWithTag(209, value.rep_fixed64);
      result += ProtoAdapter.SFIXED64.asRepeated().encodedSizeWithTag(210, value.rep_sfixed64);
      result += ProtoAdapter.BOOL.asRepeated().encodedSizeWithTag(211, value.rep_bool);
      result += ProtoAdapter.FLOAT.asRepeated().encodedSizeWithTag(212, value.rep_float);
      result += ProtoAdapter.DOUBLE.asRepeated().encodedSizeWithTag(213, value.rep_double);
      result += ProtoAdapter.STRING.asRepeated().encodedSizeWithTag(214, value.rep_string);
      result += ProtoAdapter.BYTES.asRepeated().encodedSizeWithTag(215, value.rep_bytes);
      result += NestedEnum.ADAPTER.asRepeated().encodedSizeWithTag(216, value.rep_nested_enum);
      result += NestedMessage.ADAPTER.asRepeated().encodedSizeWithTag(217, value.rep_nested_message);
      result += ProtoAdapter.INT32.asPacked().encodedSizeWithTag(301, value.pack_int32);
      result += ProtoAdapter.UINT32.asPacked().encodedSizeWithTag(302, value.pack_uint32);
      result += ProtoAdapter.SINT32.asPacked().encodedSizeWithTag(303, value.pack_sint32);
      result += ProtoAdapter.FIXED32.asPacked().encodedSizeWithTag(304, value.pack_fixed32);
      result += ProtoAdapter.SFIXED32.asPacked().encodedSizeWithTag(305, value.pack_sfixed32);
      result += ProtoAdapter.INT64.asPacked().encodedSizeWithTag(306, value.pack_int64);
      result += ProtoAdapter.UINT64.asPacked().encodedSizeWithTag(307, value.pack_uint64);
      result += ProtoAdapter.SINT64.asPacked().encodedSizeWithTag(308, value.pack_sint64);
      result += ProtoAdapter.FIXED64.asPacked().encodedSizeWithTag(309, value.pack_fixed64);
      result += ProtoAdapter.SFIXED64.asPacked().encodedSizeWithTag(310, value.pack_sfixed64);
      result += ProtoAdapter.BOOL.asPacked().encodedSizeWithTag(311, value.pack_bool);
      result += ProtoAdapter.FLOAT.asPacked().encodedSizeWithTag(312, value.pack_float);
      result += ProtoAdapter.DOUBLE.asPacked().encodedSizeWithTag(313, value.pack_double);
      result += NestedEnum.ADAPTER.asPacked().encodedSizeWithTag(316, value.pack_nested_enum);
      result += ProtoAdapter.INT32.encodedSizeWithTag(401, value.default_int32);
      result += ProtoAdapter.UINT32.encodedSizeWithTag(402, value.default_uint32);
      result += ProtoAdapter.SINT32.encodedSizeWithTag(403, value.default_sint32);
      result += ProtoAdapter.FIXED32.encodedSizeWithTag(404, value.default_fixed32);
      result += ProtoAdapter.SFIXED32.encodedSizeWithTag(405, value.default_sfixed32);
      result += ProtoAdapter.INT64.encodedSizeWithTag(406, value.default_int64);
      result += ProtoAdapter.UINT64.encodedSizeWithTag(407, value.default_uint64);
      result += ProtoAdapter.SINT64.encodedSizeWithTag(408, value.default_sint64);
      result += ProtoAdapter.FIXED64.encodedSizeWithTag(409, value.default_fixed64);
      result += ProtoAdapter.SFIXED64.encodedSizeWithTag(410, value.default_sfixed64);
      result += ProtoAdapter.BOOL.encodedSizeWithTag(411, value.default_bool);
      result += ProtoAdapter.FLOAT.encodedSizeWithTag(412, value.default_float);
      result += ProtoAdapter.DOUBLE.encodedSizeWithTag(413, value.default_double);
      result += ProtoAdapter.STRING.encodedSizeWithTag(414, value.default_string);
      result += ProtoAdapter.BYTES.encodedSizeWithTag(415, value.default_bytes);
      result += NestedEnum.ADAPTER.encodedSizeWithTag(416, value.default_nested_enum);
      result += map_int32_int32Adapter().encodedSizeWithTag(501, value.map_int32_int32);
      result += map_string_stringAdapter().encodedSizeWithTag(502, value.map_string_string);
      result += map_string_messageAdapter().encodedSizeWithTag(503, value.map_string_message);
      result += map_string_enumAdapter().encodedSizeWithTag(504, value.map_string_enum);
      result += ProtoAdapter.INT32.encodedSizeWithTag(1001, value.ext_opt_int32);
      result += ProtoAdapter.UINT32.encodedSizeWithTag(1002, value.ext_opt_uint32);
      result += ProtoAdapter.SINT32.encodedSizeWithTag(1003, value.ext_opt_sint32);
      result += ProtoAdapter.FIXED32.encodedSizeWithTag(1004, value.ext_opt_fixed32);
      result += ProtoAdapter.SFIXED32.encodedSizeWithTag(1005, value.ext_opt_sfixed32);
      result += ProtoAdapter.INT64.encodedSizeWithTag(1006, value.ext_opt_int64);
      result += ProtoAdapter.UINT64.encodedSizeWithTag(1007, value.ext_opt_uint64);
      result += ProtoAdapter.SINT64.encodedSizeWithTag(1008, value.ext_opt_sint64);
      result += ProtoAdapter.FIXED64.encodedSizeWithTag(1009, value.ext_opt_fixed64);
      result += ProtoAdapter.SFIXED64.encodedSizeWithTag(1010, value.ext_opt_sfixed64);
      result += ProtoAdapter.BOOL.encodedSizeWithTag(1011, value.ext_opt_bool);
      result += ProtoAdapter.FLOAT.encodedSizeWithTag(1012, value.ext_opt_float);
      result += ProtoAdapter.DOUBLE.encodedSizeWithTag(1013, value.ext_opt_double);
      result += ProtoAdapter.STRING.encodedSizeWithTag(1014, value.ext_opt_string);
      result += ProtoAdapter.BYTES.encodedSizeWithTag(1015, value.ext_opt_bytes);
      result += NestedEnum.ADAPTER.encodedSizeWithTag(1016, value.ext_opt_nested_enum);
      result += NestedMessage.ADAPTER.encodedSizeWithTag(1017, value.ext_opt_nested_message);
      result += ProtoAdapter.INT32.asRepeated().encodedSizeWithTag(1101, value.ext_rep_int32);
      result += ProtoAdapter.UINT32.asRepeated().encodedSizeWithTag(1102, value.ext_rep_uint32);
      result += ProtoAdapter.SINT32.asRepeated().encodedSizeWithTag(1103, value.ext_rep_sint32);
      result += ProtoAdapter.FIXED32.asRepeated().encodedSizeWithTag(1104, value.ext_rep_fixed32);
      result += ProtoAdapter.SFIXED32.asRepeated().encodedSizeWithTag(1105, value.ext_rep_sfixed32);
      result += ProtoAdapter.INT64.asRepeated().encodedSizeWithTag(1106, value.ext_rep_int64);
      result += ProtoAdapter.UINT64.asRepeated().encodedSizeWithTag(1107, value.ext_rep_uint64);
      result += ProtoAdapter.SINT64.asRepeated().encodedSizeWithTag(1108, value.ext_rep_sint64);
      result += ProtoAdapter.FIXED64.asRepeated().encodedSizeWithTag(1109, value.ext_rep_fixed64);
      result += ProtoAdapter.SFIXED64.asRepeated().encodedSizeWithTag(1110, value.ext_rep_sfixed64);
      result += ProtoAdapter.BOOL.asRepeated().encodedSizeWithTag(1111, value.ext_rep_bool);
      result += ProtoAdapter.FLOAT.asRepeated().encodedSizeWithTag(1112, value.ext_rep_float);
      result += ProtoAdapter.DOUBLE.asRepeated().encodedSizeWithTag(1113, value.ext_rep_double);
      result += ProtoAdapter.STRING.asRepeated().encodedSizeWithTag(1114, value.ext_rep_string);
      result += ProtoAdapter.BYTES.asRepeated().encodedSizeWithTag(1115, value.ext_rep_bytes);
      result += NestedEnum.ADAPTER.asRepeated().encodedSizeWithTag(1116, value.ext_rep_nested_enum);
      result += NestedMessage.ADAPTER.asRepeated().encodedSizeWithTag(1117, value.ext_rep_nested_message);
      result += ProtoAdapter.INT32.asPacked().encodedSizeWithTag(1201, value.ext_pack_int32);
      result += ProtoAdapter.UINT32.asPacked().encodedSizeWithTag(1202, value.ext_pack_uint32);
      result += ProtoAdapter.SINT32.asPacked().encodedSizeWithTag(1203, value.ext_pack_sint32);
      result += ProtoAdapter.FIXED32.asPacked().encodedSizeWithTag(1204, value.ext_pack_fixed32);
      result += ProtoAdapter.SFIXED32.asPacked().encodedSizeWithTag(1205, value.ext_pack_sfixed32);
      result += ProtoAdapter.INT64.asPacked().encodedSizeWithTag(1206, value.ext_pack_int64);
      result += ProtoAdapter.UINT64.asPacked().encodedSizeWithTag(1207, value.ext_pack_uint64);
      result += ProtoAdapter.SINT64.asPacked().encodedSizeWithTag(1208, value.ext_pack_sint64);
      result += ProtoAdapter.FIXED64.asPacked().encodedSizeWithTag(1209, value.ext_pack_fixed64);
      result += ProtoAdapter.SFIXED64.asPacked().encodedSizeWithTag(1210, value.ext_pack_sfixed64);
      result += ProtoAdapter.BOOL.asPacked().encodedSizeWithTag(1211, value.ext_pack_bool);
      result += ProtoAdapter.FLOAT.asPacked().encodedSizeWithTag(1212, value.ext_pack_float);
      result += ProtoAdapter.DOUBLE.asPacked().encodedSizeWithTag(1213, value.ext_pack_double);
      result += NestedEnum.ADAPTER.asPacked().encodedSizeWithTag(1216, value.ext_pack_nested_enum);
      result += value.unknownFields().size();
      return result;
    }

    @Override
    public void encode(ProtoWriter writer, AllTypes value) throws IOException {
      ProtoAdapter.INT32.encodeWithTag(writer, 1, value.opt_int32);
      ProtoAdapter.UINT32.encodeWithTag(writer, 2, value.opt_uint32);
      ProtoAdapter.SINT32.encodeWithTag(writer, 3, value.opt_sint32);
      ProtoAdapter.FIXED32.encodeWithTag(writer, 4, value.opt_fixed32);
      ProtoAdapter.SFIXED32.encodeWithTag(writer, 5, value.opt_sfixed32);
      ProtoAdapter.INT64.encodeWithTag(writer, 6, value.opt_int64);
      ProtoAdapter.UINT64.encodeWithTag(writer, 7, value.opt_uint64);
      ProtoAdapter.SINT64.encodeWithTag(writer, 8, value.opt_sint64);
      ProtoAdapter.FIXED64.encodeWithTag(writer, 9, value.opt_fixed64);
      ProtoAdapter.SFIXED64.encodeWithTag(writer, 10, value.opt_sfixed64);
      ProtoAdapter.BOOL.encodeWithTag(writer, 11, value.opt_bool);
      ProtoAdapter.FLOAT.encodeWithTag(writer, 12, value.opt_float);
      ProtoAdapter.DOUBLE.encodeWithTag(writer, 13, value.opt_double);
      ProtoAdapter.STRING.encodeWithTag(writer, 14, value.opt_string);
      ProtoAdapter.BYTES.encodeWithTag(writer, 15, value.opt_bytes);
      NestedEnum.ADAPTER.encodeWithTag(writer, 16, value.opt_nested_enum);
      NestedMessage.ADAPTER.encodeWithTag(writer, 17, value.opt_nested_message);
      ProtoAdapter.INT32.encodeWithTag(writer, 101, value.req_int32);
      ProtoAdapter.UINT32.encodeWithTag(writer, 102, value.req_uint32);
      ProtoAdapter.SINT32.encodeWithTag(writer, 103, value.req_sint32);
      ProtoAdapter.FIXED32.encodeWithTag(writer, 104, value.req_fixed32);
      ProtoAdapter.SFIXED32.encodeWithTag(writer, 105, value.req_sfixed32);
      ProtoAdapter.INT64.encodeWithTag(writer, 106, value.req_int64);
      ProtoAdapter.UINT64.encodeWithTag(writer, 107, value.req_uint64);
      ProtoAdapter.SINT64.encodeWithTag(writer, 108, value.req_sint64);
      ProtoAdapter.FIXED64.encodeWithTag(writer, 109, value.req_fixed64);
      ProtoAdapter.SFIXED64.encodeWithTag(writer, 110, value.req_sfixed64);
      ProtoAdapter.BOOL.encodeWithTag(writer, 111, value.req_bool);
      ProtoAdapter.FLOAT.encodeWithTag(writer, 112, value.req_float);
      ProtoAdapter.DOUBLE.encodeWithTag(writer, 113, value.req_double);
      ProtoAdapter.STRING.encodeWithTag(writer, 114, value.req_string);
      ProtoAdapter.BYTES.encodeWithTag(writer, 115, value.req_bytes);
      NestedEnum.ADAPTER.encodeWithTag(writer, 116, value.req_nested_enum);
      NestedMessage.ADAPTER.encodeWithTag(writer, 117, value.req_nested_message);
      ProtoAdapter.INT32.asRepeated().encodeWithTag(writer, 201, value.rep_int32);
      ProtoAdapter.UINT32.asRepeated().encodeWithTag(writer, 202, value.rep_uint32);
      ProtoAdapter.SINT32.asRepeated().encodeWithTag(writer, 203, value.rep_sint32);
      ProtoAdapter.FIXED32.asRepeated().encodeWithTag(writer, 204, value.rep_fixed32);
      ProtoAdapter.SFIXED32.asRepeated().encodeWithTag(writer, 205, value.rep_sfixed32);
      ProtoAdapter.INT64.asRepeated().encodeWithTag(writer, 206, value.rep_int64);
      ProtoAdapter.UINT64.asRepeated().encodeWithTag(writer, 207, value.rep_uint64);
      ProtoAdapter.SINT64.asRepeated().encodeWithTag(writer, 208, value.rep_sint64);
      ProtoAdapter.FIXED64.asRepeated().encodeWithTag(writer, 209, value.rep_fixed64);
      ProtoAdapter.SFIXED64.asRepeated().encodeWithTag(writer, 210, value.rep_sfixed64);
      ProtoAdapter.BOOL.asRepeated().encodeWithTag(writer, 211, value.rep_bool);
      ProtoAdapter.FLOAT.asRepeated().encodeWithTag(writer, 212, value.rep_float);
      ProtoAdapter.DOUBLE.asRepeated().encodeWithTag(writer, 213, value.rep_double);
      ProtoAdapter.STRING.asRepeated().encodeWithTag(writer, 214, value.rep_string);
      ProtoAdapter.BYTES.asRepeated().encodeWithTag(writer, 215, value.rep_bytes);
      NestedEnum.ADAPTER.asRepeated().encodeWithTag(writer, 216, value.rep_nested_enum);
      NestedMessage.ADAPTER.asRepeated().encodeWithTag(writer, 217, value.rep_nested_message);
      ProtoAdapter.INT32.asPacked().encodeWithTag(writer, 301, value.pack_int32);
      ProtoAdapter.UINT32.asPacked().encodeWithTag(writer, 302, value.pack_uint32);
      ProtoAdapter.SINT32.asPacked().encodeWithTag(writer, 303, value.pack_sint32);
      ProtoAdapter.FIXED32.asPacked().encodeWithTag(writer, 304, value.pack_fixed32);
      ProtoAdapter.SFIXED32.asPacked().encodeWithTag(writer, 305, value.pack_sfixed32);
      ProtoAdapter.INT64.asPacked().encodeWithTag(writer, 306, value.pack_int64);
      ProtoAdapter.UINT64.asPacked().encodeWithTag(writer, 307, value.pack_uint64);
      ProtoAdapter.SINT64.asPacked().encodeWithTag(writer, 308, value.pack_sint64);
      ProtoAdapter.FIXED64.asPacked().encodeWithTag(writer, 309, value.pack_fixed64);
      ProtoAdapter.SFIXED64.asPacked().encodeWithTag(writer, 310, value.pack_sfixed64);
      ProtoAdapter.BOOL.asPacked().encodeWithTag(writer, 311, value.pack_bool);
      ProtoAdapter.FLOAT.asPacked().encodeWithTag(writer, 312, value.pack_float);
      ProtoAdapter.DOUBLE.asPacked().encodeWithTag(writer, 313, value.pack_double);
      NestedEnum.ADAPTER.asPacked().encodeWithTag(writer, 316, value.pack_nested_enum);
      ProtoAdapter.INT32.encodeWithTag(writer, 401, value.default_int32);
      ProtoAdapter.UINT32.encodeWithTag(writer, 402, value.default_uint32);
      ProtoAdapter.SINT32.encodeWithTag(writer, 403, value.default_sint32);
      ProtoAdapter.FIXED32.encodeWithTag(writer, 404, value.default_fixed32);
      ProtoAdapter.SFIXED32.encodeWithTag(writer, 405, value.default_sfixed32);
      ProtoAdapter.INT64.encodeWithTag(writer, 406, value.default_int64);
      ProtoAdapter.UINT64.encodeWithTag(writer, 407, value.default_uint64);
      ProtoAdapter.SINT64.encodeWithTag(writer, 408, value.default_sint64);
      ProtoAdapter.FIXED64.encodeWithTag(writer, 409, value.default_fixed64);
      ProtoAdapter.SFIXED64.encodeWithTag(writer, 410, value.default_sfixed64);
      ProtoAdapter.BOOL.encodeWithTag(writer, 411, value.default_bool);
      ProtoAdapter.FLOAT.encodeWithTag(writer, 412, value.default_float);
      ProtoAdapter.DOUBLE.encodeWithTag(writer, 413, value.default_double);
      ProtoAdapter.STRING.encodeWithTag(writer, 414, value.default_string);
      ProtoAdapter.BYTES.encodeWithTag(writer, 415, value.default_bytes);
      NestedEnum.ADAPTER.encodeWithTag(writer, 416, value.default_nested_enum);
      map_int32_int32Adapter().encodeWithTag(writer, 501, value.map_int32_int32);
      map_string_stringAdapter().encodeWithTag(writer, 502, value.map_string_string);
      map_string_messageAdapter().encodeWithTag(writer, 503, value.map_string_message);
      map_string_enumAdapter().encodeWithTag(writer, 504, value.map_string_enum);
      ProtoAdapter.INT32.encodeWithTag(writer, 1001, value.ext_opt_int32);
      ProtoAdapter.UINT32.encodeWithTag(writer, 1002, value.ext_opt_uint32);
      ProtoAdapter.SINT32.encodeWithTag(writer, 1003, value.ext_opt_sint32);
      ProtoAdapter.FIXED32.encodeWithTag(writer, 1004, value.ext_opt_fixed32);
      ProtoAdapter.SFIXED32.encodeWithTag(writer, 1005, value.ext_opt_sfixed32);
      ProtoAdapter.INT64.encodeWithTag(writer, 1006, value.ext_opt_int64);
      ProtoAdapter.UINT64.encodeWithTag(writer, 1007, value.ext_opt_uint64);
      ProtoAdapter.SINT64.encodeWithTag(writer, 1008, value.ext_opt_sint64);
      ProtoAdapter.FIXED64.encodeWithTag(writer, 1009, value.ext_opt_fixed64);
      ProtoAdapter.SFIXED64.encodeWithTag(writer, 1010, value.ext_opt_sfixed64);
      ProtoAdapter.BOOL.encodeWithTag(writer, 1011, value.ext_opt_bool);
      ProtoAdapter.FLOAT.encodeWithTag(writer, 1012, value.ext_opt_float);
      ProtoAdapter.DOUBLE.encodeWithTag(writer, 1013, value.ext_opt_double);
      ProtoAdapter.STRING.encodeWithTag(writer, 1014, value.ext_opt_string);
      ProtoAdapter.BYTES.encodeWithTag(writer, 1015, value.ext_opt_bytes);
      NestedEnum.ADAPTER.encodeWithTag(writer, 1016, value.ext_opt_nested_enum);
      NestedMessage.ADAPTER.encodeWithTag(writer, 1017, value.ext_opt_nested_message);
      ProtoAdapter.INT32.asRepeated().encodeWithTag(writer, 1101, value.ext_rep_int32);
      ProtoAdapter.UINT32.asRepeated().encodeWithTag(writer, 1102, value.ext_rep_uint32);
      ProtoAdapter.SINT32.asRepeated().encodeWithTag(writer, 1103, value.ext_rep_sint32);
      ProtoAdapter.FIXED32.asRepeated().encodeWithTag(writer, 1104, value.ext_rep_fixed32);
      ProtoAdapter.SFIXED32.asRepeated().encodeWithTag(writer, 1105, value.ext_rep_sfixed32);
      ProtoAdapter.INT64.asRepeated().encodeWithTag(writer, 1106, value.ext_rep_int64);
      ProtoAdapter.UINT64.asRepeated().encodeWithTag(writer, 1107, value.ext_rep_uint64);
      ProtoAdapter.SINT64.asRepeated().encodeWithTag(writer, 1108, value.ext_rep_sint64);
      ProtoAdapter.FIXED64.asRepeated().encodeWithTag(writer, 1109, value.ext_rep_fixed64);
      ProtoAdapter.SFIXED64.asRepeated().encodeWithTag(writer, 1110, value.ext_rep_sfixed64);
      ProtoAdapter.BOOL.asRepeated().encodeWithTag(writer, 1111, value.ext_rep_bool);
      ProtoAdapter.FLOAT.asRepeated().encodeWithTag(writer, 1112, value.ext_rep_float);
      ProtoAdapter.DOUBLE.asRepeated().encodeWithTag(writer, 1113, value.ext_rep_double);
      ProtoAdapter.STRING.asRepeated().encodeWithTag(writer, 1114, value.ext_rep_string);
      ProtoAdapter.BYTES.asRepeated().encodeWithTag(writer, 1115, value.ext_rep_bytes);
      NestedEnum.ADAPTER.asRepeated().encodeWithTag(writer, 1116, value.ext_rep_nested_enum);
      NestedMessage.ADAPTER.asRepeated().encodeWithTag(writer, 1117, value.ext_rep_nested_message);
      ProtoAdapter.INT32.asPacked().encodeWithTag(writer, 1201, value.ext_pack_int32);
      ProtoAdapter.UINT32.asPacked().encodeWithTag(writer, 1202, value.ext_pack_uint32);
      ProtoAdapter.SINT32.asPacked().encodeWithTag(writer, 1203, value.ext_pack_sint32);
      ProtoAdapter.FIXED32.asPacked().encodeWithTag(writer, 1204, value.ext_pack_fixed32);
      ProtoAdapter.SFIXED32.asPacked().encodeWithTag(writer, 1205, value.ext_pack_sfixed32);
      ProtoAdapter.INT64.asPacked().encodeWithTag(writer, 1206, value.ext_pack_int64);
      ProtoAdapter.UINT64.asPacked().encodeWithTag(writer, 1207, value.ext_pack_uint64);
      ProtoAdapter.SINT64.asPacked().encodeWithTag(writer, 1208, value.ext_pack_sint64);
      ProtoAdapter.FIXED64.asPacked().encodeWithTag(writer, 1209, value.ext_pack_fixed64);
      ProtoAdapter.SFIXED64.asPacked().encodeWithTag(writer, 1210, value.ext_pack_sfixed64);
      ProtoAdapter.BOOL.asPacked().encodeWithTag(writer, 1211, value.ext_pack_bool);
      ProtoAdapter.FLOAT.asPacked().encodeWithTag(writer, 1212, value.ext_pack_float);
      ProtoAdapter.DOUBLE.asPacked().encodeWithTag(writer, 1213, value.ext_pack_double);
      NestedEnum.ADAPTER.asPacked().encodeWithTag(writer, 1216, value.ext_pack_nested_enum);
      writer.writeBytes(value.unknownFields());
    }

    @Override
    public void encode(ReverseProtoWriter writer, AllTypes value) throws IOException {
      writer.writeBytes(value.unknownFields());
      NestedEnum.ADAPTER.asPacked().encodeWithTag(writer, 1216, value.ext_pack_nested_enum);
      ProtoAdapter.DOUBLE.asPacked().encodeWithTag(writer, 1213, value.ext_pack_double);
      ProtoAdapter.FLOAT.asPacked().encodeWithTag(writer, 1212, value.ext_pack_float);
      ProtoAdapter.BOOL.asPacked().encodeWithTag(writer, 1211, value.ext_pack_bool);
      ProtoAdapter.SFIXED64.asPacked().encodeWithTag(writer, 1210, value.ext_pack_sfixed64);
      ProtoAdapter.FIXED64.asPacked().encodeWithTag(writer, 1209, value.ext_pack_fixed64);
      ProtoAdapter.SINT64.asPacked().encodeWithTag(writer, 1208, value.ext_pack_sint64);
      ProtoAdapter.UINT64.asPacked().encodeWithTag(writer, 1207, value.ext_pack_uint64);
      ProtoAdapter.INT64.asPacked().encodeWithTag(writer, 1206, value.ext_pack_int64);
      ProtoAdapter.SFIXED32.asPacked().encodeWithTag(writer, 1205, value.ext_pack_sfixed32);
      ProtoAdapter.FIXED32.asPacked().encodeWithTag(writer, 1204, value.ext_pack_fixed32);
      ProtoAdapter.SINT32.asPacked().encodeWithTag(writer, 1203, value.ext_pack_sint32);
      ProtoAdapter.UINT32.asPacked().encodeWithTag(writer, 1202, value.ext_pack_uint32);
      ProtoAdapter.INT32.asPacked().encodeWithTag(writer, 1201, value.ext_pack_int32);
      NestedMessage.ADAPTER.asRepeated().encodeWithTag(writer, 1117, value.ext_rep_nested_message);
      NestedEnum.ADAPTER.asRepeated().encodeWithTag(writer, 1116, value.ext_rep_nested_enum);
      ProtoAdapter.BYTES.asRepeated().encodeWithTag(writer, 1115, value.ext_rep_bytes);
      ProtoAdapter.STRING.asRepeated().encodeWithTag(writer, 1114, value.ext_rep_string);
      ProtoAdapter.DOUBLE.asRepeated().encodeWithTag(writer, 1113, value.ext_rep_double);
      ProtoAdapter.FLOAT.asRepeated().encodeWithTag(writer, 1112, value.ext_rep_float);
      ProtoAdapter.BOOL.asRepeated().encodeWithTag(writer, 1111, value.ext_rep_bool);
      ProtoAdapter.SFIXED64.asRepeated().encodeWithTag(writer, 1110, value.ext_rep_sfixed64);
      ProtoAdapter.FIXED64.asRepeated().encodeWithTag(writer, 1109, value.ext_rep_fixed64);
      ProtoAdapter.SINT64.asRepeated().encodeWithTag(writer, 1108, value.ext_rep_sint64);
      ProtoAdapter.UINT64.asRepeated().encodeWithTag(writer, 1107, value.ext_rep_uint64);
      ProtoAdapter.INT64.asRepeated().encodeWithTag(writer, 1106, value.ext_rep_int64);
      ProtoAdapter.SFIXED32.asRepeated().encodeWithTag(writer, 1105, value.ext_rep_sfixed32);
      ProtoAdapter.FIXED32.asRepeated().encodeWithTag(writer, 1104, value.ext_rep_fixed32);
      ProtoAdapter.SINT32.asRepeated().encodeWithTag(writer, 1103, value.ext_rep_sint32);
      ProtoAdapter.UINT32.asRepeated().encodeWithTag(writer, 1102, value.ext_rep_uint32);
      ProtoAdapter.INT32.asRepeated().encodeWithTag(writer, 1101, value.ext_rep_int32);
      NestedMessage.ADAPTER.encodeWithTag(writer, 1017, value.ext_opt_nested_message);
      NestedEnum.ADAPTER.encodeWithTag(writer, 1016, value.ext_opt_nested_enum);
      ProtoAdapter.BYTES.encodeWithTag(writer, 1015, value.ext_opt_bytes);
      ProtoAdapter.STRING.encodeWithTag(writer, 1014, value.ext_opt_string);
      ProtoAdapter.DOUBLE.encodeWithTag(writer, 1013, value.ext_opt_double);
      ProtoAdapter.FLOAT.encodeWithTag(writer, 1012, value.ext_opt_float);
      ProtoAdapter.BOOL.encodeWithTag(writer, 1011, value.ext_opt_bool);
      ProtoAdapter.SFIXED64.encodeWithTag(writer, 1010, value.ext_opt_sfixed64);
      ProtoAdapter.FIXED64.encodeWithTag(writer, 1009, value.ext_opt_fixed64);
      ProtoAdapter.SINT64.encodeWithTag(writer, 1008, value.ext_opt_sint64);
      ProtoAdapter.UINT64.encodeWithTag(writer, 1007, value.ext_opt_uint64);
      ProtoAdapter.INT64.encodeWithTag(writer, 1006, value.ext_opt_int64);
      ProtoAdapter.SFIXED32.encodeWithTag(writer, 1005, value.ext_opt_sfixed32);
      ProtoAdapter.FIXED32.encodeWithTag(writer, 1004, value.ext_opt_fixed32);
      ProtoAdapter.SINT32.encodeWithTag(writer, 1003, value.ext_opt_sint32);
      ProtoAdapter.UINT32.encodeWithTag(writer, 1002, value.ext_opt_uint32);
      ProtoAdapter.INT32.encodeWithTag(writer, 1001, value.ext_opt_int32);
      map_string_enumAdapter().encodeWithTag(writer, 504, value.map_string_enum);
      map_string_messageAdapter().encodeWithTag(writer, 503, value.map_string_message);
      map_string_stringAdapter().encodeWithTag(writer, 502, value.map_string_string);
      map_int32_int32Adapter().encodeWithTag(writer, 501, value.map_int32_int32);
      NestedEnum.ADAPTER.encodeWithTag(writer, 416, value.default_nested_enum);
      ProtoAdapter.BYTES.encodeWithTag(writer, 415, value.default_bytes);
      ProtoAdapter.STRING.encodeWithTag(writer, 414, value.default_string);
      ProtoAdapter.DOUBLE.encodeWithTag(writer, 413, value.default_double);
      ProtoAdapter.FLOAT.encodeWithTag(writer, 412, value.default_float);
      ProtoAdapter.BOOL.encodeWithTag(writer, 411, value.default_bool);
      ProtoAdapter.SFIXED64.encodeWithTag(writer, 410, value.default_sfixed64);
      ProtoAdapter.FIXED64.encodeWithTag(writer, 409, value.default_fixed64);
      ProtoAdapter.SINT64.encodeWithTag(writer, 408, value.default_sint64);
      ProtoAdapter.UINT64.encodeWithTag(writer, 407, value.default_uint64);
      ProtoAdapter.INT64.encodeWithTag(writer, 406, value.default_int64);
      ProtoAdapter.SFIXED32.encodeWithTag(writer, 405, value.default_sfixed32);
      ProtoAdapter.FIXED32.encodeWithTag(writer, 404, value.default_fixed32);
      ProtoAdapter.SINT32.encodeWithTag(writer, 403, value.default_sint32);
      ProtoAdapter.UINT32.encodeWithTag(writer, 402, value.default_uint32);
      ProtoAdapter.INT32.encodeWithTag(writer, 401, value.default_int32);
      NestedEnum.ADAPTER.asPacked().encodeWithTag(writer, 316, value.pack_nested_enum);
      ProtoAdapter.DOUBLE.asPacked().encodeWithTag(writer, 313, value.pack_double);
      ProtoAdapter.FLOAT.asPacked().encodeWithTag(writer, 312, value.pack_float);
      ProtoAdapter.BOOL.asPacked().encodeWithTag(writer, 311, value.pack_bool);
      ProtoAdapter.SFIXED64.asPacked().encodeWithTag(writer, 310, value.pack_sfixed64);
      ProtoAdapter.FIXED64.asPacked().encodeWithTag(writer, 309, value.pack_fixed64);
      ProtoAdapter.SINT64.asPacked().encodeWithTag(writer, 308, value.pack_sint64);
      ProtoAdapter.UINT64.asPacked().encodeWithTag(writer, 307, value.pack_uint64);
      ProtoAdapter.INT64.asPacked().encodeWithTag(writer, 306, value.pack_int64);
      ProtoAdapter.SFIXED32.asPacked().encodeWithTag(writer, 305, value.pack_sfixed32);
      ProtoAdapter.FIXED32.asPacked().encodeWithTag(writer, 304, value.pack_fixed32);
      ProtoAdapter.SINT32.asPacked().encodeWithTag(writer, 303, value.pack_sint32);
      ProtoAdapter.UINT32.asPacked().encodeWithTag(writer, 302, value.pack_uint32);
      ProtoAdapter.INT32.asPacked().encodeWithTag(writer, 301, value.pack_int32);
      NestedMessage.ADAPTER.asRepeated().encodeWithTag(writer, 217, value.rep_nested_message);
      NestedEnum.ADAPTER.asRepeated().encodeWithTag(writer, 216, value.rep_nested_enum);
      ProtoAdapter.BYTES.asRepeated().encodeWithTag(writer, 215, value.rep_bytes);
      ProtoAdapter.STRING.asRepeated().encodeWithTag(writer, 214, value.rep_string);
      ProtoAdapter.DOUBLE.asRepeated().encodeWithTag(writer, 213, value.rep_double);
      ProtoAdapter.FLOAT.asRepeated().encodeWithTag(writer, 212, value.rep_float);
      ProtoAdapter.BOOL.asRepeated().encodeWithTag(writer, 211, value.rep_bool);
      ProtoAdapter.SFIXED64.asRepeated().encodeWithTag(writer, 210, value.rep_sfixed64);
      ProtoAdapter.FIXED64.asRepeated().encodeWithTag(writer, 209, value.rep_fixed64);
      ProtoAdapter.SINT64.asRepeated().encodeWithTag(writer, 208, value.rep_sint64);
      ProtoAdapter.UINT64.asRepeated().encodeWithTag(writer, 207, value.rep_uint64);
      ProtoAdapter.INT64.asRepeated().encodeWithTag(writer, 206, value.rep_int64);
      ProtoAdapter.SFIXED32.asRepeated().encodeWithTag(writer, 205, value.rep_sfixed32);
      ProtoAdapter.FIXED32.asRepeated().encodeWithTag(writer, 204, value.rep_fixed32);
      ProtoAdapter.SINT32.asRepeated().encodeWithTag(writer, 203, value.rep_sint32);
      ProtoAdapter.UINT32.asRepeated().encodeWithTag(writer, 202, value.rep_uint32);
      ProtoAdapter.INT32.asRepeated().encodeWithTag(writer, 201, value.rep_int32);
      NestedMessage.ADAPTER.encodeWithTag(writer, 117, value.req_nested_message);
      NestedEnum.ADAPTER.encodeWithTag(writer, 116, value.req_nested_enum);
      ProtoAdapter.BYTES.encodeWithTag(writer, 115, value.req_bytes);
      ProtoAdapter.STRING.encodeWithTag(writer, 114, value.req_string);
      ProtoAdapter.DOUBLE.encodeWithTag(writer, 113, value.req_double);
      ProtoAdapter.FLOAT.encodeWithTag(writer, 112, value.req_float);
      ProtoAdapter.BOOL.encodeWithTag(writer, 111, value.req_bool);
      ProtoAdapter.SFIXED64.encodeWithTag(writer, 110, value.req_sfixed64);
      ProtoAdapter.FIXED64.encodeWithTag(writer, 109, value.req_fixed64);
      ProtoAdapter.SINT64.encodeWithTag(writer, 108, value.req_sint64);
      ProtoAdapter.UINT64.encodeWithTag(writer, 107, value.req_uint64);
      ProtoAdapter.INT64.encodeWithTag(writer, 106, value.req_int64);
      ProtoAdapter.SFIXED32.encodeWithTag(writer, 105, value.req_sfixed32);
      ProtoAdapter.FIXED32.encodeWithTag(writer, 104, value.req_fixed32);
      ProtoAdapter.SINT32.encodeWithTag(writer, 103, value.req_sint32);
      ProtoAdapter.UINT32.encodeWithTag(writer, 102, value.req_uint32);
      ProtoAdapter.INT32.encodeWithTag(writer, 101, value.req_int32);
      NestedMessage.ADAPTER.encodeWithTag(writer, 17, value.opt_nested_message);
      NestedEnum.ADAPTER.encodeWithTag(writer, 16, value.opt_nested_enum);
      ProtoAdapter.BYTES.encodeWithTag(writer, 15, value.opt_bytes);
      ProtoAdapter.STRING.encodeWithTag(writer, 14, value.opt_string);
      ProtoAdapter.DOUBLE.encodeWithTag(writer, 13, value.opt_double);
      ProtoAdapter.FLOAT.encodeWithTag(writer, 12, value.opt_float);
      ProtoAdapter.BOOL.encodeWithTag(writer, 11, value.opt_bool);
      ProtoAdapter.SFIXED64.encodeWithTag(writer, 10, value.opt_sfixed64);
      ProtoAdapter.FIXED64.encodeWithTag(writer, 9, value.opt_fixed64);
      ProtoAdapter.SINT64.encodeWithTag(writer, 8, value.opt_sint64);
      ProtoAdapter.UINT64.encodeWithTag(writer, 7, value.opt_uint64);
      ProtoAdapter.INT64.encodeWithTag(writer, 6, value.opt_int64);
      ProtoAdapter.SFIXED32.encodeWithTag(writer, 5, value.opt_sfixed32);
      ProtoAdapter.FIXED32.encodeWithTag(writer, 4, value.opt_fixed32);
      ProtoAdapter.SINT32.encodeWithTag(writer, 3, value.opt_sint32);
      ProtoAdapter.UINT32.encodeWithTag(writer, 2, value.opt_uint32);
      ProtoAdapter.INT32.encodeWithTag(writer, 1, value.opt_int32);
    }

    @Override
    public AllTypes decode(ProtoReader reader) throws IOException {
      Builder builder = new Builder();
      long token = reader.beginMessage();
      for (int tag; (tag = reader.nextTag()) != -1;) {
        switch (tag) {
          case 1: builder.opt_int32(ProtoAdapter.INT32.decode(reader)); break;
          case 2: builder.opt_uint32(ProtoAdapter.UINT32.decode(reader)); break;
          case 3: builder.opt_sint32(ProtoAdapter.SINT32.decode(reader)); break;
          case 4: builder.opt_fixed32(ProtoAdapter.FIXED32.decode(reader)); break;
          case 5: builder.opt_sfixed32(ProtoAdapter.SFIXED32.decode(reader)); break;
          case 6: builder.opt_int64(ProtoAdapter.INT64.decode(reader)); break;
          case 7: builder.opt_uint64(ProtoAdapter.UINT64.decode(reader)); break;
          case 8: builder.opt_sint64(ProtoAdapter.SINT64.decode(reader)); break;
          case 9: builder.opt_fixed64(ProtoAdapter.FIXED64.decode(reader)); break;
          case 10: builder.opt_sfixed64(ProtoAdapter.SFIXED64.decode(reader)); break;
          case 11: builder.opt_bool(ProtoAdapter.BOOL.decode(reader)); break;
          case 12: builder.opt_float(ProtoAdapter.FLOAT.decode(reader)); break;
          case 13: builder.opt_double(ProtoAdapter.DOUBLE.decode(reader)); break;
          case 14: builder.opt_string(ProtoAdapter.STRING.decode(reader)); break;
          case 15: builder.opt_bytes(ProtoAdapter.BYTES.decode(reader)); break;
          case 16: {
            try {
              builder.opt_nested_enum(NestedEnum.ADAPTER.decode(reader));
            } catch (ProtoAdapter.EnumConstantNotFoundException e) {
              builder.addUnknownField(tag, FieldEncoding.VARINT, (long) e.value);
            }
            break;
          }
          case 17: builder.opt_nested_message(NestedMessage.ADAPTER.decode(reader)); break;
          case 101: builder.req_int32(ProtoAdapter.INT32.decode(reader)); break;
          case 102: builder.req_uint32(ProtoAdapter.UINT32.decode(reader)); break;
          case 103: builder.req_sint32(ProtoAdapter.SINT32.decode(reader)); break;
          case 104: builder.req_fixed32(ProtoAdapter.FIXED32.decode(reader)); break;
          case 105: builder.req_sfixed32(ProtoAdapter.SFIXED32.decode(reader)); break;
          case 106: builder.req_int64(ProtoAdapter.INT64.decode(reader)); break;
          case 107: builder.req_uint64(ProtoAdapter.UINT64.decode(reader)); break;
          case 108: builder.req_sint64(ProtoAdapter.SINT64.decode(reader)); break;
          case 109: builder.req_fixed64(ProtoAdapter.FIXED64.decode(reader)); break;
          case 110: builder.req_sfixed64(ProtoAdapter.SFIXED64.decode(reader)); break;
          case 111: builder.req_bool(ProtoAdapter.BOOL.decode(reader)); break;
          case 112: builder.req_float(ProtoAdapter.FLOAT.decode(reader)); break;
          case 113: builder.req_double(ProtoAdapter.DOUBLE.decode(reader)); break;
          case 114: builder.req_string(ProtoAdapter.STRING.decode(reader)); break;
          case 115: builder.req_bytes(ProtoAdapter.BYTES.decode(reader)); break;
          case 116: {
            try {
              builder.req_nested_enum(NestedEnum.ADAPTER.decode(reader));
            } catch (ProtoAdapter.EnumConstantNotFoundException e) {
              builder.addUnknownField(tag, FieldEncoding.VARINT, (long) e.value);
            }
            break;
          }
          case 117: builder.req_nested_message(NestedMessage.ADAPTER.decode(reader)); break;
          case 201: builder.rep_int32.add(ProtoAdapter.INT32.decode(reader)); break;
          case 202: builder.rep_uint32.add(ProtoAdapter.UINT32.decode(reader)); break;
          case 203: builder.rep_sint32.add(ProtoAdapter.SINT32.decode(reader)); break;
          case 204: builder.rep_fixed32.add(ProtoAdapter.FIXED32.decode(reader)); break;
          case 205: builder.rep_sfixed32.add(ProtoAdapter.SFIXED32.decode(reader)); break;
          case 206: builder.rep_int64.add(ProtoAdapter.INT64.decode(reader)); break;
          case 207: builder.rep_uint64.add(ProtoAdapter.UINT64.decode(reader)); break;
          case 208: builder.rep_sint64.add(ProtoAdapter.SINT64.decode(reader)); break;
          case 209: builder.rep_fixed64.add(ProtoAdapter.FIXED64.decode(reader)); break;
          case 210: builder.rep_sfixed64.add(ProtoAdapter.SFIXED64.decode(reader)); break;
          case 211: builder.rep_bool.add(ProtoAdapter.BOOL.decode(reader)); break;
          case 212: builder.rep_float.add(ProtoAdapter.FLOAT.decode(reader)); break;
          case 213: builder.rep_double.add(ProtoAdapter.DOUBLE.decode(reader)); break;
          case 214: builder.rep_string.add(ProtoAdapter.STRING.decode(reader)); break;
          case 215: builder.rep_bytes.add(ProtoAdapter.BYTES.decode(reader)); break;
          case 216: {
            try {
              builder.rep_nested_enum.add(NestedEnum.ADAPTER.decode(reader));
            } catch (ProtoAdapter.EnumConstantNotFoundException e) {
              builder.addUnknownField(tag, FieldEncoding.VARINT, (long) e.value);
            }
            break;
          }
          case 217: builder.rep_nested_message.add(NestedMessage.ADAPTER.decode(reader)); break;
          case 301: builder.pack_int32.add(ProtoAdapter.INT32.decode(reader)); break;
          case 302: builder.pack_uint32.add(ProtoAdapter.UINT32.decode(reader)); break;
          case 303: builder.pack_sint32.add(ProtoAdapter.SINT32.decode(reader)); break;
          case 304: builder.pack_fixed32.add(ProtoAdapter.FIXED32.decode(reader)); break;
          case 305: builder.pack_sfixed32.add(ProtoAdapter.SFIXED32.decode(reader)); break;
          case 306: builder.pack_int64.add(ProtoAdapter.INT64.decode(reader)); break;
          case 307: builder.pack_uint64.add(ProtoAdapter.UINT64.decode(reader)); break;
          case 308: builder.pack_sint64.add(ProtoAdapter.SINT64.decode(reader)); break;
          case 309: builder.pack_fixed64.add(ProtoAdapter.FIXED64.decode(reader)); break;
          case 310: builder.pack_sfixed64.add(ProtoAdapter.SFIXED64.decode(reader)); break;
          case 311: builder.pack_bool.add(ProtoAdapter.BOOL.decode(reader)); break;
          case 312: builder.pack_float.add(ProtoAdapter.FLOAT.decode(reader)); break;
          case 313: builder.pack_double.add(ProtoAdapter.DOUBLE.decode(reader)); break;
          case 316: {
            try {
              builder.pack_nested_enum.add(NestedEnum.ADAPTER.decode(reader));
            } catch (ProtoAdapter.EnumConstantNotFoundException e) {
              builder.addUnknownField(tag, FieldEncoding.VARINT, (long) e.value);
            }
            break;
          }
          case 401: builder.default_int32(ProtoAdapter.INT32.decode(reader)); break;
          case 402: builder.default_uint32(ProtoAdapter.UINT32.decode(reader)); break;
          case 403: builder.default_sint32(ProtoAdapter.SINT32.decode(reader)); break;
          case 404: builder.default_fixed32(ProtoAdapter.FIXED32.decode(reader)); break;
          case 405: builder.default_sfixed32(ProtoAdapter.SFIXED32.decode(reader)); break;
          case 406: builder.default_int64(ProtoAdapter.INT64.decode(reader)); break;
          case 407: builder.default_uint64(ProtoAdapter.UINT64.decode(reader)); break;
          case 408: builder.default_sint64(ProtoAdapter.SINT64.decode(reader)); break;
          case 409: builder.default_fixed64(ProtoAdapter.FIXED64.decode(reader)); break;
          case 410: builder.default_sfixed64(ProtoAdapter.SFIXED64.decode(reader)); break;
          case 411: builder.default_bool(ProtoAdapter.BOOL.decode(reader)); break;
          case 412: builder.default_float(ProtoAdapter.FLOAT.decode(reader)); break;
          case 413: builder.default_double(ProtoAdapter.DOUBLE.decode(reader)); break;
          case 414: builder.default_string(ProtoAdapter.STRING.decode(reader)); break;
          case 415: builder.default_bytes(ProtoAdapter.BYTES.decode(reader)); break;
          case 416: {
            try {
              builder.default_nested_enum(NestedEnum.ADAPTER.decode(reader));
            } catch (ProtoAdapter.EnumConstantNotFoundException e) {
              builder.addUnknownField(tag, FieldEncoding.VARINT, (long) e.value);
            }
            break;
          }
          case 501: builder.map_int32_int32.putAll(map_int32_int32Adapter().decode(reader)); break;
          case 502: builder.map_string_string.putAll(map_string_stringAdapter().decode(reader)); break;
          case 503: builder.map_string_message.putAll(map_string_messageAdapter().decode(reader)); break;
          case 504: builder.map_string_enum.putAll(map_string_enumAdapter().decode(reader)); break;
          case 1001: builder.ext_opt_int32(ProtoAdapter.INT32.decode(reader)); break;
          case 1002: builder.ext_opt_uint32(ProtoAdapter.UINT32.decode(reader)); break;
          case 1003: builder.ext_opt_sint32(ProtoAdapter.SINT32.decode(reader)); break;
          case 1004: builder.ext_opt_fixed32(ProtoAdapter.FIXED32.decode(reader)); break;
          case 1005: builder.ext_opt_sfixed32(ProtoAdapter.SFIXED32.decode(reader)); break;
          case 1006: builder.ext_opt_int64(ProtoAdapter.INT64.decode(reader)); break;
          case 1007: builder.ext_opt_uint64(ProtoAdapter.UINT64.decode(reader)); break;
          case 1008: builder.ext_opt_sint64(ProtoAdapter.SINT64.decode(reader)); break;
          case 1009: builder.ext_opt_fixed64(ProtoAdapter.FIXED64.decode(reader)); break;
          case 1010: builder.ext_opt_sfixed64(ProtoAdapter.SFIXED64.decode(reader)); break;
          case 1011: builder.ext_opt_bool(ProtoAdapter.BOOL.decode(reader)); break;
          case 1012: builder.ext_opt_float(ProtoAdapter.FLOAT.decode(reader)); break;
          case 1013: builder.ext_opt_double(ProtoAdapter.DOUBLE.decode(reader)); break;
          case 1014: builder.ext_opt_string(ProtoAdapter.STRING.decode(reader)); break;
          case 1015: builder.ext_opt_bytes(ProtoAdapter.BYTES.decode(reader)); break;
          case 1016: {
            try {
              builder.ext_opt_nested_enum(NestedEnum.ADAPTER.decode(reader));
            } catch (ProtoAdapter.EnumConstantNotFoundException e) {
              builder.addUnknownField(tag, FieldEncoding.VARINT, (long) e.value);
            }
            break;
          }
          case 1017: builder.ext_opt_nested_message(NestedMessage.ADAPTER.decode(reader)); break;
          case 1101: builder.ext_rep_int32.add(ProtoAdapter.INT32.decode(reader)); break;
          case 1102: builder.ext_rep_uint32.add(ProtoAdapter.UINT32.decode(reader)); break;
          case 1103: builder.ext_rep_sint32.add(ProtoAdapter.SINT32.decode(reader)); break;
          case 1104: builder.ext_rep_fixed32.add(ProtoAdapter.FIXED32.decode(reader)); break;
          case 1105: builder.ext_rep_sfixed32.add(ProtoAdapter.SFIXED32.decode(reader)); break;
          case 1106: builder.ext_rep_int64.add(ProtoAdapter.INT64.decode(reader)); break;
          case 1107: builder.ext_rep_uint64.add(ProtoAdapter.UINT64.decode(reader)); break;
          case 1108: builder.ext_rep_sint64.add(ProtoAdapter.SINT64.decode(reader)); break;
          case 1109: builder.ext_rep_fixed64.add(ProtoAdapter.FIXED64.decode(reader)); break;
          case 1110: builder.ext_rep_sfixed64.add(ProtoAdapter.SFIXED64.decode(reader)); break;
          case 1111: builder.ext_rep_bool.add(ProtoAdapter.BOOL.decode(reader)); break;
          case 1112: builder.ext_rep_float.add(ProtoAdapter.FLOAT.decode(reader)); break;
          case 1113: builder.ext_rep_double.add(ProtoAdapter.DOUBLE.decode(reader)); break;
          case 1114: builder.ext_rep_string.add(ProtoAdapter.STRING.decode(reader)); break;
          case 1115: builder.ext_rep_bytes.add(ProtoAdapter.BYTES.decode(reader)); break;
          case 1116: {
            try {
              builder.ext_rep_nested_enum.add(NestedEnum.ADAPTER.decode(reader));
            } catch (ProtoAdapter.EnumConstantNotFoundException e) {
              builder.addUnknownField(tag, FieldEncoding.VARINT, (long) e.value);
            }
            break;
          }
          case 1117: builder.ext_rep_nested_message.add(NestedMessage.ADAPTER.decode(reader)); break;
          case 1201: builder.ext_pack_int32.add(ProtoAdapter.INT32.decode(reader)); break;
          case 1202: builder.ext_pack_uint32.add(ProtoAdapter.UINT32.decode(reader)); break;
          case 1203: builder.ext_pack_sint32.add(ProtoAdapter.SINT32.decode(reader)); break;
          case 1204: builder.ext_pack_fixed32.add(ProtoAdapter.FIXED32.decode(reader)); break;
          case 1205: builder.ext_pack_sfixed32.add(ProtoAdapter.SFIXED32.decode(reader)); break;
          case 1206: builder.ext_pack_int64.add(ProtoAdapter.INT64.decode(reader)); break;
          case 1207: builder.ext_pack_uint64.add(ProtoAdapter.UINT64.decode(reader)); break;
          case 1208: builder.ext_pack_sint64.add(ProtoAdapter.SINT64.decode(reader)); break;
          case 1209: builder.ext_pack_fixed64.add(ProtoAdapter.FIXED64.decode(reader)); break;
          case 1210: builder.ext_pack_sfixed64.add(ProtoAdapter.SFIXED64.decode(reader)); break;
          case 1211: builder.ext_pack_bool.add(ProtoAdapter.BOOL.decode(reader)); break;
          case 1212: builder.ext_pack_float.add(ProtoAdapter.FLOAT.decode(reader)); break;
          case 1213: builder.ext_pack_double.add(ProtoAdapter.DOUBLE.decode(reader)); break;
          case 1216: {
            try {
              builder.ext_pack_nested_enum.add(NestedEnum.ADAPTER.decode(reader));
            } catch (ProtoAdapter.EnumConstantNotFoundException e) {
              builder.addUnknownField(tag, FieldEncoding.VARINT, (long) e.value);
            }
            break;
          }
          default: {
            reader.readUnknownField(tag);
          }
        }
      }
      builder.addUnknownFields(reader.endMessageAndGetUnknownFields(token));
      return builder.build();
    }

    @Override
    public AllTypes redact(AllTypes value) {
      Builder builder = value.newBuilder();
      if (builder.opt_nested_message != null) builder.opt_nested_message = NestedMessage.ADAPTER.redact(builder.opt_nested_message);
      builder.req_nested_message = NestedMessage.ADAPTER.redact(builder.req_nested_message);
      Internal.redactElements(builder.rep_nested_message, NestedMessage.ADAPTER);
      Internal.redactElements(builder.map_string_message, NestedMessage.ADAPTER);
      if (builder.ext_opt_nested_message != null) builder.ext_opt_nested_message = NestedMessage.ADAPTER.redact(builder.ext_opt_nested_message);
      Internal.redactElements(builder.ext_rep_nested_message, NestedMessage.ADAPTER);
      builder.clearUnknownFields();
      return builder.build();
    }

    private ProtoAdapter<Map<Integer, Integer>> map_int32_int32Adapter() {
      ProtoAdapter<Map<Integer, Integer>> result = map_int32_int32;
      if (result == null) {
        result = ProtoAdapter.newMapAdapter(ProtoAdapter.INT32, ProtoAdapter.INT32);
        map_int32_int32 = result;
      }
      return result;
    }

    private ProtoAdapter<Map<String, String>> map_string_stringAdapter() {
      ProtoAdapter<Map<String, String>> result = map_string_string;
      if (result == null) {
        result = ProtoAdapter.newMapAdapter(ProtoAdapter.STRING, ProtoAdapter.STRING);
        map_string_string = result;
      }
      return result;
    }

    private ProtoAdapter<Map<String, NestedMessage>> map_string_messageAdapter() {
      ProtoAdapter<Map<String, NestedMessage>> result = map_string_message;
      if (result == null) {
        result = ProtoAdapter.newMapAdapter(ProtoAdapter.STRING, NestedMessage.ADAPTER);
        map_string_message = result;
      }
      return result;
    }

    private ProtoAdapter<Map<String, NestedEnum>> map_string_enumAdapter() {
      ProtoAdapter<Map<String, NestedEnum>> result = map_string_enum;
      if (result == null) {
        result = ProtoAdapter.newMapAdapter(ProtoAdapter.STRING, NestedEnum.ADAPTER);
        map_string_enum = result;
      }
      return result;
    }
  }
}
