// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: SignalService.proto

package org.session.libsignal.protos;

public final class SignalServiceProtos {
  private SignalServiceProtos() {}
  public static void registerAllExtensions(
      com.google.protobuf.ExtensionRegistry registry) {
  }
  public interface EnvelopeOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // required .signalservice.Envelope.Type type = 1;
    /**
     * <code>required .signalservice.Envelope.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasType();
    /**
     * <code>required .signalservice.Envelope.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    org.session.libsignal.protos.SignalServiceProtos.Envelope.Type getType();

    // optional string source = 2;
    /**
     * <code>optional string source = 2;</code>
     */
    boolean hasSource();
    /**
     * <code>optional string source = 2;</code>
     */
    java.lang.String getSource();
    /**
     * <code>optional string source = 2;</code>
     */
    com.google.protobuf.ByteString
        getSourceBytes();

    // optional uint32 sourceDevice = 7;
    /**
     * <code>optional uint32 sourceDevice = 7;</code>
     */
    boolean hasSourceDevice();
    /**
     * <code>optional uint32 sourceDevice = 7;</code>
     */
    int getSourceDevice();

    // required uint64 timestamp = 5;
    /**
     * <code>required uint64 timestamp = 5;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasTimestamp();
    /**
     * <code>required uint64 timestamp = 5;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    long getTimestamp();

    // optional bytes content = 8;
    /**
     * <code>optional bytes content = 8;</code>
     */
    boolean hasContent();
    /**
     * <code>optional bytes content = 8;</code>
     */
    com.google.protobuf.ByteString getContent();

    // optional uint64 serverTimestamp = 10;
    /**
     * <code>optional uint64 serverTimestamp = 10;</code>
     */
    boolean hasServerTimestamp();
    /**
     * <code>optional uint64 serverTimestamp = 10;</code>
     */
    long getServerTimestamp();
  }
  /**
   * Protobuf type {@code signalservice.Envelope}
   */
  public static final class Envelope extends
      com.google.protobuf.GeneratedMessage
      implements EnvelopeOrBuilder {
    // Use Envelope.newBuilder() to construct.
    private Envelope(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private Envelope(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final Envelope defaultInstance;
    public static Envelope getDefaultInstance() {
      return defaultInstance;
    }

    public Envelope getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private Envelope(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 8: {
              int rawValue = input.readEnum();
              org.session.libsignal.protos.SignalServiceProtos.Envelope.Type value = org.session.libsignal.protos.SignalServiceProtos.Envelope.Type.valueOf(rawValue);
              if (value == null) {
                unknownFields.mergeVarintField(1, rawValue);
              } else {
                bitField0_ |= 0x00000001;
                type_ = value;
              }
              break;
            }
            case 18: {
              bitField0_ |= 0x00000002;
              source_ = input.readBytes();
              break;
            }
            case 40: {
              bitField0_ |= 0x00000008;
              timestamp_ = input.readUInt64();
              break;
            }
            case 56: {
              bitField0_ |= 0x00000004;
              sourceDevice_ = input.readUInt32();
              break;
            }
            case 66: {
              bitField0_ |= 0x00000010;
              content_ = input.readBytes();
              break;
            }
            case 80: {
              bitField0_ |= 0x00000020;
              serverTimestamp_ = input.readUInt64();
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_Envelope_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_Envelope_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.Envelope.class, org.session.libsignal.protos.SignalServiceProtos.Envelope.Builder.class);
    }

    public static com.google.protobuf.Parser<Envelope> PARSER =
        new com.google.protobuf.AbstractParser<Envelope>() {
      public Envelope parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new Envelope(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<Envelope> getParserForType() {
      return PARSER;
    }

    /**
     * Protobuf enum {@code signalservice.Envelope.Type}
     */
    public enum Type
        implements com.google.protobuf.ProtocolMessageEnum {
      /**
       * <code>SESSION_MESSAGE = 6;</code>
       */
      SESSION_MESSAGE(0, 6),
      /**
       * <code>CLOSED_GROUP_MESSAGE = 7;</code>
       */
      CLOSED_GROUP_MESSAGE(1, 7),
      ;

      /**
       * <code>SESSION_MESSAGE = 6;</code>
       */
      public static final int SESSION_MESSAGE_VALUE = 6;
      /**
       * <code>CLOSED_GROUP_MESSAGE = 7;</code>
       */
      public static final int CLOSED_GROUP_MESSAGE_VALUE = 7;


      public final int getNumber() { return value; }

      public static Type valueOf(int value) {
        switch (value) {
          case 6: return SESSION_MESSAGE;
          case 7: return CLOSED_GROUP_MESSAGE;
          default: return null;
        }
      }

      public static com.google.protobuf.Internal.EnumLiteMap<Type>
          internalGetValueMap() {
        return internalValueMap;
      }
      private static com.google.protobuf.Internal.EnumLiteMap<Type>
          internalValueMap =
            new com.google.protobuf.Internal.EnumLiteMap<Type>() {
              public Type findValueByNumber(int number) {
                return Type.valueOf(number);
              }
            };

      public final com.google.protobuf.Descriptors.EnumValueDescriptor
          getValueDescriptor() {
        return getDescriptor().getValues().get(index);
      }
      public final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptorForType() {
        return getDescriptor();
      }
      public static final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.Envelope.getDescriptor().getEnumTypes().get(0);
      }

      private static final Type[] VALUES = values();

      public static Type valueOf(
          com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
        if (desc.getType() != getDescriptor()) {
          throw new java.lang.IllegalArgumentException(
            "EnumValueDescriptor is not for this type.");
        }
        return VALUES[desc.getIndex()];
      }

      private final int index;
      private final int value;

      private Type(int index, int value) {
        this.index = index;
        this.value = value;
      }

      // @@protoc_insertion_point(enum_scope:signalservice.Envelope.Type)
    }

    private int bitField0_;
    // required .signalservice.Envelope.Type type = 1;
    public static final int TYPE_FIELD_NUMBER = 1;
    private org.session.libsignal.protos.SignalServiceProtos.Envelope.Type type_;
    /**
     * <code>required .signalservice.Envelope.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasType() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>required .signalservice.Envelope.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public org.session.libsignal.protos.SignalServiceProtos.Envelope.Type getType() {
      return type_;
    }

    // optional string source = 2;
    public static final int SOURCE_FIELD_NUMBER = 2;
    private java.lang.Object source_;
    /**
     * <code>optional string source = 2;</code>
     */
    public boolean hasSource() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>optional string source = 2;</code>
     */
    public java.lang.String getSource() {
      java.lang.Object ref = source_;
      if (ref instanceof java.lang.String) {
        return (java.lang.String) ref;
      } else {
        com.google.protobuf.ByteString bs = 
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          source_ = s;
        }
        return s;
      }
    }
    /**
     * <code>optional string source = 2;</code>
     */
    public com.google.protobuf.ByteString
        getSourceBytes() {
      java.lang.Object ref = source_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        source_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    // optional uint32 sourceDevice = 7;
    public static final int SOURCEDEVICE_FIELD_NUMBER = 7;
    private int sourceDevice_;
    /**
     * <code>optional uint32 sourceDevice = 7;</code>
     */
    public boolean hasSourceDevice() {
      return ((bitField0_ & 0x00000004) == 0x00000004);
    }
    /**
     * <code>optional uint32 sourceDevice = 7;</code>
     */
    public int getSourceDevice() {
      return sourceDevice_;
    }

    // required uint64 timestamp = 5;
    public static final int TIMESTAMP_FIELD_NUMBER = 5;
    private long timestamp_;
    /**
     * <code>required uint64 timestamp = 5;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasTimestamp() {
      return ((bitField0_ & 0x00000008) == 0x00000008);
    }
    /**
     * <code>required uint64 timestamp = 5;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public long getTimestamp() {
      return timestamp_;
    }

    // optional bytes content = 8;
    public static final int CONTENT_FIELD_NUMBER = 8;
    private com.google.protobuf.ByteString content_;
    /**
     * <code>optional bytes content = 8;</code>
     */
    public boolean hasContent() {
      return ((bitField0_ & 0x00000010) == 0x00000010);
    }
    /**
     * <code>optional bytes content = 8;</code>
     */
    public com.google.protobuf.ByteString getContent() {
      return content_;
    }

    // optional uint64 serverTimestamp = 10;
    public static final int SERVERTIMESTAMP_FIELD_NUMBER = 10;
    private long serverTimestamp_;
    /**
     * <code>optional uint64 serverTimestamp = 10;</code>
     */
    public boolean hasServerTimestamp() {
      return ((bitField0_ & 0x00000020) == 0x00000020);
    }
    /**
     * <code>optional uint64 serverTimestamp = 10;</code>
     */
    public long getServerTimestamp() {
      return serverTimestamp_;
    }

    private void initFields() {
      type_ = org.session.libsignal.protos.SignalServiceProtos.Envelope.Type.SESSION_MESSAGE;
      source_ = "";
      sourceDevice_ = 0;
      timestamp_ = 0L;
      content_ = com.google.protobuf.ByteString.EMPTY;
      serverTimestamp_ = 0L;
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      if (!hasType()) {
        memoizedIsInitialized = 0;
        return false;
      }
      if (!hasTimestamp()) {
        memoizedIsInitialized = 0;
        return false;
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeEnum(1, type_.getNumber());
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeBytes(2, getSourceBytes());
      }
      if (((bitField0_ & 0x00000008) == 0x00000008)) {
        output.writeUInt64(5, timestamp_);
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        output.writeUInt32(7, sourceDevice_);
      }
      if (((bitField0_ & 0x00000010) == 0x00000010)) {
        output.writeBytes(8, content_);
      }
      if (((bitField0_ & 0x00000020) == 0x00000020)) {
        output.writeUInt64(10, serverTimestamp_);
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeEnumSize(1, type_.getNumber());
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(2, getSourceBytes());
      }
      if (((bitField0_ & 0x00000008) == 0x00000008)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt64Size(5, timestamp_);
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt32Size(7, sourceDevice_);
      }
      if (((bitField0_ & 0x00000010) == 0x00000010)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(8, content_);
      }
      if (((bitField0_ & 0x00000020) == 0x00000020)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt64Size(10, serverTimestamp_);
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.Envelope parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Envelope parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Envelope parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Envelope parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Envelope parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Envelope parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Envelope parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Envelope parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Envelope parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Envelope parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.Envelope prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.Envelope}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.EnvelopeOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_Envelope_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_Envelope_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.Envelope.class, org.session.libsignal.protos.SignalServiceProtos.Envelope.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.Envelope.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        type_ = org.session.libsignal.protos.SignalServiceProtos.Envelope.Type.SESSION_MESSAGE;
        bitField0_ = (bitField0_ & ~0x00000001);
        source_ = "";
        bitField0_ = (bitField0_ & ~0x00000002);
        sourceDevice_ = 0;
        bitField0_ = (bitField0_ & ~0x00000004);
        timestamp_ = 0L;
        bitField0_ = (bitField0_ & ~0x00000008);
        content_ = com.google.protobuf.ByteString.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000010);
        serverTimestamp_ = 0L;
        bitField0_ = (bitField0_ & ~0x00000020);
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_Envelope_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.Envelope getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.Envelope.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.Envelope build() {
        org.session.libsignal.protos.SignalServiceProtos.Envelope result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.Envelope buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.Envelope result = new org.session.libsignal.protos.SignalServiceProtos.Envelope(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.type_ = type_;
        if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
          to_bitField0_ |= 0x00000002;
        }
        result.source_ = source_;
        if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
          to_bitField0_ |= 0x00000004;
        }
        result.sourceDevice_ = sourceDevice_;
        if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
          to_bitField0_ |= 0x00000008;
        }
        result.timestamp_ = timestamp_;
        if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
          to_bitField0_ |= 0x00000010;
        }
        result.content_ = content_;
        if (((from_bitField0_ & 0x00000020) == 0x00000020)) {
          to_bitField0_ |= 0x00000020;
        }
        result.serverTimestamp_ = serverTimestamp_;
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.Envelope) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.Envelope)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.Envelope other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.Envelope.getDefaultInstance()) return this;
        if (other.hasType()) {
          setType(other.getType());
        }
        if (other.hasSource()) {
          bitField0_ |= 0x00000002;
          source_ = other.source_;
          onChanged();
        }
        if (other.hasSourceDevice()) {
          setSourceDevice(other.getSourceDevice());
        }
        if (other.hasTimestamp()) {
          setTimestamp(other.getTimestamp());
        }
        if (other.hasContent()) {
          setContent(other.getContent());
        }
        if (other.hasServerTimestamp()) {
          setServerTimestamp(other.getServerTimestamp());
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        if (!hasType()) {
          
          return false;
        }
        if (!hasTimestamp()) {
          
          return false;
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.Envelope parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.Envelope) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // required .signalservice.Envelope.Type type = 1;
      private org.session.libsignal.protos.SignalServiceProtos.Envelope.Type type_ = org.session.libsignal.protos.SignalServiceProtos.Envelope.Type.SESSION_MESSAGE;
      /**
       * <code>required .signalservice.Envelope.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasType() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required .signalservice.Envelope.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public org.session.libsignal.protos.SignalServiceProtos.Envelope.Type getType() {
        return type_;
      }
      /**
       * <code>required .signalservice.Envelope.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setType(org.session.libsignal.protos.SignalServiceProtos.Envelope.Type value) {
        if (value == null) {
          throw new NullPointerException();
        }
        bitField0_ |= 0x00000001;
        type_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required .signalservice.Envelope.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearType() {
        bitField0_ = (bitField0_ & ~0x00000001);
        type_ = org.session.libsignal.protos.SignalServiceProtos.Envelope.Type.SESSION_MESSAGE;
        onChanged();
        return this;
      }

      // optional string source = 2;
      private java.lang.Object source_ = "";
      /**
       * <code>optional string source = 2;</code>
       */
      public boolean hasSource() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>optional string source = 2;</code>
       */
      public java.lang.String getSource() {
        java.lang.Object ref = source_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          source_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>optional string source = 2;</code>
       */
      public com.google.protobuf.ByteString
          getSourceBytes() {
        java.lang.Object ref = source_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          source_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>optional string source = 2;</code>
       */
      public Builder setSource(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
        source_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional string source = 2;</code>
       */
      public Builder clearSource() {
        bitField0_ = (bitField0_ & ~0x00000002);
        source_ = getDefaultInstance().getSource();
        onChanged();
        return this;
      }
      /**
       * <code>optional string source = 2;</code>
       */
      public Builder setSourceBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
        source_ = value;
        onChanged();
        return this;
      }

      // optional uint32 sourceDevice = 7;
      private int sourceDevice_ ;
      /**
       * <code>optional uint32 sourceDevice = 7;</code>
       */
      public boolean hasSourceDevice() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional uint32 sourceDevice = 7;</code>
       */
      public int getSourceDevice() {
        return sourceDevice_;
      }
      /**
       * <code>optional uint32 sourceDevice = 7;</code>
       */
      public Builder setSourceDevice(int value) {
        bitField0_ |= 0x00000004;
        sourceDevice_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional uint32 sourceDevice = 7;</code>
       */
      public Builder clearSourceDevice() {
        bitField0_ = (bitField0_ & ~0x00000004);
        sourceDevice_ = 0;
        onChanged();
        return this;
      }

      // required uint64 timestamp = 5;
      private long timestamp_ ;
      /**
       * <code>required uint64 timestamp = 5;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasTimestamp() {
        return ((bitField0_ & 0x00000008) == 0x00000008);
      }
      /**
       * <code>required uint64 timestamp = 5;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public long getTimestamp() {
        return timestamp_;
      }
      /**
       * <code>required uint64 timestamp = 5;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setTimestamp(long value) {
        bitField0_ |= 0x00000008;
        timestamp_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required uint64 timestamp = 5;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearTimestamp() {
        bitField0_ = (bitField0_ & ~0x00000008);
        timestamp_ = 0L;
        onChanged();
        return this;
      }

      // optional bytes content = 8;
      private com.google.protobuf.ByteString content_ = com.google.protobuf.ByteString.EMPTY;
      /**
       * <code>optional bytes content = 8;</code>
       */
      public boolean hasContent() {
        return ((bitField0_ & 0x00000010) == 0x00000010);
      }
      /**
       * <code>optional bytes content = 8;</code>
       */
      public com.google.protobuf.ByteString getContent() {
        return content_;
      }
      /**
       * <code>optional bytes content = 8;</code>
       */
      public Builder setContent(com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000010;
        content_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional bytes content = 8;</code>
       */
      public Builder clearContent() {
        bitField0_ = (bitField0_ & ~0x00000010);
        content_ = getDefaultInstance().getContent();
        onChanged();
        return this;
      }

      // optional uint64 serverTimestamp = 10;
      private long serverTimestamp_ ;
      /**
       * <code>optional uint64 serverTimestamp = 10;</code>
       */
      public boolean hasServerTimestamp() {
        return ((bitField0_ & 0x00000020) == 0x00000020);
      }
      /**
       * <code>optional uint64 serverTimestamp = 10;</code>
       */
      public long getServerTimestamp() {
        return serverTimestamp_;
      }
      /**
       * <code>optional uint64 serverTimestamp = 10;</code>
       */
      public Builder setServerTimestamp(long value) {
        bitField0_ |= 0x00000020;
        serverTimestamp_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional uint64 serverTimestamp = 10;</code>
       */
      public Builder clearServerTimestamp() {
        bitField0_ = (bitField0_ & ~0x00000020);
        serverTimestamp_ = 0L;
        onChanged();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.Envelope)
    }

    static {
      defaultInstance = new Envelope(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.Envelope)
  }

  public interface TypingMessageOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // required uint64 timestamp = 1;
    /**
     * <code>required uint64 timestamp = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasTimestamp();
    /**
     * <code>required uint64 timestamp = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    long getTimestamp();

    // required .signalservice.TypingMessage.Action action = 2;
    /**
     * <code>required .signalservice.TypingMessage.Action action = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasAction();
    /**
     * <code>required .signalservice.TypingMessage.Action action = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Action getAction();
  }
  /**
   * Protobuf type {@code signalservice.TypingMessage}
   */
  public static final class TypingMessage extends
      com.google.protobuf.GeneratedMessage
      implements TypingMessageOrBuilder {
    // Use TypingMessage.newBuilder() to construct.
    private TypingMessage(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private TypingMessage(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final TypingMessage defaultInstance;
    public static TypingMessage getDefaultInstance() {
      return defaultInstance;
    }

    public TypingMessage getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private TypingMessage(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 8: {
              bitField0_ |= 0x00000001;
              timestamp_ = input.readUInt64();
              break;
            }
            case 16: {
              int rawValue = input.readEnum();
              org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Action value = org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Action.valueOf(rawValue);
              if (value == null) {
                unknownFields.mergeVarintField(2, rawValue);
              } else {
                bitField0_ |= 0x00000002;
                action_ = value;
              }
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_TypingMessage_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_TypingMessage_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.TypingMessage.class, org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Builder.class);
    }

    public static com.google.protobuf.Parser<TypingMessage> PARSER =
        new com.google.protobuf.AbstractParser<TypingMessage>() {
      public TypingMessage parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new TypingMessage(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<TypingMessage> getParserForType() {
      return PARSER;
    }

    /**
     * Protobuf enum {@code signalservice.TypingMessage.Action}
     */
    public enum Action
        implements com.google.protobuf.ProtocolMessageEnum {
      /**
       * <code>STARTED = 0;</code>
       */
      STARTED(0, 0),
      /**
       * <code>STOPPED = 1;</code>
       */
      STOPPED(1, 1),
      ;

      /**
       * <code>STARTED = 0;</code>
       */
      public static final int STARTED_VALUE = 0;
      /**
       * <code>STOPPED = 1;</code>
       */
      public static final int STOPPED_VALUE = 1;


      public final int getNumber() { return value; }

      public static Action valueOf(int value) {
        switch (value) {
          case 0: return STARTED;
          case 1: return STOPPED;
          default: return null;
        }
      }

      public static com.google.protobuf.Internal.EnumLiteMap<Action>
          internalGetValueMap() {
        return internalValueMap;
      }
      private static com.google.protobuf.Internal.EnumLiteMap<Action>
          internalValueMap =
            new com.google.protobuf.Internal.EnumLiteMap<Action>() {
              public Action findValueByNumber(int number) {
                return Action.valueOf(number);
              }
            };

      public final com.google.protobuf.Descriptors.EnumValueDescriptor
          getValueDescriptor() {
        return getDescriptor().getValues().get(index);
      }
      public final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptorForType() {
        return getDescriptor();
      }
      public static final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.TypingMessage.getDescriptor().getEnumTypes().get(0);
      }

      private static final Action[] VALUES = values();

      public static Action valueOf(
          com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
        if (desc.getType() != getDescriptor()) {
          throw new java.lang.IllegalArgumentException(
            "EnumValueDescriptor is not for this type.");
        }
        return VALUES[desc.getIndex()];
      }

      private final int index;
      private final int value;

      private Action(int index, int value) {
        this.index = index;
        this.value = value;
      }

      // @@protoc_insertion_point(enum_scope:signalservice.TypingMessage.Action)
    }

    private int bitField0_;
    // required uint64 timestamp = 1;
    public static final int TIMESTAMP_FIELD_NUMBER = 1;
    private long timestamp_;
    /**
     * <code>required uint64 timestamp = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasTimestamp() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>required uint64 timestamp = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public long getTimestamp() {
      return timestamp_;
    }

    // required .signalservice.TypingMessage.Action action = 2;
    public static final int ACTION_FIELD_NUMBER = 2;
    private org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Action action_;
    /**
     * <code>required .signalservice.TypingMessage.Action action = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasAction() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>required .signalservice.TypingMessage.Action action = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Action getAction() {
      return action_;
    }

    private void initFields() {
      timestamp_ = 0L;
      action_ = org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Action.STARTED;
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      if (!hasTimestamp()) {
        memoizedIsInitialized = 0;
        return false;
      }
      if (!hasAction()) {
        memoizedIsInitialized = 0;
        return false;
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeUInt64(1, timestamp_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeEnum(2, action_.getNumber());
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt64Size(1, timestamp_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeEnumSize(2, action_.getNumber());
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.TypingMessage parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.TypingMessage parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.TypingMessage parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.TypingMessage parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.TypingMessage parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.TypingMessage parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.TypingMessage parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.TypingMessage parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.TypingMessage parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.TypingMessage parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.TypingMessage prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.TypingMessage}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.TypingMessageOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_TypingMessage_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_TypingMessage_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.TypingMessage.class, org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.TypingMessage.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        timestamp_ = 0L;
        bitField0_ = (bitField0_ & ~0x00000001);
        action_ = org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Action.STARTED;
        bitField0_ = (bitField0_ & ~0x00000002);
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_TypingMessage_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.TypingMessage getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.TypingMessage.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.TypingMessage build() {
        org.session.libsignal.protos.SignalServiceProtos.TypingMessage result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.TypingMessage buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.TypingMessage result = new org.session.libsignal.protos.SignalServiceProtos.TypingMessage(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.timestamp_ = timestamp_;
        if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
          to_bitField0_ |= 0x00000002;
        }
        result.action_ = action_;
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.TypingMessage) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.TypingMessage)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.TypingMessage other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.TypingMessage.getDefaultInstance()) return this;
        if (other.hasTimestamp()) {
          setTimestamp(other.getTimestamp());
        }
        if (other.hasAction()) {
          setAction(other.getAction());
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        if (!hasTimestamp()) {
          
          return false;
        }
        if (!hasAction()) {
          
          return false;
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.TypingMessage parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.TypingMessage) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // required uint64 timestamp = 1;
      private long timestamp_ ;
      /**
       * <code>required uint64 timestamp = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasTimestamp() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required uint64 timestamp = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public long getTimestamp() {
        return timestamp_;
      }
      /**
       * <code>required uint64 timestamp = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setTimestamp(long value) {
        bitField0_ |= 0x00000001;
        timestamp_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required uint64 timestamp = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearTimestamp() {
        bitField0_ = (bitField0_ & ~0x00000001);
        timestamp_ = 0L;
        onChanged();
        return this;
      }

      // required .signalservice.TypingMessage.Action action = 2;
      private org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Action action_ = org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Action.STARTED;
      /**
       * <code>required .signalservice.TypingMessage.Action action = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasAction() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>required .signalservice.TypingMessage.Action action = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Action getAction() {
        return action_;
      }
      /**
       * <code>required .signalservice.TypingMessage.Action action = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setAction(org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Action value) {
        if (value == null) {
          throw new NullPointerException();
        }
        bitField0_ |= 0x00000002;
        action_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required .signalservice.TypingMessage.Action action = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearAction() {
        bitField0_ = (bitField0_ & ~0x00000002);
        action_ = org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Action.STARTED;
        onChanged();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.TypingMessage)
    }

    static {
      defaultInstance = new TypingMessage(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.TypingMessage)
  }

  public interface UnsendRequestOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // required uint64 timestamp = 1;
    /**
     * <code>required uint64 timestamp = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasTimestamp();
    /**
     * <code>required uint64 timestamp = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    long getTimestamp();

    // required string author = 2;
    /**
     * <code>required string author = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasAuthor();
    /**
     * <code>required string author = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    java.lang.String getAuthor();
    /**
     * <code>required string author = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    com.google.protobuf.ByteString
        getAuthorBytes();
  }
  /**
   * Protobuf type {@code signalservice.UnsendRequest}
   */
  public static final class UnsendRequest extends
      com.google.protobuf.GeneratedMessage
      implements UnsendRequestOrBuilder {
    // Use UnsendRequest.newBuilder() to construct.
    private UnsendRequest(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private UnsendRequest(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final UnsendRequest defaultInstance;
    public static UnsendRequest getDefaultInstance() {
      return defaultInstance;
    }

    public UnsendRequest getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private UnsendRequest(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 8: {
              bitField0_ |= 0x00000001;
              timestamp_ = input.readUInt64();
              break;
            }
            case 18: {
              bitField0_ |= 0x00000002;
              author_ = input.readBytes();
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_UnsendRequest_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_UnsendRequest_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.class, org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.Builder.class);
    }

    public static com.google.protobuf.Parser<UnsendRequest> PARSER =
        new com.google.protobuf.AbstractParser<UnsendRequest>() {
      public UnsendRequest parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new UnsendRequest(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<UnsendRequest> getParserForType() {
      return PARSER;
    }

    private int bitField0_;
    // required uint64 timestamp = 1;
    public static final int TIMESTAMP_FIELD_NUMBER = 1;
    private long timestamp_;
    /**
     * <code>required uint64 timestamp = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasTimestamp() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>required uint64 timestamp = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public long getTimestamp() {
      return timestamp_;
    }

    // required string author = 2;
    public static final int AUTHOR_FIELD_NUMBER = 2;
    private java.lang.Object author_;
    /**
     * <code>required string author = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasAuthor() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>required string author = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public java.lang.String getAuthor() {
      java.lang.Object ref = author_;
      if (ref instanceof java.lang.String) {
        return (java.lang.String) ref;
      } else {
        com.google.protobuf.ByteString bs = 
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          author_ = s;
        }
        return s;
      }
    }
    /**
     * <code>required string author = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public com.google.protobuf.ByteString
        getAuthorBytes() {
      java.lang.Object ref = author_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        author_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    private void initFields() {
      timestamp_ = 0L;
      author_ = "";
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      if (!hasTimestamp()) {
        memoizedIsInitialized = 0;
        return false;
      }
      if (!hasAuthor()) {
        memoizedIsInitialized = 0;
        return false;
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeUInt64(1, timestamp_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeBytes(2, getAuthorBytes());
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt64Size(1, timestamp_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(2, getAuthorBytes());
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.UnsendRequest parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.UnsendRequest parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.UnsendRequest parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.UnsendRequest parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.UnsendRequest parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.UnsendRequest parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.UnsendRequest parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.UnsendRequest parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.UnsendRequest parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.UnsendRequest parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.UnsendRequest prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.UnsendRequest}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.UnsendRequestOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_UnsendRequest_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_UnsendRequest_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.class, org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        timestamp_ = 0L;
        bitField0_ = (bitField0_ & ~0x00000001);
        author_ = "";
        bitField0_ = (bitField0_ & ~0x00000002);
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_UnsendRequest_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.UnsendRequest getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.UnsendRequest build() {
        org.session.libsignal.protos.SignalServiceProtos.UnsendRequest result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.UnsendRequest buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.UnsendRequest result = new org.session.libsignal.protos.SignalServiceProtos.UnsendRequest(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.timestamp_ = timestamp_;
        if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
          to_bitField0_ |= 0x00000002;
        }
        result.author_ = author_;
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.UnsendRequest) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.UnsendRequest)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.UnsendRequest other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.getDefaultInstance()) return this;
        if (other.hasTimestamp()) {
          setTimestamp(other.getTimestamp());
        }
        if (other.hasAuthor()) {
          bitField0_ |= 0x00000002;
          author_ = other.author_;
          onChanged();
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        if (!hasTimestamp()) {
          
          return false;
        }
        if (!hasAuthor()) {
          
          return false;
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.UnsendRequest parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.UnsendRequest) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // required uint64 timestamp = 1;
      private long timestamp_ ;
      /**
       * <code>required uint64 timestamp = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasTimestamp() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required uint64 timestamp = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public long getTimestamp() {
        return timestamp_;
      }
      /**
       * <code>required uint64 timestamp = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setTimestamp(long value) {
        bitField0_ |= 0x00000001;
        timestamp_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required uint64 timestamp = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearTimestamp() {
        bitField0_ = (bitField0_ & ~0x00000001);
        timestamp_ = 0L;
        onChanged();
        return this;
      }

      // required string author = 2;
      private java.lang.Object author_ = "";
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasAuthor() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public java.lang.String getAuthor() {
        java.lang.Object ref = author_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          author_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public com.google.protobuf.ByteString
          getAuthorBytes() {
        java.lang.Object ref = author_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          author_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setAuthor(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
        author_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearAuthor() {
        bitField0_ = (bitField0_ & ~0x00000002);
        author_ = getDefaultInstance().getAuthor();
        onChanged();
        return this;
      }
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setAuthorBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
        author_ = value;
        onChanged();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.UnsendRequest)
    }

    static {
      defaultInstance = new UnsendRequest(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.UnsendRequest)
  }

  public interface ContentOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // optional .signalservice.DataMessage dataMessage = 1;
    /**
     * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
     */
    boolean hasDataMessage();
    /**
     * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage getDataMessage();
    /**
     * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessageOrBuilder getDataMessageOrBuilder();

    // optional .signalservice.CallMessage callMessage = 3;
    /**
     * <code>optional .signalservice.CallMessage callMessage = 3;</code>
     */
    boolean hasCallMessage();
    /**
     * <code>optional .signalservice.CallMessage callMessage = 3;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.CallMessage getCallMessage();
    /**
     * <code>optional .signalservice.CallMessage callMessage = 3;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.CallMessageOrBuilder getCallMessageOrBuilder();

    // optional .signalservice.ReceiptMessage receiptMessage = 5;
    /**
     * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
     */
    boolean hasReceiptMessage();
    /**
     * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage getReceiptMessage();
    /**
     * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.ReceiptMessageOrBuilder getReceiptMessageOrBuilder();

    // optional .signalservice.TypingMessage typingMessage = 6;
    /**
     * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
     */
    boolean hasTypingMessage();
    /**
     * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.TypingMessage getTypingMessage();
    /**
     * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.TypingMessageOrBuilder getTypingMessageOrBuilder();

    // optional .signalservice.ConfigurationMessage configurationMessage = 7;
    /**
     * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
     */
    boolean hasConfigurationMessage();
    /**
     * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage getConfigurationMessage();
    /**
     * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessageOrBuilder getConfigurationMessageOrBuilder();

    // optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;
    /**
     * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
     */
    boolean hasDataExtractionNotification();
    /**
     * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification getDataExtractionNotification();
    /**
     * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotificationOrBuilder getDataExtractionNotificationOrBuilder();

    // optional .signalservice.UnsendRequest unsendRequest = 9;
    /**
     * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
     */
    boolean hasUnsendRequest();
    /**
     * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.UnsendRequest getUnsendRequest();
    /**
     * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.UnsendRequestOrBuilder getUnsendRequestOrBuilder();

    // optional .signalservice.MessageRequestResponse messageRequestResponse = 10;
    /**
     * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
     */
    boolean hasMessageRequestResponse();
    /**
     * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse getMessageRequestResponse();
    /**
     * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponseOrBuilder getMessageRequestResponseOrBuilder();
  }
  /**
   * Protobuf type {@code signalservice.Content}
   */
  public static final class Content extends
      com.google.protobuf.GeneratedMessage
      implements ContentOrBuilder {
    // Use Content.newBuilder() to construct.
    private Content(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private Content(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final Content defaultInstance;
    public static Content getDefaultInstance() {
      return defaultInstance;
    }

    public Content getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private Content(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 10: {
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.Builder subBuilder = null;
              if (((bitField0_ & 0x00000001) == 0x00000001)) {
                subBuilder = dataMessage_.toBuilder();
              }
              dataMessage_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(dataMessage_);
                dataMessage_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000001;
              break;
            }
            case 26: {
              org.session.libsignal.protos.SignalServiceProtos.CallMessage.Builder subBuilder = null;
              if (((bitField0_ & 0x00000002) == 0x00000002)) {
                subBuilder = callMessage_.toBuilder();
              }
              callMessage_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.CallMessage.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(callMessage_);
                callMessage_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000002;
              break;
            }
            case 42: {
              org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Builder subBuilder = null;
              if (((bitField0_ & 0x00000004) == 0x00000004)) {
                subBuilder = receiptMessage_.toBuilder();
              }
              receiptMessage_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(receiptMessage_);
                receiptMessage_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000004;
              break;
            }
            case 50: {
              org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Builder subBuilder = null;
              if (((bitField0_ & 0x00000008) == 0x00000008)) {
                subBuilder = typingMessage_.toBuilder();
              }
              typingMessage_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.TypingMessage.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(typingMessage_);
                typingMessage_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000008;
              break;
            }
            case 58: {
              org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Builder subBuilder = null;
              if (((bitField0_ & 0x00000010) == 0x00000010)) {
                subBuilder = configurationMessage_.toBuilder();
              }
              configurationMessage_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(configurationMessage_);
                configurationMessage_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000010;
              break;
            }
            case 66: {
              org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Builder subBuilder = null;
              if (((bitField0_ & 0x00000020) == 0x00000020)) {
                subBuilder = dataExtractionNotification_.toBuilder();
              }
              dataExtractionNotification_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(dataExtractionNotification_);
                dataExtractionNotification_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000020;
              break;
            }
            case 74: {
              org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.Builder subBuilder = null;
              if (((bitField0_ & 0x00000040) == 0x00000040)) {
                subBuilder = unsendRequest_.toBuilder();
              }
              unsendRequest_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(unsendRequest_);
                unsendRequest_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000040;
              break;
            }
            case 82: {
              org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.Builder subBuilder = null;
              if (((bitField0_ & 0x00000080) == 0x00000080)) {
                subBuilder = messageRequestResponse_.toBuilder();
              }
              messageRequestResponse_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(messageRequestResponse_);
                messageRequestResponse_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000080;
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_Content_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_Content_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.Content.class, org.session.libsignal.protos.SignalServiceProtos.Content.Builder.class);
    }

    public static com.google.protobuf.Parser<Content> PARSER =
        new com.google.protobuf.AbstractParser<Content>() {
      public Content parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new Content(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<Content> getParserForType() {
      return PARSER;
    }

    private int bitField0_;
    // optional .signalservice.DataMessage dataMessage = 1;
    public static final int DATAMESSAGE_FIELD_NUMBER = 1;
    private org.session.libsignal.protos.SignalServiceProtos.DataMessage dataMessage_;
    /**
     * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
     */
    public boolean hasDataMessage() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage getDataMessage() {
      return dataMessage_;
    }
    /**
     * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessageOrBuilder getDataMessageOrBuilder() {
      return dataMessage_;
    }

    // optional .signalservice.CallMessage callMessage = 3;
    public static final int CALLMESSAGE_FIELD_NUMBER = 3;
    private org.session.libsignal.protos.SignalServiceProtos.CallMessage callMessage_;
    /**
     * <code>optional .signalservice.CallMessage callMessage = 3;</code>
     */
    public boolean hasCallMessage() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>optional .signalservice.CallMessage callMessage = 3;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.CallMessage getCallMessage() {
      return callMessage_;
    }
    /**
     * <code>optional .signalservice.CallMessage callMessage = 3;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.CallMessageOrBuilder getCallMessageOrBuilder() {
      return callMessage_;
    }

    // optional .signalservice.ReceiptMessage receiptMessage = 5;
    public static final int RECEIPTMESSAGE_FIELD_NUMBER = 5;
    private org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage receiptMessage_;
    /**
     * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
     */
    public boolean hasReceiptMessage() {
      return ((bitField0_ & 0x00000004) == 0x00000004);
    }
    /**
     * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage getReceiptMessage() {
      return receiptMessage_;
    }
    /**
     * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.ReceiptMessageOrBuilder getReceiptMessageOrBuilder() {
      return receiptMessage_;
    }

    // optional .signalservice.TypingMessage typingMessage = 6;
    public static final int TYPINGMESSAGE_FIELD_NUMBER = 6;
    private org.session.libsignal.protos.SignalServiceProtos.TypingMessage typingMessage_;
    /**
     * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
     */
    public boolean hasTypingMessage() {
      return ((bitField0_ & 0x00000008) == 0x00000008);
    }
    /**
     * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.TypingMessage getTypingMessage() {
      return typingMessage_;
    }
    /**
     * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.TypingMessageOrBuilder getTypingMessageOrBuilder() {
      return typingMessage_;
    }

    // optional .signalservice.ConfigurationMessage configurationMessage = 7;
    public static final int CONFIGURATIONMESSAGE_FIELD_NUMBER = 7;
    private org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage configurationMessage_;
    /**
     * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
     */
    public boolean hasConfigurationMessage() {
      return ((bitField0_ & 0x00000010) == 0x00000010);
    }
    /**
     * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage getConfigurationMessage() {
      return configurationMessage_;
    }
    /**
     * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessageOrBuilder getConfigurationMessageOrBuilder() {
      return configurationMessage_;
    }

    // optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;
    public static final int DATAEXTRACTIONNOTIFICATION_FIELD_NUMBER = 8;
    private org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification dataExtractionNotification_;
    /**
     * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
     */
    public boolean hasDataExtractionNotification() {
      return ((bitField0_ & 0x00000020) == 0x00000020);
    }
    /**
     * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification getDataExtractionNotification() {
      return dataExtractionNotification_;
    }
    /**
     * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotificationOrBuilder getDataExtractionNotificationOrBuilder() {
      return dataExtractionNotification_;
    }

    // optional .signalservice.UnsendRequest unsendRequest = 9;
    public static final int UNSENDREQUEST_FIELD_NUMBER = 9;
    private org.session.libsignal.protos.SignalServiceProtos.UnsendRequest unsendRequest_;
    /**
     * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
     */
    public boolean hasUnsendRequest() {
      return ((bitField0_ & 0x00000040) == 0x00000040);
    }
    /**
     * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.UnsendRequest getUnsendRequest() {
      return unsendRequest_;
    }
    /**
     * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.UnsendRequestOrBuilder getUnsendRequestOrBuilder() {
      return unsendRequest_;
    }

    // optional .signalservice.MessageRequestResponse messageRequestResponse = 10;
    public static final int MESSAGEREQUESTRESPONSE_FIELD_NUMBER = 10;
    private org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse messageRequestResponse_;
    /**
     * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
     */
    public boolean hasMessageRequestResponse() {
      return ((bitField0_ & 0x00000080) == 0x00000080);
    }
    /**
     * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse getMessageRequestResponse() {
      return messageRequestResponse_;
    }
    /**
     * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponseOrBuilder getMessageRequestResponseOrBuilder() {
      return messageRequestResponse_;
    }

    private void initFields() {
      dataMessage_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.getDefaultInstance();
      callMessage_ = org.session.libsignal.protos.SignalServiceProtos.CallMessage.getDefaultInstance();
      receiptMessage_ = org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.getDefaultInstance();
      typingMessage_ = org.session.libsignal.protos.SignalServiceProtos.TypingMessage.getDefaultInstance();
      configurationMessage_ = org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.getDefaultInstance();
      dataExtractionNotification_ = org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.getDefaultInstance();
      unsendRequest_ = org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.getDefaultInstance();
      messageRequestResponse_ = org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.getDefaultInstance();
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      if (hasDataMessage()) {
        if (!getDataMessage().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      if (hasCallMessage()) {
        if (!getCallMessage().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      if (hasReceiptMessage()) {
        if (!getReceiptMessage().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      if (hasTypingMessage()) {
        if (!getTypingMessage().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      if (hasConfigurationMessage()) {
        if (!getConfigurationMessage().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      if (hasDataExtractionNotification()) {
        if (!getDataExtractionNotification().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      if (hasUnsendRequest()) {
        if (!getUnsendRequest().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      if (hasMessageRequestResponse()) {
        if (!getMessageRequestResponse().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeMessage(1, dataMessage_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeMessage(3, callMessage_);
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        output.writeMessage(5, receiptMessage_);
      }
      if (((bitField0_ & 0x00000008) == 0x00000008)) {
        output.writeMessage(6, typingMessage_);
      }
      if (((bitField0_ & 0x00000010) == 0x00000010)) {
        output.writeMessage(7, configurationMessage_);
      }
      if (((bitField0_ & 0x00000020) == 0x00000020)) {
        output.writeMessage(8, dataExtractionNotification_);
      }
      if (((bitField0_ & 0x00000040) == 0x00000040)) {
        output.writeMessage(9, unsendRequest_);
      }
      if (((bitField0_ & 0x00000080) == 0x00000080)) {
        output.writeMessage(10, messageRequestResponse_);
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(1, dataMessage_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(3, callMessage_);
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(5, receiptMessage_);
      }
      if (((bitField0_ & 0x00000008) == 0x00000008)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(6, typingMessage_);
      }
      if (((bitField0_ & 0x00000010) == 0x00000010)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(7, configurationMessage_);
      }
      if (((bitField0_ & 0x00000020) == 0x00000020)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(8, dataExtractionNotification_);
      }
      if (((bitField0_ & 0x00000040) == 0x00000040)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(9, unsendRequest_);
      }
      if (((bitField0_ & 0x00000080) == 0x00000080)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(10, messageRequestResponse_);
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.Content parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Content parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Content parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Content parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Content parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Content parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Content parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Content parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Content parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.Content parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.Content prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.Content}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.ContentOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_Content_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_Content_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.Content.class, org.session.libsignal.protos.SignalServiceProtos.Content.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.Content.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
          getDataMessageFieldBuilder();
          getCallMessageFieldBuilder();
          getReceiptMessageFieldBuilder();
          getTypingMessageFieldBuilder();
          getConfigurationMessageFieldBuilder();
          getDataExtractionNotificationFieldBuilder();
          getUnsendRequestFieldBuilder();
          getMessageRequestResponseFieldBuilder();
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        if (dataMessageBuilder_ == null) {
          dataMessage_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.getDefaultInstance();
        } else {
          dataMessageBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000001);
        if (callMessageBuilder_ == null) {
          callMessage_ = org.session.libsignal.protos.SignalServiceProtos.CallMessage.getDefaultInstance();
        } else {
          callMessageBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000002);
        if (receiptMessageBuilder_ == null) {
          receiptMessage_ = org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.getDefaultInstance();
        } else {
          receiptMessageBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000004);
        if (typingMessageBuilder_ == null) {
          typingMessage_ = org.session.libsignal.protos.SignalServiceProtos.TypingMessage.getDefaultInstance();
        } else {
          typingMessageBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000008);
        if (configurationMessageBuilder_ == null) {
          configurationMessage_ = org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.getDefaultInstance();
        } else {
          configurationMessageBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000010);
        if (dataExtractionNotificationBuilder_ == null) {
          dataExtractionNotification_ = org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.getDefaultInstance();
        } else {
          dataExtractionNotificationBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000020);
        if (unsendRequestBuilder_ == null) {
          unsendRequest_ = org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.getDefaultInstance();
        } else {
          unsendRequestBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000040);
        if (messageRequestResponseBuilder_ == null) {
          messageRequestResponse_ = org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.getDefaultInstance();
        } else {
          messageRequestResponseBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000080);
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_Content_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.Content getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.Content.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.Content build() {
        org.session.libsignal.protos.SignalServiceProtos.Content result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.Content buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.Content result = new org.session.libsignal.protos.SignalServiceProtos.Content(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        if (dataMessageBuilder_ == null) {
          result.dataMessage_ = dataMessage_;
        } else {
          result.dataMessage_ = dataMessageBuilder_.build();
        }
        if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
          to_bitField0_ |= 0x00000002;
        }
        if (callMessageBuilder_ == null) {
          result.callMessage_ = callMessage_;
        } else {
          result.callMessage_ = callMessageBuilder_.build();
        }
        if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
          to_bitField0_ |= 0x00000004;
        }
        if (receiptMessageBuilder_ == null) {
          result.receiptMessage_ = receiptMessage_;
        } else {
          result.receiptMessage_ = receiptMessageBuilder_.build();
        }
        if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
          to_bitField0_ |= 0x00000008;
        }
        if (typingMessageBuilder_ == null) {
          result.typingMessage_ = typingMessage_;
        } else {
          result.typingMessage_ = typingMessageBuilder_.build();
        }
        if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
          to_bitField0_ |= 0x00000010;
        }
        if (configurationMessageBuilder_ == null) {
          result.configurationMessage_ = configurationMessage_;
        } else {
          result.configurationMessage_ = configurationMessageBuilder_.build();
        }
        if (((from_bitField0_ & 0x00000020) == 0x00000020)) {
          to_bitField0_ |= 0x00000020;
        }
        if (dataExtractionNotificationBuilder_ == null) {
          result.dataExtractionNotification_ = dataExtractionNotification_;
        } else {
          result.dataExtractionNotification_ = dataExtractionNotificationBuilder_.build();
        }
        if (((from_bitField0_ & 0x00000040) == 0x00000040)) {
          to_bitField0_ |= 0x00000040;
        }
        if (unsendRequestBuilder_ == null) {
          result.unsendRequest_ = unsendRequest_;
        } else {
          result.unsendRequest_ = unsendRequestBuilder_.build();
        }
        if (((from_bitField0_ & 0x00000080) == 0x00000080)) {
          to_bitField0_ |= 0x00000080;
        }
        if (messageRequestResponseBuilder_ == null) {
          result.messageRequestResponse_ = messageRequestResponse_;
        } else {
          result.messageRequestResponse_ = messageRequestResponseBuilder_.build();
        }
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.Content) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.Content)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.Content other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.Content.getDefaultInstance()) return this;
        if (other.hasDataMessage()) {
          mergeDataMessage(other.getDataMessage());
        }
        if (other.hasCallMessage()) {
          mergeCallMessage(other.getCallMessage());
        }
        if (other.hasReceiptMessage()) {
          mergeReceiptMessage(other.getReceiptMessage());
        }
        if (other.hasTypingMessage()) {
          mergeTypingMessage(other.getTypingMessage());
        }
        if (other.hasConfigurationMessage()) {
          mergeConfigurationMessage(other.getConfigurationMessage());
        }
        if (other.hasDataExtractionNotification()) {
          mergeDataExtractionNotification(other.getDataExtractionNotification());
        }
        if (other.hasUnsendRequest()) {
          mergeUnsendRequest(other.getUnsendRequest());
        }
        if (other.hasMessageRequestResponse()) {
          mergeMessageRequestResponse(other.getMessageRequestResponse());
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        if (hasDataMessage()) {
          if (!getDataMessage().isInitialized()) {
            
            return false;
          }
        }
        if (hasCallMessage()) {
          if (!getCallMessage().isInitialized()) {
            
            return false;
          }
        }
        if (hasReceiptMessage()) {
          if (!getReceiptMessage().isInitialized()) {
            
            return false;
          }
        }
        if (hasTypingMessage()) {
          if (!getTypingMessage().isInitialized()) {
            
            return false;
          }
        }
        if (hasConfigurationMessage()) {
          if (!getConfigurationMessage().isInitialized()) {
            
            return false;
          }
        }
        if (hasDataExtractionNotification()) {
          if (!getDataExtractionNotification().isInitialized()) {
            
            return false;
          }
        }
        if (hasUnsendRequest()) {
          if (!getUnsendRequest().isInitialized()) {
            
            return false;
          }
        }
        if (hasMessageRequestResponse()) {
          if (!getMessageRequestResponse().isInitialized()) {
            
            return false;
          }
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.Content parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.Content) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // optional .signalservice.DataMessage dataMessage = 1;
      private org.session.libsignal.protos.SignalServiceProtos.DataMessage dataMessage_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessageOrBuilder> dataMessageBuilder_;
      /**
       * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
       */
      public boolean hasDataMessage() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage getDataMessage() {
        if (dataMessageBuilder_ == null) {
          return dataMessage_;
        } else {
          return dataMessageBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
       */
      public Builder setDataMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage value) {
        if (dataMessageBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          dataMessage_ = value;
          onChanged();
        } else {
          dataMessageBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000001;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
       */
      public Builder setDataMessage(
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Builder builderForValue) {
        if (dataMessageBuilder_ == null) {
          dataMessage_ = builderForValue.build();
          onChanged();
        } else {
          dataMessageBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000001;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
       */
      public Builder mergeDataMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage value) {
        if (dataMessageBuilder_ == null) {
          if (((bitField0_ & 0x00000001) == 0x00000001) &&
              dataMessage_ != org.session.libsignal.protos.SignalServiceProtos.DataMessage.getDefaultInstance()) {
            dataMessage_ =
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.newBuilder(dataMessage_).mergeFrom(value).buildPartial();
          } else {
            dataMessage_ = value;
          }
          onChanged();
        } else {
          dataMessageBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000001;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
       */
      public Builder clearDataMessage() {
        if (dataMessageBuilder_ == null) {
          dataMessage_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.getDefaultInstance();
          onChanged();
        } else {
          dataMessageBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000001);
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Builder getDataMessageBuilder() {
        bitField0_ |= 0x00000001;
        onChanged();
        return getDataMessageFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessageOrBuilder getDataMessageOrBuilder() {
        if (dataMessageBuilder_ != null) {
          return dataMessageBuilder_.getMessageOrBuilder();
        } else {
          return dataMessage_;
        }
      }
      /**
       * <code>optional .signalservice.DataMessage dataMessage = 1;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessageOrBuilder> 
          getDataMessageFieldBuilder() {
        if (dataMessageBuilder_ == null) {
          dataMessageBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.DataMessage, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessageOrBuilder>(
                  dataMessage_,
                  getParentForChildren(),
                  isClean());
          dataMessage_ = null;
        }
        return dataMessageBuilder_;
      }

      // optional .signalservice.CallMessage callMessage = 3;
      private org.session.libsignal.protos.SignalServiceProtos.CallMessage callMessage_ = org.session.libsignal.protos.SignalServiceProtos.CallMessage.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.CallMessage, org.session.libsignal.protos.SignalServiceProtos.CallMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.CallMessageOrBuilder> callMessageBuilder_;
      /**
       * <code>optional .signalservice.CallMessage callMessage = 3;</code>
       */
      public boolean hasCallMessage() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>optional .signalservice.CallMessage callMessage = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.CallMessage getCallMessage() {
        if (callMessageBuilder_ == null) {
          return callMessage_;
        } else {
          return callMessageBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.CallMessage callMessage = 3;</code>
       */
      public Builder setCallMessage(org.session.libsignal.protos.SignalServiceProtos.CallMessage value) {
        if (callMessageBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          callMessage_ = value;
          onChanged();
        } else {
          callMessageBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000002;
        return this;
      }
      /**
       * <code>optional .signalservice.CallMessage callMessage = 3;</code>
       */
      public Builder setCallMessage(
          org.session.libsignal.protos.SignalServiceProtos.CallMessage.Builder builderForValue) {
        if (callMessageBuilder_ == null) {
          callMessage_ = builderForValue.build();
          onChanged();
        } else {
          callMessageBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000002;
        return this;
      }
      /**
       * <code>optional .signalservice.CallMessage callMessage = 3;</code>
       */
      public Builder mergeCallMessage(org.session.libsignal.protos.SignalServiceProtos.CallMessage value) {
        if (callMessageBuilder_ == null) {
          if (((bitField0_ & 0x00000002) == 0x00000002) &&
              callMessage_ != org.session.libsignal.protos.SignalServiceProtos.CallMessage.getDefaultInstance()) {
            callMessage_ =
              org.session.libsignal.protos.SignalServiceProtos.CallMessage.newBuilder(callMessage_).mergeFrom(value).buildPartial();
          } else {
            callMessage_ = value;
          }
          onChanged();
        } else {
          callMessageBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000002;
        return this;
      }
      /**
       * <code>optional .signalservice.CallMessage callMessage = 3;</code>
       */
      public Builder clearCallMessage() {
        if (callMessageBuilder_ == null) {
          callMessage_ = org.session.libsignal.protos.SignalServiceProtos.CallMessage.getDefaultInstance();
          onChanged();
        } else {
          callMessageBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000002);
        return this;
      }
      /**
       * <code>optional .signalservice.CallMessage callMessage = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.CallMessage.Builder getCallMessageBuilder() {
        bitField0_ |= 0x00000002;
        onChanged();
        return getCallMessageFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.CallMessage callMessage = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.CallMessageOrBuilder getCallMessageOrBuilder() {
        if (callMessageBuilder_ != null) {
          return callMessageBuilder_.getMessageOrBuilder();
        } else {
          return callMessage_;
        }
      }
      /**
       * <code>optional .signalservice.CallMessage callMessage = 3;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.CallMessage, org.session.libsignal.protos.SignalServiceProtos.CallMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.CallMessageOrBuilder> 
          getCallMessageFieldBuilder() {
        if (callMessageBuilder_ == null) {
          callMessageBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.CallMessage, org.session.libsignal.protos.SignalServiceProtos.CallMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.CallMessageOrBuilder>(
                  callMessage_,
                  getParentForChildren(),
                  isClean());
          callMessage_ = null;
        }
        return callMessageBuilder_;
      }

      // optional .signalservice.ReceiptMessage receiptMessage = 5;
      private org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage receiptMessage_ = org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage, org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.ReceiptMessageOrBuilder> receiptMessageBuilder_;
      /**
       * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
       */
      public boolean hasReceiptMessage() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage getReceiptMessage() {
        if (receiptMessageBuilder_ == null) {
          return receiptMessage_;
        } else {
          return receiptMessageBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
       */
      public Builder setReceiptMessage(org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage value) {
        if (receiptMessageBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          receiptMessage_ = value;
          onChanged();
        } else {
          receiptMessageBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000004;
        return this;
      }
      /**
       * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
       */
      public Builder setReceiptMessage(
          org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Builder builderForValue) {
        if (receiptMessageBuilder_ == null) {
          receiptMessage_ = builderForValue.build();
          onChanged();
        } else {
          receiptMessageBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000004;
        return this;
      }
      /**
       * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
       */
      public Builder mergeReceiptMessage(org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage value) {
        if (receiptMessageBuilder_ == null) {
          if (((bitField0_ & 0x00000004) == 0x00000004) &&
              receiptMessage_ != org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.getDefaultInstance()) {
            receiptMessage_ =
              org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.newBuilder(receiptMessage_).mergeFrom(value).buildPartial();
          } else {
            receiptMessage_ = value;
          }
          onChanged();
        } else {
          receiptMessageBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000004;
        return this;
      }
      /**
       * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
       */
      public Builder clearReceiptMessage() {
        if (receiptMessageBuilder_ == null) {
          receiptMessage_ = org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.getDefaultInstance();
          onChanged();
        } else {
          receiptMessageBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000004);
        return this;
      }
      /**
       * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Builder getReceiptMessageBuilder() {
        bitField0_ |= 0x00000004;
        onChanged();
        return getReceiptMessageFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ReceiptMessageOrBuilder getReceiptMessageOrBuilder() {
        if (receiptMessageBuilder_ != null) {
          return receiptMessageBuilder_.getMessageOrBuilder();
        } else {
          return receiptMessage_;
        }
      }
      /**
       * <code>optional .signalservice.ReceiptMessage receiptMessage = 5;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage, org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.ReceiptMessageOrBuilder> 
          getReceiptMessageFieldBuilder() {
        if (receiptMessageBuilder_ == null) {
          receiptMessageBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage, org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.ReceiptMessageOrBuilder>(
                  receiptMessage_,
                  getParentForChildren(),
                  isClean());
          receiptMessage_ = null;
        }
        return receiptMessageBuilder_;
      }

      // optional .signalservice.TypingMessage typingMessage = 6;
      private org.session.libsignal.protos.SignalServiceProtos.TypingMessage typingMessage_ = org.session.libsignal.protos.SignalServiceProtos.TypingMessage.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.TypingMessage, org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.TypingMessageOrBuilder> typingMessageBuilder_;
      /**
       * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
       */
      public boolean hasTypingMessage() {
        return ((bitField0_ & 0x00000008) == 0x00000008);
      }
      /**
       * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.TypingMessage getTypingMessage() {
        if (typingMessageBuilder_ == null) {
          return typingMessage_;
        } else {
          return typingMessageBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
       */
      public Builder setTypingMessage(org.session.libsignal.protos.SignalServiceProtos.TypingMessage value) {
        if (typingMessageBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          typingMessage_ = value;
          onChanged();
        } else {
          typingMessageBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000008;
        return this;
      }
      /**
       * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
       */
      public Builder setTypingMessage(
          org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Builder builderForValue) {
        if (typingMessageBuilder_ == null) {
          typingMessage_ = builderForValue.build();
          onChanged();
        } else {
          typingMessageBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000008;
        return this;
      }
      /**
       * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
       */
      public Builder mergeTypingMessage(org.session.libsignal.protos.SignalServiceProtos.TypingMessage value) {
        if (typingMessageBuilder_ == null) {
          if (((bitField0_ & 0x00000008) == 0x00000008) &&
              typingMessage_ != org.session.libsignal.protos.SignalServiceProtos.TypingMessage.getDefaultInstance()) {
            typingMessage_ =
              org.session.libsignal.protos.SignalServiceProtos.TypingMessage.newBuilder(typingMessage_).mergeFrom(value).buildPartial();
          } else {
            typingMessage_ = value;
          }
          onChanged();
        } else {
          typingMessageBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000008;
        return this;
      }
      /**
       * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
       */
      public Builder clearTypingMessage() {
        if (typingMessageBuilder_ == null) {
          typingMessage_ = org.session.libsignal.protos.SignalServiceProtos.TypingMessage.getDefaultInstance();
          onChanged();
        } else {
          typingMessageBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000008);
        return this;
      }
      /**
       * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Builder getTypingMessageBuilder() {
        bitField0_ |= 0x00000008;
        onChanged();
        return getTypingMessageFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.TypingMessageOrBuilder getTypingMessageOrBuilder() {
        if (typingMessageBuilder_ != null) {
          return typingMessageBuilder_.getMessageOrBuilder();
        } else {
          return typingMessage_;
        }
      }
      /**
       * <code>optional .signalservice.TypingMessage typingMessage = 6;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.TypingMessage, org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.TypingMessageOrBuilder> 
          getTypingMessageFieldBuilder() {
        if (typingMessageBuilder_ == null) {
          typingMessageBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.TypingMessage, org.session.libsignal.protos.SignalServiceProtos.TypingMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.TypingMessageOrBuilder>(
                  typingMessage_,
                  getParentForChildren(),
                  isClean());
          typingMessage_ = null;
        }
        return typingMessageBuilder_;
      }

      // optional .signalservice.ConfigurationMessage configurationMessage = 7;
      private org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage configurationMessage_ = org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessageOrBuilder> configurationMessageBuilder_;
      /**
       * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
       */
      public boolean hasConfigurationMessage() {
        return ((bitField0_ & 0x00000010) == 0x00000010);
      }
      /**
       * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage getConfigurationMessage() {
        if (configurationMessageBuilder_ == null) {
          return configurationMessage_;
        } else {
          return configurationMessageBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
       */
      public Builder setConfigurationMessage(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage value) {
        if (configurationMessageBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          configurationMessage_ = value;
          onChanged();
        } else {
          configurationMessageBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000010;
        return this;
      }
      /**
       * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
       */
      public Builder setConfigurationMessage(
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Builder builderForValue) {
        if (configurationMessageBuilder_ == null) {
          configurationMessage_ = builderForValue.build();
          onChanged();
        } else {
          configurationMessageBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000010;
        return this;
      }
      /**
       * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
       */
      public Builder mergeConfigurationMessage(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage value) {
        if (configurationMessageBuilder_ == null) {
          if (((bitField0_ & 0x00000010) == 0x00000010) &&
              configurationMessage_ != org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.getDefaultInstance()) {
            configurationMessage_ =
              org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.newBuilder(configurationMessage_).mergeFrom(value).buildPartial();
          } else {
            configurationMessage_ = value;
          }
          onChanged();
        } else {
          configurationMessageBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000010;
        return this;
      }
      /**
       * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
       */
      public Builder clearConfigurationMessage() {
        if (configurationMessageBuilder_ == null) {
          configurationMessage_ = org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.getDefaultInstance();
          onChanged();
        } else {
          configurationMessageBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000010);
        return this;
      }
      /**
       * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Builder getConfigurationMessageBuilder() {
        bitField0_ |= 0x00000010;
        onChanged();
        return getConfigurationMessageFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessageOrBuilder getConfigurationMessageOrBuilder() {
        if (configurationMessageBuilder_ != null) {
          return configurationMessageBuilder_.getMessageOrBuilder();
        } else {
          return configurationMessage_;
        }
      }
      /**
       * <code>optional .signalservice.ConfigurationMessage configurationMessage = 7;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessageOrBuilder> 
          getConfigurationMessageFieldBuilder() {
        if (configurationMessageBuilder_ == null) {
          configurationMessageBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessageOrBuilder>(
                  configurationMessage_,
                  getParentForChildren(),
                  isClean());
          configurationMessage_ = null;
        }
        return configurationMessageBuilder_;
      }

      // optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;
      private org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification dataExtractionNotification_ = org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification, org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Builder, org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotificationOrBuilder> dataExtractionNotificationBuilder_;
      /**
       * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
       */
      public boolean hasDataExtractionNotification() {
        return ((bitField0_ & 0x00000020) == 0x00000020);
      }
      /**
       * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification getDataExtractionNotification() {
        if (dataExtractionNotificationBuilder_ == null) {
          return dataExtractionNotification_;
        } else {
          return dataExtractionNotificationBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
       */
      public Builder setDataExtractionNotification(org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification value) {
        if (dataExtractionNotificationBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          dataExtractionNotification_ = value;
          onChanged();
        } else {
          dataExtractionNotificationBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000020;
        return this;
      }
      /**
       * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
       */
      public Builder setDataExtractionNotification(
          org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Builder builderForValue) {
        if (dataExtractionNotificationBuilder_ == null) {
          dataExtractionNotification_ = builderForValue.build();
          onChanged();
        } else {
          dataExtractionNotificationBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000020;
        return this;
      }
      /**
       * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
       */
      public Builder mergeDataExtractionNotification(org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification value) {
        if (dataExtractionNotificationBuilder_ == null) {
          if (((bitField0_ & 0x00000020) == 0x00000020) &&
              dataExtractionNotification_ != org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.getDefaultInstance()) {
            dataExtractionNotification_ =
              org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.newBuilder(dataExtractionNotification_).mergeFrom(value).buildPartial();
          } else {
            dataExtractionNotification_ = value;
          }
          onChanged();
        } else {
          dataExtractionNotificationBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000020;
        return this;
      }
      /**
       * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
       */
      public Builder clearDataExtractionNotification() {
        if (dataExtractionNotificationBuilder_ == null) {
          dataExtractionNotification_ = org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.getDefaultInstance();
          onChanged();
        } else {
          dataExtractionNotificationBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000020);
        return this;
      }
      /**
       * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Builder getDataExtractionNotificationBuilder() {
        bitField0_ |= 0x00000020;
        onChanged();
        return getDataExtractionNotificationFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotificationOrBuilder getDataExtractionNotificationOrBuilder() {
        if (dataExtractionNotificationBuilder_ != null) {
          return dataExtractionNotificationBuilder_.getMessageOrBuilder();
        } else {
          return dataExtractionNotification_;
        }
      }
      /**
       * <code>optional .signalservice.DataExtractionNotification dataExtractionNotification = 8;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification, org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Builder, org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotificationOrBuilder> 
          getDataExtractionNotificationFieldBuilder() {
        if (dataExtractionNotificationBuilder_ == null) {
          dataExtractionNotificationBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification, org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Builder, org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotificationOrBuilder>(
                  dataExtractionNotification_,
                  getParentForChildren(),
                  isClean());
          dataExtractionNotification_ = null;
        }
        return dataExtractionNotificationBuilder_;
      }

      // optional .signalservice.UnsendRequest unsendRequest = 9;
      private org.session.libsignal.protos.SignalServiceProtos.UnsendRequest unsendRequest_ = org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.UnsendRequest, org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.Builder, org.session.libsignal.protos.SignalServiceProtos.UnsendRequestOrBuilder> unsendRequestBuilder_;
      /**
       * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
       */
      public boolean hasUnsendRequest() {
        return ((bitField0_ & 0x00000040) == 0x00000040);
      }
      /**
       * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.UnsendRequest getUnsendRequest() {
        if (unsendRequestBuilder_ == null) {
          return unsendRequest_;
        } else {
          return unsendRequestBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
       */
      public Builder setUnsendRequest(org.session.libsignal.protos.SignalServiceProtos.UnsendRequest value) {
        if (unsendRequestBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          unsendRequest_ = value;
          onChanged();
        } else {
          unsendRequestBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000040;
        return this;
      }
      /**
       * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
       */
      public Builder setUnsendRequest(
          org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.Builder builderForValue) {
        if (unsendRequestBuilder_ == null) {
          unsendRequest_ = builderForValue.build();
          onChanged();
        } else {
          unsendRequestBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000040;
        return this;
      }
      /**
       * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
       */
      public Builder mergeUnsendRequest(org.session.libsignal.protos.SignalServiceProtos.UnsendRequest value) {
        if (unsendRequestBuilder_ == null) {
          if (((bitField0_ & 0x00000040) == 0x00000040) &&
              unsendRequest_ != org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.getDefaultInstance()) {
            unsendRequest_ =
              org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.newBuilder(unsendRequest_).mergeFrom(value).buildPartial();
          } else {
            unsendRequest_ = value;
          }
          onChanged();
        } else {
          unsendRequestBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000040;
        return this;
      }
      /**
       * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
       */
      public Builder clearUnsendRequest() {
        if (unsendRequestBuilder_ == null) {
          unsendRequest_ = org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.getDefaultInstance();
          onChanged();
        } else {
          unsendRequestBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000040);
        return this;
      }
      /**
       * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.Builder getUnsendRequestBuilder() {
        bitField0_ |= 0x00000040;
        onChanged();
        return getUnsendRequestFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.UnsendRequestOrBuilder getUnsendRequestOrBuilder() {
        if (unsendRequestBuilder_ != null) {
          return unsendRequestBuilder_.getMessageOrBuilder();
        } else {
          return unsendRequest_;
        }
      }
      /**
       * <code>optional .signalservice.UnsendRequest unsendRequest = 9;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.UnsendRequest, org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.Builder, org.session.libsignal.protos.SignalServiceProtos.UnsendRequestOrBuilder> 
          getUnsendRequestFieldBuilder() {
        if (unsendRequestBuilder_ == null) {
          unsendRequestBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.UnsendRequest, org.session.libsignal.protos.SignalServiceProtos.UnsendRequest.Builder, org.session.libsignal.protos.SignalServiceProtos.UnsendRequestOrBuilder>(
                  unsendRequest_,
                  getParentForChildren(),
                  isClean());
          unsendRequest_ = null;
        }
        return unsendRequestBuilder_;
      }

      // optional .signalservice.MessageRequestResponse messageRequestResponse = 10;
      private org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse messageRequestResponse_ = org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse, org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.Builder, org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponseOrBuilder> messageRequestResponseBuilder_;
      /**
       * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
       */
      public boolean hasMessageRequestResponse() {
        return ((bitField0_ & 0x00000080) == 0x00000080);
      }
      /**
       * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse getMessageRequestResponse() {
        if (messageRequestResponseBuilder_ == null) {
          return messageRequestResponse_;
        } else {
          return messageRequestResponseBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
       */
      public Builder setMessageRequestResponse(org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse value) {
        if (messageRequestResponseBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          messageRequestResponse_ = value;
          onChanged();
        } else {
          messageRequestResponseBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000080;
        return this;
      }
      /**
       * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
       */
      public Builder setMessageRequestResponse(
          org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.Builder builderForValue) {
        if (messageRequestResponseBuilder_ == null) {
          messageRequestResponse_ = builderForValue.build();
          onChanged();
        } else {
          messageRequestResponseBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000080;
        return this;
      }
      /**
       * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
       */
      public Builder mergeMessageRequestResponse(org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse value) {
        if (messageRequestResponseBuilder_ == null) {
          if (((bitField0_ & 0x00000080) == 0x00000080) &&
              messageRequestResponse_ != org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.getDefaultInstance()) {
            messageRequestResponse_ =
              org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.newBuilder(messageRequestResponse_).mergeFrom(value).buildPartial();
          } else {
            messageRequestResponse_ = value;
          }
          onChanged();
        } else {
          messageRequestResponseBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000080;
        return this;
      }
      /**
       * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
       */
      public Builder clearMessageRequestResponse() {
        if (messageRequestResponseBuilder_ == null) {
          messageRequestResponse_ = org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.getDefaultInstance();
          onChanged();
        } else {
          messageRequestResponseBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000080);
        return this;
      }
      /**
       * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.Builder getMessageRequestResponseBuilder() {
        bitField0_ |= 0x00000080;
        onChanged();
        return getMessageRequestResponseFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponseOrBuilder getMessageRequestResponseOrBuilder() {
        if (messageRequestResponseBuilder_ != null) {
          return messageRequestResponseBuilder_.getMessageOrBuilder();
        } else {
          return messageRequestResponse_;
        }
      }
      /**
       * <code>optional .signalservice.MessageRequestResponse messageRequestResponse = 10;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse, org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.Builder, org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponseOrBuilder> 
          getMessageRequestResponseFieldBuilder() {
        if (messageRequestResponseBuilder_ == null) {
          messageRequestResponseBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse, org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.Builder, org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponseOrBuilder>(
                  messageRequestResponse_,
                  getParentForChildren(),
                  isClean());
          messageRequestResponse_ = null;
        }
        return messageRequestResponseBuilder_;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.Content)
    }

    static {
      defaultInstance = new Content(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.Content)
  }

  public interface KeyPairOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // required bytes publicKey = 1;
    /**
     * <code>required bytes publicKey = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasPublicKey();
    /**
     * <code>required bytes publicKey = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    com.google.protobuf.ByteString getPublicKey();

    // required bytes privateKey = 2;
    /**
     * <code>required bytes privateKey = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasPrivateKey();
    /**
     * <code>required bytes privateKey = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    com.google.protobuf.ByteString getPrivateKey();
  }
  /**
   * Protobuf type {@code signalservice.KeyPair}
   */
  public static final class KeyPair extends
      com.google.protobuf.GeneratedMessage
      implements KeyPairOrBuilder {
    // Use KeyPair.newBuilder() to construct.
    private KeyPair(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private KeyPair(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final KeyPair defaultInstance;
    public static KeyPair getDefaultInstance() {
      return defaultInstance;
    }

    public KeyPair getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private KeyPair(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 10: {
              bitField0_ |= 0x00000001;
              publicKey_ = input.readBytes();
              break;
            }
            case 18: {
              bitField0_ |= 0x00000002;
              privateKey_ = input.readBytes();
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_KeyPair_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_KeyPair_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.KeyPair.class, org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder.class);
    }

    public static com.google.protobuf.Parser<KeyPair> PARSER =
        new com.google.protobuf.AbstractParser<KeyPair>() {
      public KeyPair parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new KeyPair(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<KeyPair> getParserForType() {
      return PARSER;
    }

    private int bitField0_;
    // required bytes publicKey = 1;
    public static final int PUBLICKEY_FIELD_NUMBER = 1;
    private com.google.protobuf.ByteString publicKey_;
    /**
     * <code>required bytes publicKey = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasPublicKey() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>required bytes publicKey = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public com.google.protobuf.ByteString getPublicKey() {
      return publicKey_;
    }

    // required bytes privateKey = 2;
    public static final int PRIVATEKEY_FIELD_NUMBER = 2;
    private com.google.protobuf.ByteString privateKey_;
    /**
     * <code>required bytes privateKey = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasPrivateKey() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>required bytes privateKey = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public com.google.protobuf.ByteString getPrivateKey() {
      return privateKey_;
    }

    private void initFields() {
      publicKey_ = com.google.protobuf.ByteString.EMPTY;
      privateKey_ = com.google.protobuf.ByteString.EMPTY;
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      if (!hasPublicKey()) {
        memoizedIsInitialized = 0;
        return false;
      }
      if (!hasPrivateKey()) {
        memoizedIsInitialized = 0;
        return false;
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeBytes(1, publicKey_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeBytes(2, privateKey_);
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(1, publicKey_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(2, privateKey_);
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.KeyPair parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.KeyPair parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.KeyPair parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.KeyPair parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.KeyPair parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.KeyPair parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.KeyPair parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.KeyPair parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.KeyPair parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.KeyPair parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.KeyPair prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.KeyPair}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_KeyPair_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_KeyPair_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.KeyPair.class, org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.KeyPair.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        publicKey_ = com.google.protobuf.ByteString.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000001);
        privateKey_ = com.google.protobuf.ByteString.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000002);
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_KeyPair_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.KeyPair getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.KeyPair.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.KeyPair build() {
        org.session.libsignal.protos.SignalServiceProtos.KeyPair result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.KeyPair buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.KeyPair result = new org.session.libsignal.protos.SignalServiceProtos.KeyPair(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.publicKey_ = publicKey_;
        if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
          to_bitField0_ |= 0x00000002;
        }
        result.privateKey_ = privateKey_;
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.KeyPair) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.KeyPair)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.KeyPair other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.KeyPair.getDefaultInstance()) return this;
        if (other.hasPublicKey()) {
          setPublicKey(other.getPublicKey());
        }
        if (other.hasPrivateKey()) {
          setPrivateKey(other.getPrivateKey());
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        if (!hasPublicKey()) {
          
          return false;
        }
        if (!hasPrivateKey()) {
          
          return false;
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.KeyPair parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.KeyPair) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // required bytes publicKey = 1;
      private com.google.protobuf.ByteString publicKey_ = com.google.protobuf.ByteString.EMPTY;
      /**
       * <code>required bytes publicKey = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasPublicKey() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required bytes publicKey = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public com.google.protobuf.ByteString getPublicKey() {
        return publicKey_;
      }
      /**
       * <code>required bytes publicKey = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setPublicKey(com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
        publicKey_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required bytes publicKey = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearPublicKey() {
        bitField0_ = (bitField0_ & ~0x00000001);
        publicKey_ = getDefaultInstance().getPublicKey();
        onChanged();
        return this;
      }

      // required bytes privateKey = 2;
      private com.google.protobuf.ByteString privateKey_ = com.google.protobuf.ByteString.EMPTY;
      /**
       * <code>required bytes privateKey = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasPrivateKey() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>required bytes privateKey = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public com.google.protobuf.ByteString getPrivateKey() {
        return privateKey_;
      }
      /**
       * <code>required bytes privateKey = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setPrivateKey(com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
        privateKey_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required bytes privateKey = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearPrivateKey() {
        bitField0_ = (bitField0_ & ~0x00000002);
        privateKey_ = getDefaultInstance().getPrivateKey();
        onChanged();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.KeyPair)
    }

    static {
      defaultInstance = new KeyPair(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.KeyPair)
  }

  public interface DataExtractionNotificationOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // required .signalservice.DataExtractionNotification.Type type = 1;
    /**
     * <code>required .signalservice.DataExtractionNotification.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasType();
    /**
     * <code>required .signalservice.DataExtractionNotification.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Type getType();

    // optional uint64 timestamp = 2;
    /**
     * <code>optional uint64 timestamp = 2;</code>
     */
    boolean hasTimestamp();
    /**
     * <code>optional uint64 timestamp = 2;</code>
     */
    long getTimestamp();
  }
  /**
   * Protobuf type {@code signalservice.DataExtractionNotification}
   */
  public static final class DataExtractionNotification extends
      com.google.protobuf.GeneratedMessage
      implements DataExtractionNotificationOrBuilder {
    // Use DataExtractionNotification.newBuilder() to construct.
    private DataExtractionNotification(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private DataExtractionNotification(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final DataExtractionNotification defaultInstance;
    public static DataExtractionNotification getDefaultInstance() {
      return defaultInstance;
    }

    public DataExtractionNotification getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private DataExtractionNotification(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 8: {
              int rawValue = input.readEnum();
              org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Type value = org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Type.valueOf(rawValue);
              if (value == null) {
                unknownFields.mergeVarintField(1, rawValue);
              } else {
                bitField0_ |= 0x00000001;
                type_ = value;
              }
              break;
            }
            case 16: {
              bitField0_ |= 0x00000002;
              timestamp_ = input.readUInt64();
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataExtractionNotification_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataExtractionNotification_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.class, org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Builder.class);
    }

    public static com.google.protobuf.Parser<DataExtractionNotification> PARSER =
        new com.google.protobuf.AbstractParser<DataExtractionNotification>() {
      public DataExtractionNotification parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new DataExtractionNotification(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<DataExtractionNotification> getParserForType() {
      return PARSER;
    }

    /**
     * Protobuf enum {@code signalservice.DataExtractionNotification.Type}
     */
    public enum Type
        implements com.google.protobuf.ProtocolMessageEnum {
      /**
       * <code>SCREENSHOT = 1;</code>
       */
      SCREENSHOT(0, 1),
      /**
       * <code>MEDIA_SAVED = 2;</code>
       *
       * <pre>
       * timestamp
       * </pre>
       */
      MEDIA_SAVED(1, 2),
      ;

      /**
       * <code>SCREENSHOT = 1;</code>
       */
      public static final int SCREENSHOT_VALUE = 1;
      /**
       * <code>MEDIA_SAVED = 2;</code>
       *
       * <pre>
       * timestamp
       * </pre>
       */
      public static final int MEDIA_SAVED_VALUE = 2;


      public final int getNumber() { return value; }

      public static Type valueOf(int value) {
        switch (value) {
          case 1: return SCREENSHOT;
          case 2: return MEDIA_SAVED;
          default: return null;
        }
      }

      public static com.google.protobuf.Internal.EnumLiteMap<Type>
          internalGetValueMap() {
        return internalValueMap;
      }
      private static com.google.protobuf.Internal.EnumLiteMap<Type>
          internalValueMap =
            new com.google.protobuf.Internal.EnumLiteMap<Type>() {
              public Type findValueByNumber(int number) {
                return Type.valueOf(number);
              }
            };

      public final com.google.protobuf.Descriptors.EnumValueDescriptor
          getValueDescriptor() {
        return getDescriptor().getValues().get(index);
      }
      public final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptorForType() {
        return getDescriptor();
      }
      public static final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.getDescriptor().getEnumTypes().get(0);
      }

      private static final Type[] VALUES = values();

      public static Type valueOf(
          com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
        if (desc.getType() != getDescriptor()) {
          throw new java.lang.IllegalArgumentException(
            "EnumValueDescriptor is not for this type.");
        }
        return VALUES[desc.getIndex()];
      }

      private final int index;
      private final int value;

      private Type(int index, int value) {
        this.index = index;
        this.value = value;
      }

      // @@protoc_insertion_point(enum_scope:signalservice.DataExtractionNotification.Type)
    }

    private int bitField0_;
    // required .signalservice.DataExtractionNotification.Type type = 1;
    public static final int TYPE_FIELD_NUMBER = 1;
    private org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Type type_;
    /**
     * <code>required .signalservice.DataExtractionNotification.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasType() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>required .signalservice.DataExtractionNotification.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Type getType() {
      return type_;
    }

    // optional uint64 timestamp = 2;
    public static final int TIMESTAMP_FIELD_NUMBER = 2;
    private long timestamp_;
    /**
     * <code>optional uint64 timestamp = 2;</code>
     */
    public boolean hasTimestamp() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>optional uint64 timestamp = 2;</code>
     */
    public long getTimestamp() {
      return timestamp_;
    }

    private void initFields() {
      type_ = org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Type.SCREENSHOT;
      timestamp_ = 0L;
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      if (!hasType()) {
        memoizedIsInitialized = 0;
        return false;
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeEnum(1, type_.getNumber());
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeUInt64(2, timestamp_);
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeEnumSize(1, type_.getNumber());
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt64Size(2, timestamp_);
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.DataExtractionNotification}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotificationOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataExtractionNotification_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataExtractionNotification_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.class, org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        type_ = org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Type.SCREENSHOT;
        bitField0_ = (bitField0_ & ~0x00000001);
        timestamp_ = 0L;
        bitField0_ = (bitField0_ & ~0x00000002);
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataExtractionNotification_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification build() {
        org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification result = new org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.type_ = type_;
        if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
          to_bitField0_ |= 0x00000002;
        }
        result.timestamp_ = timestamp_;
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.getDefaultInstance()) return this;
        if (other.hasType()) {
          setType(other.getType());
        }
        if (other.hasTimestamp()) {
          setTimestamp(other.getTimestamp());
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        if (!hasType()) {
          
          return false;
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // required .signalservice.DataExtractionNotification.Type type = 1;
      private org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Type type_ = org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Type.SCREENSHOT;
      /**
       * <code>required .signalservice.DataExtractionNotification.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasType() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required .signalservice.DataExtractionNotification.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Type getType() {
        return type_;
      }
      /**
       * <code>required .signalservice.DataExtractionNotification.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setType(org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Type value) {
        if (value == null) {
          throw new NullPointerException();
        }
        bitField0_ |= 0x00000001;
        type_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required .signalservice.DataExtractionNotification.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearType() {
        bitField0_ = (bitField0_ & ~0x00000001);
        type_ = org.session.libsignal.protos.SignalServiceProtos.DataExtractionNotification.Type.SCREENSHOT;
        onChanged();
        return this;
      }

      // optional uint64 timestamp = 2;
      private long timestamp_ ;
      /**
       * <code>optional uint64 timestamp = 2;</code>
       */
      public boolean hasTimestamp() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>optional uint64 timestamp = 2;</code>
       */
      public long getTimestamp() {
        return timestamp_;
      }
      /**
       * <code>optional uint64 timestamp = 2;</code>
       */
      public Builder setTimestamp(long value) {
        bitField0_ |= 0x00000002;
        timestamp_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional uint64 timestamp = 2;</code>
       */
      public Builder clearTimestamp() {
        bitField0_ = (bitField0_ & ~0x00000002);
        timestamp_ = 0L;
        onChanged();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.DataExtractionNotification)
    }

    static {
      defaultInstance = new DataExtractionNotification(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.DataExtractionNotification)
  }

  public interface DataMessageOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // optional string body = 1;
    /**
     * <code>optional string body = 1;</code>
     */
    boolean hasBody();
    /**
     * <code>optional string body = 1;</code>
     */
    java.lang.String getBody();
    /**
     * <code>optional string body = 1;</code>
     */
    com.google.protobuf.ByteString
        getBodyBytes();

    // repeated .signalservice.AttachmentPointer attachments = 2;
    /**
     * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
     */
    java.util.List<org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer> 
        getAttachmentsList();
    /**
     * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getAttachments(int index);
    /**
     * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
     */
    int getAttachmentsCount();
    /**
     * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
     */
    java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder> 
        getAttachmentsOrBuilderList();
    /**
     * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder getAttachmentsOrBuilder(
        int index);

    // optional .signalservice.GroupContext group = 3;
    /**
     * <code>optional .signalservice.GroupContext group = 3;</code>
     */
    boolean hasGroup();
    /**
     * <code>optional .signalservice.GroupContext group = 3;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.GroupContext getGroup();
    /**
     * <code>optional .signalservice.GroupContext group = 3;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.GroupContextOrBuilder getGroupOrBuilder();

    // optional uint32 flags = 4;
    /**
     * <code>optional uint32 flags = 4;</code>
     */
    boolean hasFlags();
    /**
     * <code>optional uint32 flags = 4;</code>
     */
    int getFlags();

    // optional uint32 expireTimer = 5;
    /**
     * <code>optional uint32 expireTimer = 5;</code>
     */
    boolean hasExpireTimer();
    /**
     * <code>optional uint32 expireTimer = 5;</code>
     */
    int getExpireTimer();

    // optional bytes profileKey = 6;
    /**
     * <code>optional bytes profileKey = 6;</code>
     */
    boolean hasProfileKey();
    /**
     * <code>optional bytes profileKey = 6;</code>
     */
    com.google.protobuf.ByteString getProfileKey();

    // optional uint64 timestamp = 7;
    /**
     * <code>optional uint64 timestamp = 7;</code>
     */
    boolean hasTimestamp();
    /**
     * <code>optional uint64 timestamp = 7;</code>
     */
    long getTimestamp();

    // optional .signalservice.DataMessage.Quote quote = 8;
    /**
     * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
     */
    boolean hasQuote();
    /**
     * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote getQuote();
    /**
     * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.QuoteOrBuilder getQuoteOrBuilder();

    // repeated .signalservice.DataMessage.Preview preview = 10;
    /**
     * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
     */
    java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview> 
        getPreviewList();
    /**
     * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview getPreview(int index);
    /**
     * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
     */
    int getPreviewCount();
    /**
     * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
     */
    java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.DataMessage.PreviewOrBuilder> 
        getPreviewOrBuilderList();
    /**
     * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.PreviewOrBuilder getPreviewOrBuilder(
        int index);

    // optional .signalservice.DataMessage.Reaction reaction = 11;
    /**
     * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
     */
    boolean hasReaction();
    /**
     * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction getReaction();
    /**
     * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.ReactionOrBuilder getReactionOrBuilder();

    // optional .signalservice.DataMessage.LokiProfile profile = 101;
    /**
     * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
     */
    boolean hasProfile();
    /**
     * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile getProfile();
    /**
     * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder getProfileOrBuilder();

    // optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;
    /**
     * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
     */
    boolean hasOpenGroupInvitation();
    /**
     * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation getOpenGroupInvitation();
    /**
     * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitationOrBuilder getOpenGroupInvitationOrBuilder();

    // optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;
    /**
     * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
     */
    boolean hasClosedGroupControlMessage();
    /**
     * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage getClosedGroupControlMessage();
    /**
     * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessageOrBuilder getClosedGroupControlMessageOrBuilder();

    // optional string syncTarget = 105;
    /**
     * <code>optional string syncTarget = 105;</code>
     */
    boolean hasSyncTarget();
    /**
     * <code>optional string syncTarget = 105;</code>
     */
    java.lang.String getSyncTarget();
    /**
     * <code>optional string syncTarget = 105;</code>
     */
    com.google.protobuf.ByteString
        getSyncTargetBytes();
  }
  /**
   * Protobuf type {@code signalservice.DataMessage}
   */
  public static final class DataMessage extends
      com.google.protobuf.GeneratedMessage
      implements DataMessageOrBuilder {
    // Use DataMessage.newBuilder() to construct.
    private DataMessage(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private DataMessage(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final DataMessage defaultInstance;
    public static DataMessage getDefaultInstance() {
      return defaultInstance;
    }

    public DataMessage getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private DataMessage(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 10: {
              bitField0_ |= 0x00000001;
              body_ = input.readBytes();
              break;
            }
            case 18: {
              if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
                attachments_ = new java.util.ArrayList<org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer>();
                mutable_bitField0_ |= 0x00000002;
              }
              attachments_.add(input.readMessage(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.PARSER, extensionRegistry));
              break;
            }
            case 26: {
              org.session.libsignal.protos.SignalServiceProtos.GroupContext.Builder subBuilder = null;
              if (((bitField0_ & 0x00000002) == 0x00000002)) {
                subBuilder = group_.toBuilder();
              }
              group_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.GroupContext.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(group_);
                group_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000002;
              break;
            }
            case 32: {
              bitField0_ |= 0x00000004;
              flags_ = input.readUInt32();
              break;
            }
            case 40: {
              bitField0_ |= 0x00000008;
              expireTimer_ = input.readUInt32();
              break;
            }
            case 50: {
              bitField0_ |= 0x00000010;
              profileKey_ = input.readBytes();
              break;
            }
            case 56: {
              bitField0_ |= 0x00000020;
              timestamp_ = input.readUInt64();
              break;
            }
            case 66: {
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.Builder subBuilder = null;
              if (((bitField0_ & 0x00000040) == 0x00000040)) {
                subBuilder = quote_.toBuilder();
              }
              quote_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(quote_);
                quote_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000040;
              break;
            }
            case 82: {
              if (!((mutable_bitField0_ & 0x00000100) == 0x00000100)) {
                preview_ = new java.util.ArrayList<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview>();
                mutable_bitField0_ |= 0x00000100;
              }
              preview_.add(input.readMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.PARSER, extensionRegistry));
              break;
            }
            case 90: {
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Builder subBuilder = null;
              if (((bitField0_ & 0x00000080) == 0x00000080)) {
                subBuilder = reaction_.toBuilder();
              }
              reaction_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(reaction_);
                reaction_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000080;
              break;
            }
            case 810: {
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder subBuilder = null;
              if (((bitField0_ & 0x00000100) == 0x00000100)) {
                subBuilder = profile_.toBuilder();
              }
              profile_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(profile_);
                profile_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000100;
              break;
            }
            case 818: {
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.Builder subBuilder = null;
              if (((bitField0_ & 0x00000200) == 0x00000200)) {
                subBuilder = openGroupInvitation_.toBuilder();
              }
              openGroupInvitation_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(openGroupInvitation_);
                openGroupInvitation_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000200;
              break;
            }
            case 834: {
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Builder subBuilder = null;
              if (((bitField0_ & 0x00000400) == 0x00000400)) {
                subBuilder = closedGroupControlMessage_.toBuilder();
              }
              closedGroupControlMessage_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(closedGroupControlMessage_);
                closedGroupControlMessage_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000400;
              break;
            }
            case 842: {
              bitField0_ |= 0x00000800;
              syncTarget_ = input.readBytes();
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
          attachments_ = java.util.Collections.unmodifiableList(attachments_);
        }
        if (((mutable_bitField0_ & 0x00000100) == 0x00000100)) {
          preview_ = java.util.Collections.unmodifiableList(preview_);
        }
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Builder.class);
    }

    public static com.google.protobuf.Parser<DataMessage> PARSER =
        new com.google.protobuf.AbstractParser<DataMessage>() {
      public DataMessage parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new DataMessage(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<DataMessage> getParserForType() {
      return PARSER;
    }

    /**
     * Protobuf enum {@code signalservice.DataMessage.Flags}
     */
    public enum Flags
        implements com.google.protobuf.ProtocolMessageEnum {
      /**
       * <code>EXPIRATION_TIMER_UPDATE = 2;</code>
       */
      EXPIRATION_TIMER_UPDATE(0, 2),
      ;

      /**
       * <code>EXPIRATION_TIMER_UPDATE = 2;</code>
       */
      public static final int EXPIRATION_TIMER_UPDATE_VALUE = 2;


      public final int getNumber() { return value; }

      public static Flags valueOf(int value) {
        switch (value) {
          case 2: return EXPIRATION_TIMER_UPDATE;
          default: return null;
        }
      }

      public static com.google.protobuf.Internal.EnumLiteMap<Flags>
          internalGetValueMap() {
        return internalValueMap;
      }
      private static com.google.protobuf.Internal.EnumLiteMap<Flags>
          internalValueMap =
            new com.google.protobuf.Internal.EnumLiteMap<Flags>() {
              public Flags findValueByNumber(int number) {
                return Flags.valueOf(number);
              }
            };

      public final com.google.protobuf.Descriptors.EnumValueDescriptor
          getValueDescriptor() {
        return getDescriptor().getValues().get(index);
      }
      public final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptorForType() {
        return getDescriptor();
      }
      public static final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.DataMessage.getDescriptor().getEnumTypes().get(0);
      }

      private static final Flags[] VALUES = values();

      public static Flags valueOf(
          com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
        if (desc.getType() != getDescriptor()) {
          throw new java.lang.IllegalArgumentException(
            "EnumValueDescriptor is not for this type.");
        }
        return VALUES[desc.getIndex()];
      }

      private final int index;
      private final int value;

      private Flags(int index, int value) {
        this.index = index;
        this.value = value;
      }

      // @@protoc_insertion_point(enum_scope:signalservice.DataMessage.Flags)
    }

    public interface QuoteOrBuilder
        extends com.google.protobuf.MessageOrBuilder {

      // required uint64 id = 1;
      /**
       * <code>required uint64 id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      boolean hasId();
      /**
       * <code>required uint64 id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      long getId();

      // required string author = 2;
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      boolean hasAuthor();
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      java.lang.String getAuthor();
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      com.google.protobuf.ByteString
          getAuthorBytes();

      // optional string text = 3;
      /**
       * <code>optional string text = 3;</code>
       */
      boolean hasText();
      /**
       * <code>optional string text = 3;</code>
       */
      java.lang.String getText();
      /**
       * <code>optional string text = 3;</code>
       */
      com.google.protobuf.ByteString
          getTextBytes();

      // repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;
      /**
       * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
       */
      java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment> 
          getAttachmentsList();
      /**
       * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
       */
      org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment getAttachments(int index);
      /**
       * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
       */
      int getAttachmentsCount();
      /**
       * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
       */
      java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachmentOrBuilder> 
          getAttachmentsOrBuilderList();
      /**
       * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
       */
      org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachmentOrBuilder getAttachmentsOrBuilder(
          int index);
    }
    /**
     * Protobuf type {@code signalservice.DataMessage.Quote}
     */
    public static final class Quote extends
        com.google.protobuf.GeneratedMessage
        implements QuoteOrBuilder {
      // Use Quote.newBuilder() to construct.
      private Quote(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
        super(builder);
        this.unknownFields = builder.getUnknownFields();
      }
      private Quote(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

      private static final Quote defaultInstance;
      public static Quote getDefaultInstance() {
        return defaultInstance;
      }

      public Quote getDefaultInstanceForType() {
        return defaultInstance;
      }

      private final com.google.protobuf.UnknownFieldSet unknownFields;
      @java.lang.Override
      public final com.google.protobuf.UnknownFieldSet
          getUnknownFields() {
        return this.unknownFields;
      }
      private Quote(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        initFields();
        int mutable_bitField0_ = 0;
        com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder();
        try {
          boolean done = false;
          while (!done) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                done = true;
                break;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  done = true;
                }
                break;
              }
              case 8: {
                bitField0_ |= 0x00000001;
                id_ = input.readUInt64();
                break;
              }
              case 18: {
                bitField0_ |= 0x00000002;
                author_ = input.readBytes();
                break;
              }
              case 26: {
                bitField0_ |= 0x00000004;
                text_ = input.readBytes();
                break;
              }
              case 34: {
                if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
                  attachments_ = new java.util.ArrayList<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment>();
                  mutable_bitField0_ |= 0x00000008;
                }
                attachments_.add(input.readMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.PARSER, extensionRegistry));
                break;
              }
            }
          }
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          throw e.setUnfinishedMessage(this);
        } catch (java.io.IOException e) {
          throw new com.google.protobuf.InvalidProtocolBufferException(
              e.getMessage()).setUnfinishedMessage(this);
        } finally {
          if (((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
            attachments_ = java.util.Collections.unmodifiableList(attachments_);
          }
          this.unknownFields = unknownFields.build();
          makeExtensionsImmutable();
        }
      }
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Quote_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Quote_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.Builder.class);
      }

      public static com.google.protobuf.Parser<Quote> PARSER =
          new com.google.protobuf.AbstractParser<Quote>() {
        public Quote parsePartialFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return new Quote(input, extensionRegistry);
        }
      };

      @java.lang.Override
      public com.google.protobuf.Parser<Quote> getParserForType() {
        return PARSER;
      }

      public interface QuotedAttachmentOrBuilder
          extends com.google.protobuf.MessageOrBuilder {

        // optional string contentType = 1;
        /**
         * <code>optional string contentType = 1;</code>
         */
        boolean hasContentType();
        /**
         * <code>optional string contentType = 1;</code>
         */
        java.lang.String getContentType();
        /**
         * <code>optional string contentType = 1;</code>
         */
        com.google.protobuf.ByteString
            getContentTypeBytes();

        // optional string fileName = 2;
        /**
         * <code>optional string fileName = 2;</code>
         */
        boolean hasFileName();
        /**
         * <code>optional string fileName = 2;</code>
         */
        java.lang.String getFileName();
        /**
         * <code>optional string fileName = 2;</code>
         */
        com.google.protobuf.ByteString
            getFileNameBytes();

        // optional .signalservice.AttachmentPointer thumbnail = 3;
        /**
         * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
         */
        boolean hasThumbnail();
        /**
         * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
         */
        org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getThumbnail();
        /**
         * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
         */
        org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder getThumbnailOrBuilder();

        // optional uint32 flags = 4;
        /**
         * <code>optional uint32 flags = 4;</code>
         */
        boolean hasFlags();
        /**
         * <code>optional uint32 flags = 4;</code>
         */
        int getFlags();
      }
      /**
       * Protobuf type {@code signalservice.DataMessage.Quote.QuotedAttachment}
       */
      public static final class QuotedAttachment extends
          com.google.protobuf.GeneratedMessage
          implements QuotedAttachmentOrBuilder {
        // Use QuotedAttachment.newBuilder() to construct.
        private QuotedAttachment(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
          super(builder);
          this.unknownFields = builder.getUnknownFields();
        }
        private QuotedAttachment(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

        private static final QuotedAttachment defaultInstance;
        public static QuotedAttachment getDefaultInstance() {
          return defaultInstance;
        }

        public QuotedAttachment getDefaultInstanceForType() {
          return defaultInstance;
        }

        private final com.google.protobuf.UnknownFieldSet unknownFields;
        @java.lang.Override
        public final com.google.protobuf.UnknownFieldSet
            getUnknownFields() {
          return this.unknownFields;
        }
        private QuotedAttachment(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          initFields();
          int mutable_bitField0_ = 0;
          com.google.protobuf.UnknownFieldSet.Builder unknownFields =
              com.google.protobuf.UnknownFieldSet.newBuilder();
          try {
            boolean done = false;
            while (!done) {
              int tag = input.readTag();
              switch (tag) {
                case 0:
                  done = true;
                  break;
                default: {
                  if (!parseUnknownField(input, unknownFields,
                                         extensionRegistry, tag)) {
                    done = true;
                  }
                  break;
                }
                case 10: {
                  bitField0_ |= 0x00000001;
                  contentType_ = input.readBytes();
                  break;
                }
                case 18: {
                  bitField0_ |= 0x00000002;
                  fileName_ = input.readBytes();
                  break;
                }
                case 26: {
                  org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder subBuilder = null;
                  if (((bitField0_ & 0x00000004) == 0x00000004)) {
                    subBuilder = thumbnail_.toBuilder();
                  }
                  thumbnail_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.PARSER, extensionRegistry);
                  if (subBuilder != null) {
                    subBuilder.mergeFrom(thumbnail_);
                    thumbnail_ = subBuilder.buildPartial();
                  }
                  bitField0_ |= 0x00000004;
                  break;
                }
                case 32: {
                  bitField0_ |= 0x00000008;
                  flags_ = input.readUInt32();
                  break;
                }
              }
            }
          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
            throw e.setUnfinishedMessage(this);
          } catch (java.io.IOException e) {
            throw new com.google.protobuf.InvalidProtocolBufferException(
                e.getMessage()).setUnfinishedMessage(this);
          } finally {
            this.unknownFields = unknownFields.build();
            makeExtensionsImmutable();
          }
        }
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Quote_QuotedAttachment_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Quote_QuotedAttachment_fieldAccessorTable
              .ensureFieldAccessorsInitialized(
                  org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.Builder.class);
        }

        public static com.google.protobuf.Parser<QuotedAttachment> PARSER =
            new com.google.protobuf.AbstractParser<QuotedAttachment>() {
          public QuotedAttachment parsePartialFrom(
              com.google.protobuf.CodedInputStream input,
              com.google.protobuf.ExtensionRegistryLite extensionRegistry)
              throws com.google.protobuf.InvalidProtocolBufferException {
            return new QuotedAttachment(input, extensionRegistry);
          }
        };

        @java.lang.Override
        public com.google.protobuf.Parser<QuotedAttachment> getParserForType() {
          return PARSER;
        }

        /**
         * Protobuf enum {@code signalservice.DataMessage.Quote.QuotedAttachment.Flags}
         */
        public enum Flags
            implements com.google.protobuf.ProtocolMessageEnum {
          /**
           * <code>VOICE_MESSAGE = 1;</code>
           */
          VOICE_MESSAGE(0, 1),
          ;

          /**
           * <code>VOICE_MESSAGE = 1;</code>
           */
          public static final int VOICE_MESSAGE_VALUE = 1;


          public final int getNumber() { return value; }

          public static Flags valueOf(int value) {
            switch (value) {
              case 1: return VOICE_MESSAGE;
              default: return null;
            }
          }

          public static com.google.protobuf.Internal.EnumLiteMap<Flags>
              internalGetValueMap() {
            return internalValueMap;
          }
          private static com.google.protobuf.Internal.EnumLiteMap<Flags>
              internalValueMap =
                new com.google.protobuf.Internal.EnumLiteMap<Flags>() {
                  public Flags findValueByNumber(int number) {
                    return Flags.valueOf(number);
                  }
                };

          public final com.google.protobuf.Descriptors.EnumValueDescriptor
              getValueDescriptor() {
            return getDescriptor().getValues().get(index);
          }
          public final com.google.protobuf.Descriptors.EnumDescriptor
              getDescriptorForType() {
            return getDescriptor();
          }
          public static final com.google.protobuf.Descriptors.EnumDescriptor
              getDescriptor() {
            return org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.getDescriptor().getEnumTypes().get(0);
          }

          private static final Flags[] VALUES = values();

          public static Flags valueOf(
              com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
            if (desc.getType() != getDescriptor()) {
              throw new java.lang.IllegalArgumentException(
                "EnumValueDescriptor is not for this type.");
            }
            return VALUES[desc.getIndex()];
          }

          private final int index;
          private final int value;

          private Flags(int index, int value) {
            this.index = index;
            this.value = value;
          }

          // @@protoc_insertion_point(enum_scope:signalservice.DataMessage.Quote.QuotedAttachment.Flags)
        }

        private int bitField0_;
        // optional string contentType = 1;
        public static final int CONTENTTYPE_FIELD_NUMBER = 1;
        private java.lang.Object contentType_;
        /**
         * <code>optional string contentType = 1;</code>
         */
        public boolean hasContentType() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>optional string contentType = 1;</code>
         */
        public java.lang.String getContentType() {
          java.lang.Object ref = contentType_;
          if (ref instanceof java.lang.String) {
            return (java.lang.String) ref;
          } else {
            com.google.protobuf.ByteString bs = 
                (com.google.protobuf.ByteString) ref;
            java.lang.String s = bs.toStringUtf8();
            if (bs.isValidUtf8()) {
              contentType_ = s;
            }
            return s;
          }
        }
        /**
         * <code>optional string contentType = 1;</code>
         */
        public com.google.protobuf.ByteString
            getContentTypeBytes() {
          java.lang.Object ref = contentType_;
          if (ref instanceof java.lang.String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            contentType_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }

        // optional string fileName = 2;
        public static final int FILENAME_FIELD_NUMBER = 2;
        private java.lang.Object fileName_;
        /**
         * <code>optional string fileName = 2;</code>
         */
        public boolean hasFileName() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>optional string fileName = 2;</code>
         */
        public java.lang.String getFileName() {
          java.lang.Object ref = fileName_;
          if (ref instanceof java.lang.String) {
            return (java.lang.String) ref;
          } else {
            com.google.protobuf.ByteString bs = 
                (com.google.protobuf.ByteString) ref;
            java.lang.String s = bs.toStringUtf8();
            if (bs.isValidUtf8()) {
              fileName_ = s;
            }
            return s;
          }
        }
        /**
         * <code>optional string fileName = 2;</code>
         */
        public com.google.protobuf.ByteString
            getFileNameBytes() {
          java.lang.Object ref = fileName_;
          if (ref instanceof java.lang.String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            fileName_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }

        // optional .signalservice.AttachmentPointer thumbnail = 3;
        public static final int THUMBNAIL_FIELD_NUMBER = 3;
        private org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer thumbnail_;
        /**
         * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
         */
        public boolean hasThumbnail() {
          return ((bitField0_ & 0x00000004) == 0x00000004);
        }
        /**
         * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getThumbnail() {
          return thumbnail_;
        }
        /**
         * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder getThumbnailOrBuilder() {
          return thumbnail_;
        }

        // optional uint32 flags = 4;
        public static final int FLAGS_FIELD_NUMBER = 4;
        private int flags_;
        /**
         * <code>optional uint32 flags = 4;</code>
         */
        public boolean hasFlags() {
          return ((bitField0_ & 0x00000008) == 0x00000008);
        }
        /**
         * <code>optional uint32 flags = 4;</code>
         */
        public int getFlags() {
          return flags_;
        }

        private void initFields() {
          contentType_ = "";
          fileName_ = "";
          thumbnail_ = org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
          flags_ = 0;
        }
        private byte memoizedIsInitialized = -1;
        public final boolean isInitialized() {
          byte isInitialized = memoizedIsInitialized;
          if (isInitialized != -1) return isInitialized == 1;

          if (hasThumbnail()) {
            if (!getThumbnail().isInitialized()) {
              memoizedIsInitialized = 0;
              return false;
            }
          }
          memoizedIsInitialized = 1;
          return true;
        }

        public void writeTo(com.google.protobuf.CodedOutputStream output)
                            throws java.io.IOException {
          getSerializedSize();
          if (((bitField0_ & 0x00000001) == 0x00000001)) {
            output.writeBytes(1, getContentTypeBytes());
          }
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            output.writeBytes(2, getFileNameBytes());
          }
          if (((bitField0_ & 0x00000004) == 0x00000004)) {
            output.writeMessage(3, thumbnail_);
          }
          if (((bitField0_ & 0x00000008) == 0x00000008)) {
            output.writeUInt32(4, flags_);
          }
          getUnknownFields().writeTo(output);
        }

        private int memoizedSerializedSize = -1;
        public int getSerializedSize() {
          int size = memoizedSerializedSize;
          if (size != -1) return size;

          size = 0;
          if (((bitField0_ & 0x00000001) == 0x00000001)) {
            size += com.google.protobuf.CodedOutputStream
              .computeBytesSize(1, getContentTypeBytes());
          }
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            size += com.google.protobuf.CodedOutputStream
              .computeBytesSize(2, getFileNameBytes());
          }
          if (((bitField0_ & 0x00000004) == 0x00000004)) {
            size += com.google.protobuf.CodedOutputStream
              .computeMessageSize(3, thumbnail_);
          }
          if (((bitField0_ & 0x00000008) == 0x00000008)) {
            size += com.google.protobuf.CodedOutputStream
              .computeUInt32Size(4, flags_);
          }
          size += getUnknownFields().getSerializedSize();
          memoizedSerializedSize = size;
          return size;
        }

        private static final long serialVersionUID = 0L;
        @java.lang.Override
        protected java.lang.Object writeReplace()
            throws java.io.ObjectStreamException {
          return super.writeReplace();
        }

        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment parseFrom(
            com.google.protobuf.ByteString data)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return PARSER.parseFrom(data);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment parseFrom(
            com.google.protobuf.ByteString data,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return PARSER.parseFrom(data, extensionRegistry);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment parseFrom(byte[] data)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return PARSER.parseFrom(data);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment parseFrom(
            byte[] data,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return PARSER.parseFrom(data, extensionRegistry);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment parseFrom(java.io.InputStream input)
            throws java.io.IOException {
          return PARSER.parseFrom(input);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment parseFrom(
            java.io.InputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return PARSER.parseFrom(input, extensionRegistry);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment parseDelimitedFrom(java.io.InputStream input)
            throws java.io.IOException {
          return PARSER.parseDelimitedFrom(input);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment parseDelimitedFrom(
            java.io.InputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return PARSER.parseDelimitedFrom(input, extensionRegistry);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment parseFrom(
            com.google.protobuf.CodedInputStream input)
            throws java.io.IOException {
          return PARSER.parseFrom(input);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment parseFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return PARSER.parseFrom(input, extensionRegistry);
        }

        public static Builder newBuilder() { return Builder.create(); }
        public Builder newBuilderForType() { return newBuilder(); }
        public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment prototype) {
          return newBuilder().mergeFrom(prototype);
        }
        public Builder toBuilder() { return newBuilder(this); }

        @java.lang.Override
        protected Builder newBuilderForType(
            com.google.protobuf.GeneratedMessage.BuilderParent parent) {
          Builder builder = new Builder(parent);
          return builder;
        }
        /**
         * Protobuf type {@code signalservice.DataMessage.Quote.QuotedAttachment}
         */
        public static final class Builder extends
            com.google.protobuf.GeneratedMessage.Builder<Builder>
           implements org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachmentOrBuilder {
          public static final com.google.protobuf.Descriptors.Descriptor
              getDescriptor() {
            return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Quote_QuotedAttachment_descriptor;
          }

          protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
              internalGetFieldAccessorTable() {
            return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Quote_QuotedAttachment_fieldAccessorTable
                .ensureFieldAccessorsInitialized(
                    org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.Builder.class);
          }

          // Construct using org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.newBuilder()
          private Builder() {
            maybeForceBuilderInitialization();
          }

          private Builder(
              com.google.protobuf.GeneratedMessage.BuilderParent parent) {
            super(parent);
            maybeForceBuilderInitialization();
          }
          private void maybeForceBuilderInitialization() {
            if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
              getThumbnailFieldBuilder();
            }
          }
          private static Builder create() {
            return new Builder();
          }

          public Builder clear() {
            super.clear();
            contentType_ = "";
            bitField0_ = (bitField0_ & ~0x00000001);
            fileName_ = "";
            bitField0_ = (bitField0_ & ~0x00000002);
            if (thumbnailBuilder_ == null) {
              thumbnail_ = org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
            } else {
              thumbnailBuilder_.clear();
            }
            bitField0_ = (bitField0_ & ~0x00000004);
            flags_ = 0;
            bitField0_ = (bitField0_ & ~0x00000008);
            return this;
          }

          public Builder clone() {
            return create().mergeFrom(buildPartial());
          }

          public com.google.protobuf.Descriptors.Descriptor
              getDescriptorForType() {
            return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Quote_QuotedAttachment_descriptor;
          }

          public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment getDefaultInstanceForType() {
            return org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.getDefaultInstance();
          }

          public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment build() {
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment result = buildPartial();
            if (!result.isInitialized()) {
              throw newUninitializedMessageException(result);
            }
            return result;
          }

          public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment buildPartial() {
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment result = new org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment(this);
            int from_bitField0_ = bitField0_;
            int to_bitField0_ = 0;
            if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
              to_bitField0_ |= 0x00000001;
            }
            result.contentType_ = contentType_;
            if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
              to_bitField0_ |= 0x00000002;
            }
            result.fileName_ = fileName_;
            if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
              to_bitField0_ |= 0x00000004;
            }
            if (thumbnailBuilder_ == null) {
              result.thumbnail_ = thumbnail_;
            } else {
              result.thumbnail_ = thumbnailBuilder_.build();
            }
            if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
              to_bitField0_ |= 0x00000008;
            }
            result.flags_ = flags_;
            result.bitField0_ = to_bitField0_;
            onBuilt();
            return result;
          }

          public Builder mergeFrom(com.google.protobuf.Message other) {
            if (other instanceof org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment) {
              return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment)other);
            } else {
              super.mergeFrom(other);
              return this;
            }
          }

          public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment other) {
            if (other == org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.getDefaultInstance()) return this;
            if (other.hasContentType()) {
              bitField0_ |= 0x00000001;
              contentType_ = other.contentType_;
              onChanged();
            }
            if (other.hasFileName()) {
              bitField0_ |= 0x00000002;
              fileName_ = other.fileName_;
              onChanged();
            }
            if (other.hasThumbnail()) {
              mergeThumbnail(other.getThumbnail());
            }
            if (other.hasFlags()) {
              setFlags(other.getFlags());
            }
            this.mergeUnknownFields(other.getUnknownFields());
            return this;
          }

          public final boolean isInitialized() {
            if (hasThumbnail()) {
              if (!getThumbnail().isInitialized()) {
                
                return false;
              }
            }
            return true;
          }

          public Builder mergeFrom(
              com.google.protobuf.CodedInputStream input,
              com.google.protobuf.ExtensionRegistryLite extensionRegistry)
              throws java.io.IOException {
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment parsedMessage = null;
            try {
              parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
            } catch (com.google.protobuf.InvalidProtocolBufferException e) {
              parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment) e.getUnfinishedMessage();
              throw e;
            } finally {
              if (parsedMessage != null) {
                mergeFrom(parsedMessage);
              }
            }
            return this;
          }
          private int bitField0_;

          // optional string contentType = 1;
          private java.lang.Object contentType_ = "";
          /**
           * <code>optional string contentType = 1;</code>
           */
          public boolean hasContentType() {
            return ((bitField0_ & 0x00000001) == 0x00000001);
          }
          /**
           * <code>optional string contentType = 1;</code>
           */
          public java.lang.String getContentType() {
            java.lang.Object ref = contentType_;
            if (!(ref instanceof java.lang.String)) {
              java.lang.String s = ((com.google.protobuf.ByteString) ref)
                  .toStringUtf8();
              contentType_ = s;
              return s;
            } else {
              return (java.lang.String) ref;
            }
          }
          /**
           * <code>optional string contentType = 1;</code>
           */
          public com.google.protobuf.ByteString
              getContentTypeBytes() {
            java.lang.Object ref = contentType_;
            if (ref instanceof String) {
              com.google.protobuf.ByteString b = 
                  com.google.protobuf.ByteString.copyFromUtf8(
                      (java.lang.String) ref);
              contentType_ = b;
              return b;
            } else {
              return (com.google.protobuf.ByteString) ref;
            }
          }
          /**
           * <code>optional string contentType = 1;</code>
           */
          public Builder setContentType(
              java.lang.String value) {
            if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
            contentType_ = value;
            onChanged();
            return this;
          }
          /**
           * <code>optional string contentType = 1;</code>
           */
          public Builder clearContentType() {
            bitField0_ = (bitField0_ & ~0x00000001);
            contentType_ = getDefaultInstance().getContentType();
            onChanged();
            return this;
          }
          /**
           * <code>optional string contentType = 1;</code>
           */
          public Builder setContentTypeBytes(
              com.google.protobuf.ByteString value) {
            if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
            contentType_ = value;
            onChanged();
            return this;
          }

          // optional string fileName = 2;
          private java.lang.Object fileName_ = "";
          /**
           * <code>optional string fileName = 2;</code>
           */
          public boolean hasFileName() {
            return ((bitField0_ & 0x00000002) == 0x00000002);
          }
          /**
           * <code>optional string fileName = 2;</code>
           */
          public java.lang.String getFileName() {
            java.lang.Object ref = fileName_;
            if (!(ref instanceof java.lang.String)) {
              java.lang.String s = ((com.google.protobuf.ByteString) ref)
                  .toStringUtf8();
              fileName_ = s;
              return s;
            } else {
              return (java.lang.String) ref;
            }
          }
          /**
           * <code>optional string fileName = 2;</code>
           */
          public com.google.protobuf.ByteString
              getFileNameBytes() {
            java.lang.Object ref = fileName_;
            if (ref instanceof String) {
              com.google.protobuf.ByteString b = 
                  com.google.protobuf.ByteString.copyFromUtf8(
                      (java.lang.String) ref);
              fileName_ = b;
              return b;
            } else {
              return (com.google.protobuf.ByteString) ref;
            }
          }
          /**
           * <code>optional string fileName = 2;</code>
           */
          public Builder setFileName(
              java.lang.String value) {
            if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
            fileName_ = value;
            onChanged();
            return this;
          }
          /**
           * <code>optional string fileName = 2;</code>
           */
          public Builder clearFileName() {
            bitField0_ = (bitField0_ & ~0x00000002);
            fileName_ = getDefaultInstance().getFileName();
            onChanged();
            return this;
          }
          /**
           * <code>optional string fileName = 2;</code>
           */
          public Builder setFileNameBytes(
              com.google.protobuf.ByteString value) {
            if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
            fileName_ = value;
            onChanged();
            return this;
          }

          // optional .signalservice.AttachmentPointer thumbnail = 3;
          private org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer thumbnail_ = org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
          private com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder> thumbnailBuilder_;
          /**
           * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
           */
          public boolean hasThumbnail() {
            return ((bitField0_ & 0x00000004) == 0x00000004);
          }
          /**
           * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
           */
          public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getThumbnail() {
            if (thumbnailBuilder_ == null) {
              return thumbnail_;
            } else {
              return thumbnailBuilder_.getMessage();
            }
          }
          /**
           * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
           */
          public Builder setThumbnail(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer value) {
            if (thumbnailBuilder_ == null) {
              if (value == null) {
                throw new NullPointerException();
              }
              thumbnail_ = value;
              onChanged();
            } else {
              thumbnailBuilder_.setMessage(value);
            }
            bitField0_ |= 0x00000004;
            return this;
          }
          /**
           * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
           */
          public Builder setThumbnail(
              org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder builderForValue) {
            if (thumbnailBuilder_ == null) {
              thumbnail_ = builderForValue.build();
              onChanged();
            } else {
              thumbnailBuilder_.setMessage(builderForValue.build());
            }
            bitField0_ |= 0x00000004;
            return this;
          }
          /**
           * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
           */
          public Builder mergeThumbnail(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer value) {
            if (thumbnailBuilder_ == null) {
              if (((bitField0_ & 0x00000004) == 0x00000004) &&
                  thumbnail_ != org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance()) {
                thumbnail_ =
                  org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.newBuilder(thumbnail_).mergeFrom(value).buildPartial();
              } else {
                thumbnail_ = value;
              }
              onChanged();
            } else {
              thumbnailBuilder_.mergeFrom(value);
            }
            bitField0_ |= 0x00000004;
            return this;
          }
          /**
           * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
           */
          public Builder clearThumbnail() {
            if (thumbnailBuilder_ == null) {
              thumbnail_ = org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
              onChanged();
            } else {
              thumbnailBuilder_.clear();
            }
            bitField0_ = (bitField0_ & ~0x00000004);
            return this;
          }
          /**
           * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
           */
          public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder getThumbnailBuilder() {
            bitField0_ |= 0x00000004;
            onChanged();
            return getThumbnailFieldBuilder().getBuilder();
          }
          /**
           * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
           */
          public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder getThumbnailOrBuilder() {
            if (thumbnailBuilder_ != null) {
              return thumbnailBuilder_.getMessageOrBuilder();
            } else {
              return thumbnail_;
            }
          }
          /**
           * <code>optional .signalservice.AttachmentPointer thumbnail = 3;</code>
           */
          private com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder> 
              getThumbnailFieldBuilder() {
            if (thumbnailBuilder_ == null) {
              thumbnailBuilder_ = new com.google.protobuf.SingleFieldBuilder<
                  org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder>(
                      thumbnail_,
                      getParentForChildren(),
                      isClean());
              thumbnail_ = null;
            }
            return thumbnailBuilder_;
          }

          // optional uint32 flags = 4;
          private int flags_ ;
          /**
           * <code>optional uint32 flags = 4;</code>
           */
          public boolean hasFlags() {
            return ((bitField0_ & 0x00000008) == 0x00000008);
          }
          /**
           * <code>optional uint32 flags = 4;</code>
           */
          public int getFlags() {
            return flags_;
          }
          /**
           * <code>optional uint32 flags = 4;</code>
           */
          public Builder setFlags(int value) {
            bitField0_ |= 0x00000008;
            flags_ = value;
            onChanged();
            return this;
          }
          /**
           * <code>optional uint32 flags = 4;</code>
           */
          public Builder clearFlags() {
            bitField0_ = (bitField0_ & ~0x00000008);
            flags_ = 0;
            onChanged();
            return this;
          }

          // @@protoc_insertion_point(builder_scope:signalservice.DataMessage.Quote.QuotedAttachment)
        }

        static {
          defaultInstance = new QuotedAttachment(true);
          defaultInstance.initFields();
        }

        // @@protoc_insertion_point(class_scope:signalservice.DataMessage.Quote.QuotedAttachment)
      }

      private int bitField0_;
      // required uint64 id = 1;
      public static final int ID_FIELD_NUMBER = 1;
      private long id_;
      /**
       * <code>required uint64 id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasId() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required uint64 id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public long getId() {
        return id_;
      }

      // required string author = 2;
      public static final int AUTHOR_FIELD_NUMBER = 2;
      private java.lang.Object author_;
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasAuthor() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public java.lang.String getAuthor() {
        java.lang.Object ref = author_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            author_ = s;
          }
          return s;
        }
      }
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public com.google.protobuf.ByteString
          getAuthorBytes() {
        java.lang.Object ref = author_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          author_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // optional string text = 3;
      public static final int TEXT_FIELD_NUMBER = 3;
      private java.lang.Object text_;
      /**
       * <code>optional string text = 3;</code>
       */
      public boolean hasText() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional string text = 3;</code>
       */
      public java.lang.String getText() {
        java.lang.Object ref = text_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            text_ = s;
          }
          return s;
        }
      }
      /**
       * <code>optional string text = 3;</code>
       */
      public com.google.protobuf.ByteString
          getTextBytes() {
        java.lang.Object ref = text_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          text_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;
      public static final int ATTACHMENTS_FIELD_NUMBER = 4;
      private java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment> attachments_;
      /**
       * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
       */
      public java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment> getAttachmentsList() {
        return attachments_;
      }
      /**
       * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
       */
      public java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachmentOrBuilder> 
          getAttachmentsOrBuilderList() {
        return attachments_;
      }
      /**
       * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
       */
      public int getAttachmentsCount() {
        return attachments_.size();
      }
      /**
       * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment getAttachments(int index) {
        return attachments_.get(index);
      }
      /**
       * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachmentOrBuilder getAttachmentsOrBuilder(
          int index) {
        return attachments_.get(index);
      }

      private void initFields() {
        id_ = 0L;
        author_ = "";
        text_ = "";
        attachments_ = java.util.Collections.emptyList();
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;

        if (!hasId()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasAuthor()) {
          memoizedIsInitialized = 0;
          return false;
        }
        for (int i = 0; i < getAttachmentsCount(); i++) {
          if (!getAttachments(i).isInitialized()) {
            memoizedIsInitialized = 0;
            return false;
          }
        }
        memoizedIsInitialized = 1;
        return true;
      }

      public void writeTo(com.google.protobuf.CodedOutputStream output)
                          throws java.io.IOException {
        getSerializedSize();
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          output.writeUInt64(1, id_);
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(2, getAuthorBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          output.writeBytes(3, getTextBytes());
        }
        for (int i = 0; i < attachments_.size(); i++) {
          output.writeMessage(4, attachments_.get(i));
        }
        getUnknownFields().writeTo(output);
      }

      private int memoizedSerializedSize = -1;
      public int getSerializedSize() {
        int size = memoizedSerializedSize;
        if (size != -1) return size;

        size = 0;
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          size += com.google.protobuf.CodedOutputStream
            .computeUInt64Size(1, id_);
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(2, getAuthorBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(3, getTextBytes());
        }
        for (int i = 0; i < attachments_.size(); i++) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(4, attachments_.get(i));
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }

      private static final long serialVersionUID = 0L;
      @java.lang.Override
      protected java.lang.Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }

      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }

      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }

      @java.lang.Override
      protected Builder newBuilderForType(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      /**
       * Protobuf type {@code signalservice.DataMessage.Quote}
       */
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements org.session.libsignal.protos.SignalServiceProtos.DataMessage.QuoteOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Quote_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Quote_fieldAccessorTable
              .ensureFieldAccessorsInitialized(
                  org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.Builder.class);
        }

        // Construct using org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }

        private Builder(
            com.google.protobuf.GeneratedMessage.BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
            getAttachmentsFieldBuilder();
          }
        }
        private static Builder create() {
          return new Builder();
        }

        public Builder clear() {
          super.clear();
          id_ = 0L;
          bitField0_ = (bitField0_ & ~0x00000001);
          author_ = "";
          bitField0_ = (bitField0_ & ~0x00000002);
          text_ = "";
          bitField0_ = (bitField0_ & ~0x00000004);
          if (attachmentsBuilder_ == null) {
            attachments_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000008);
          } else {
            attachmentsBuilder_.clear();
          }
          return this;
        }

        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }

        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Quote_descriptor;
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote getDefaultInstanceForType() {
          return org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.getDefaultInstance();
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote build() {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote buildPartial() {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote result = new org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.id_ = id_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.author_ = author_;
          if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
            to_bitField0_ |= 0x00000004;
          }
          result.text_ = text_;
          if (attachmentsBuilder_ == null) {
            if (((bitField0_ & 0x00000008) == 0x00000008)) {
              attachments_ = java.util.Collections.unmodifiableList(attachments_);
              bitField0_ = (bitField0_ & ~0x00000008);
            }
            result.attachments_ = attachments_;
          } else {
            result.attachments_ = attachmentsBuilder_.build();
          }
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }

        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote) {
            return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }

        public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote other) {
          if (other == org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.getDefaultInstance()) return this;
          if (other.hasId()) {
            setId(other.getId());
          }
          if (other.hasAuthor()) {
            bitField0_ |= 0x00000002;
            author_ = other.author_;
            onChanged();
          }
          if (other.hasText()) {
            bitField0_ |= 0x00000004;
            text_ = other.text_;
            onChanged();
          }
          if (attachmentsBuilder_ == null) {
            if (!other.attachments_.isEmpty()) {
              if (attachments_.isEmpty()) {
                attachments_ = other.attachments_;
                bitField0_ = (bitField0_ & ~0x00000008);
              } else {
                ensureAttachmentsIsMutable();
                attachments_.addAll(other.attachments_);
              }
              onChanged();
            }
          } else {
            if (!other.attachments_.isEmpty()) {
              if (attachmentsBuilder_.isEmpty()) {
                attachmentsBuilder_.dispose();
                attachmentsBuilder_ = null;
                attachments_ = other.attachments_;
                bitField0_ = (bitField0_ & ~0x00000008);
                attachmentsBuilder_ = 
                  com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                     getAttachmentsFieldBuilder() : null;
              } else {
                attachmentsBuilder_.addAllMessages(other.attachments_);
              }
            }
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }

        public final boolean isInitialized() {
          if (!hasId()) {
            
            return false;
          }
          if (!hasAuthor()) {
            
            return false;
          }
          for (int i = 0; i < getAttachmentsCount(); i++) {
            if (!getAttachments(i).isInitialized()) {
              
              return false;
            }
          }
          return true;
        }

        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote parsedMessage = null;
          try {
            parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
            parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote) e.getUnfinishedMessage();
            throw e;
          } finally {
            if (parsedMessage != null) {
              mergeFrom(parsedMessage);
            }
          }
          return this;
        }
        private int bitField0_;

        // required uint64 id = 1;
        private long id_ ;
        /**
         * <code>required uint64 id = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasId() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>required uint64 id = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public long getId() {
          return id_;
        }
        /**
         * <code>required uint64 id = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setId(long value) {
          bitField0_ |= 0x00000001;
          id_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required uint64 id = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder clearId() {
          bitField0_ = (bitField0_ & ~0x00000001);
          id_ = 0L;
          onChanged();
          return this;
        }

        // required string author = 2;
        private java.lang.Object author_ = "";
        /**
         * <code>required string author = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasAuthor() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>required string author = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public java.lang.String getAuthor() {
          java.lang.Object ref = author_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            author_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>required string author = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public com.google.protobuf.ByteString
            getAuthorBytes() {
          java.lang.Object ref = author_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            author_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>required string author = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setAuthor(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          author_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required string author = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder clearAuthor() {
          bitField0_ = (bitField0_ & ~0x00000002);
          author_ = getDefaultInstance().getAuthor();
          onChanged();
          return this;
        }
        /**
         * <code>required string author = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setAuthorBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          author_ = value;
          onChanged();
          return this;
        }

        // optional string text = 3;
        private java.lang.Object text_ = "";
        /**
         * <code>optional string text = 3;</code>
         */
        public boolean hasText() {
          return ((bitField0_ & 0x00000004) == 0x00000004);
        }
        /**
         * <code>optional string text = 3;</code>
         */
        public java.lang.String getText() {
          java.lang.Object ref = text_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            text_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>optional string text = 3;</code>
         */
        public com.google.protobuf.ByteString
            getTextBytes() {
          java.lang.Object ref = text_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            text_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>optional string text = 3;</code>
         */
        public Builder setText(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
          text_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional string text = 3;</code>
         */
        public Builder clearText() {
          bitField0_ = (bitField0_ & ~0x00000004);
          text_ = getDefaultInstance().getText();
          onChanged();
          return this;
        }
        /**
         * <code>optional string text = 3;</code>
         */
        public Builder setTextBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
          text_ = value;
          onChanged();
          return this;
        }

        // repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;
        private java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment> attachments_ =
          java.util.Collections.emptyList();
        private void ensureAttachmentsIsMutable() {
          if (!((bitField0_ & 0x00000008) == 0x00000008)) {
            attachments_ = new java.util.ArrayList<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment>(attachments_);
            bitField0_ |= 0x00000008;
           }
        }

        private com.google.protobuf.RepeatedFieldBuilder<
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachmentOrBuilder> attachmentsBuilder_;

        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment> getAttachmentsList() {
          if (attachmentsBuilder_ == null) {
            return java.util.Collections.unmodifiableList(attachments_);
          } else {
            return attachmentsBuilder_.getMessageList();
          }
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public int getAttachmentsCount() {
          if (attachmentsBuilder_ == null) {
            return attachments_.size();
          } else {
            return attachmentsBuilder_.getCount();
          }
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment getAttachments(int index) {
          if (attachmentsBuilder_ == null) {
            return attachments_.get(index);
          } else {
            return attachmentsBuilder_.getMessage(index);
          }
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public Builder setAttachments(
            int index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment value) {
          if (attachmentsBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureAttachmentsIsMutable();
            attachments_.set(index, value);
            onChanged();
          } else {
            attachmentsBuilder_.setMessage(index, value);
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public Builder setAttachments(
            int index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.Builder builderForValue) {
          if (attachmentsBuilder_ == null) {
            ensureAttachmentsIsMutable();
            attachments_.set(index, builderForValue.build());
            onChanged();
          } else {
            attachmentsBuilder_.setMessage(index, builderForValue.build());
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public Builder addAttachments(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment value) {
          if (attachmentsBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureAttachmentsIsMutable();
            attachments_.add(value);
            onChanged();
          } else {
            attachmentsBuilder_.addMessage(value);
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public Builder addAttachments(
            int index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment value) {
          if (attachmentsBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureAttachmentsIsMutable();
            attachments_.add(index, value);
            onChanged();
          } else {
            attachmentsBuilder_.addMessage(index, value);
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public Builder addAttachments(
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.Builder builderForValue) {
          if (attachmentsBuilder_ == null) {
            ensureAttachmentsIsMutable();
            attachments_.add(builderForValue.build());
            onChanged();
          } else {
            attachmentsBuilder_.addMessage(builderForValue.build());
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public Builder addAttachments(
            int index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.Builder builderForValue) {
          if (attachmentsBuilder_ == null) {
            ensureAttachmentsIsMutable();
            attachments_.add(index, builderForValue.build());
            onChanged();
          } else {
            attachmentsBuilder_.addMessage(index, builderForValue.build());
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public Builder addAllAttachments(
            java.lang.Iterable<? extends org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment> values) {
          if (attachmentsBuilder_ == null) {
            ensureAttachmentsIsMutable();
            super.addAll(values, attachments_);
            onChanged();
          } else {
            attachmentsBuilder_.addAllMessages(values);
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public Builder clearAttachments() {
          if (attachmentsBuilder_ == null) {
            attachments_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000008);
            onChanged();
          } else {
            attachmentsBuilder_.clear();
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public Builder removeAttachments(int index) {
          if (attachmentsBuilder_ == null) {
            ensureAttachmentsIsMutable();
            attachments_.remove(index);
            onChanged();
          } else {
            attachmentsBuilder_.remove(index);
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.Builder getAttachmentsBuilder(
            int index) {
          return getAttachmentsFieldBuilder().getBuilder(index);
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachmentOrBuilder getAttachmentsOrBuilder(
            int index) {
          if (attachmentsBuilder_ == null) {
            return attachments_.get(index);  } else {
            return attachmentsBuilder_.getMessageOrBuilder(index);
          }
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachmentOrBuilder> 
             getAttachmentsOrBuilderList() {
          if (attachmentsBuilder_ != null) {
            return attachmentsBuilder_.getMessageOrBuilderList();
          } else {
            return java.util.Collections.unmodifiableList(attachments_);
          }
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.Builder addAttachmentsBuilder() {
          return getAttachmentsFieldBuilder().addBuilder(
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.getDefaultInstance());
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.Builder addAttachmentsBuilder(
            int index) {
          return getAttachmentsFieldBuilder().addBuilder(
              index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.getDefaultInstance());
        }
        /**
         * <code>repeated .signalservice.DataMessage.Quote.QuotedAttachment attachments = 4;</code>
         */
        public java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.Builder> 
             getAttachmentsBuilderList() {
          return getAttachmentsFieldBuilder().getBuilderList();
        }
        private com.google.protobuf.RepeatedFieldBuilder<
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachmentOrBuilder> 
            getAttachmentsFieldBuilder() {
          if (attachmentsBuilder_ == null) {
            attachmentsBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
                org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachment.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.QuotedAttachmentOrBuilder>(
                    attachments_,
                    ((bitField0_ & 0x00000008) == 0x00000008),
                    getParentForChildren(),
                    isClean());
            attachments_ = null;
          }
          return attachmentsBuilder_;
        }

        // @@protoc_insertion_point(builder_scope:signalservice.DataMessage.Quote)
      }

      static {
        defaultInstance = new Quote(true);
        defaultInstance.initFields();
      }

      // @@protoc_insertion_point(class_scope:signalservice.DataMessage.Quote)
    }

    public interface PreviewOrBuilder
        extends com.google.protobuf.MessageOrBuilder {

      // required string url = 1;
      /**
       * <code>required string url = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      boolean hasUrl();
      /**
       * <code>required string url = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      java.lang.String getUrl();
      /**
       * <code>required string url = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      com.google.protobuf.ByteString
          getUrlBytes();

      // optional string title = 2;
      /**
       * <code>optional string title = 2;</code>
       */
      boolean hasTitle();
      /**
       * <code>optional string title = 2;</code>
       */
      java.lang.String getTitle();
      /**
       * <code>optional string title = 2;</code>
       */
      com.google.protobuf.ByteString
          getTitleBytes();

      // optional .signalservice.AttachmentPointer image = 3;
      /**
       * <code>optional .signalservice.AttachmentPointer image = 3;</code>
       */
      boolean hasImage();
      /**
       * <code>optional .signalservice.AttachmentPointer image = 3;</code>
       */
      org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getImage();
      /**
       * <code>optional .signalservice.AttachmentPointer image = 3;</code>
       */
      org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder getImageOrBuilder();
    }
    /**
     * Protobuf type {@code signalservice.DataMessage.Preview}
     */
    public static final class Preview extends
        com.google.protobuf.GeneratedMessage
        implements PreviewOrBuilder {
      // Use Preview.newBuilder() to construct.
      private Preview(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
        super(builder);
        this.unknownFields = builder.getUnknownFields();
      }
      private Preview(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

      private static final Preview defaultInstance;
      public static Preview getDefaultInstance() {
        return defaultInstance;
      }

      public Preview getDefaultInstanceForType() {
        return defaultInstance;
      }

      private final com.google.protobuf.UnknownFieldSet unknownFields;
      @java.lang.Override
      public final com.google.protobuf.UnknownFieldSet
          getUnknownFields() {
        return this.unknownFields;
      }
      private Preview(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        initFields();
        int mutable_bitField0_ = 0;
        com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder();
        try {
          boolean done = false;
          while (!done) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                done = true;
                break;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  done = true;
                }
                break;
              }
              case 10: {
                bitField0_ |= 0x00000001;
                url_ = input.readBytes();
                break;
              }
              case 18: {
                bitField0_ |= 0x00000002;
                title_ = input.readBytes();
                break;
              }
              case 26: {
                org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder subBuilder = null;
                if (((bitField0_ & 0x00000004) == 0x00000004)) {
                  subBuilder = image_.toBuilder();
                }
                image_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.PARSER, extensionRegistry);
                if (subBuilder != null) {
                  subBuilder.mergeFrom(image_);
                  image_ = subBuilder.buildPartial();
                }
                bitField0_ |= 0x00000004;
                break;
              }
            }
          }
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          throw e.setUnfinishedMessage(this);
        } catch (java.io.IOException e) {
          throw new com.google.protobuf.InvalidProtocolBufferException(
              e.getMessage()).setUnfinishedMessage(this);
        } finally {
          this.unknownFields = unknownFields.build();
          makeExtensionsImmutable();
        }
      }
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Preview_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Preview_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.Builder.class);
      }

      public static com.google.protobuf.Parser<Preview> PARSER =
          new com.google.protobuf.AbstractParser<Preview>() {
        public Preview parsePartialFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return new Preview(input, extensionRegistry);
        }
      };

      @java.lang.Override
      public com.google.protobuf.Parser<Preview> getParserForType() {
        return PARSER;
      }

      private int bitField0_;
      // required string url = 1;
      public static final int URL_FIELD_NUMBER = 1;
      private java.lang.Object url_;
      /**
       * <code>required string url = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasUrl() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required string url = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public java.lang.String getUrl() {
        java.lang.Object ref = url_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            url_ = s;
          }
          return s;
        }
      }
      /**
       * <code>required string url = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public com.google.protobuf.ByteString
          getUrlBytes() {
        java.lang.Object ref = url_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          url_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // optional string title = 2;
      public static final int TITLE_FIELD_NUMBER = 2;
      private java.lang.Object title_;
      /**
       * <code>optional string title = 2;</code>
       */
      public boolean hasTitle() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>optional string title = 2;</code>
       */
      public java.lang.String getTitle() {
        java.lang.Object ref = title_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            title_ = s;
          }
          return s;
        }
      }
      /**
       * <code>optional string title = 2;</code>
       */
      public com.google.protobuf.ByteString
          getTitleBytes() {
        java.lang.Object ref = title_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          title_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // optional .signalservice.AttachmentPointer image = 3;
      public static final int IMAGE_FIELD_NUMBER = 3;
      private org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer image_;
      /**
       * <code>optional .signalservice.AttachmentPointer image = 3;</code>
       */
      public boolean hasImage() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional .signalservice.AttachmentPointer image = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getImage() {
        return image_;
      }
      /**
       * <code>optional .signalservice.AttachmentPointer image = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder getImageOrBuilder() {
        return image_;
      }

      private void initFields() {
        url_ = "";
        title_ = "";
        image_ = org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;

        if (!hasUrl()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (hasImage()) {
          if (!getImage().isInitialized()) {
            memoizedIsInitialized = 0;
            return false;
          }
        }
        memoizedIsInitialized = 1;
        return true;
      }

      public void writeTo(com.google.protobuf.CodedOutputStream output)
                          throws java.io.IOException {
        getSerializedSize();
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          output.writeBytes(1, getUrlBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(2, getTitleBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          output.writeMessage(3, image_);
        }
        getUnknownFields().writeTo(output);
      }

      private int memoizedSerializedSize = -1;
      public int getSerializedSize() {
        int size = memoizedSerializedSize;
        if (size != -1) return size;

        size = 0;
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(1, getUrlBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(2, getTitleBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(3, image_);
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }

      private static final long serialVersionUID = 0L;
      @java.lang.Override
      protected java.lang.Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }

      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }

      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }

      @java.lang.Override
      protected Builder newBuilderForType(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      /**
       * Protobuf type {@code signalservice.DataMessage.Preview}
       */
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements org.session.libsignal.protos.SignalServiceProtos.DataMessage.PreviewOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Preview_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Preview_fieldAccessorTable
              .ensureFieldAccessorsInitialized(
                  org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.Builder.class);
        }

        // Construct using org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }

        private Builder(
            com.google.protobuf.GeneratedMessage.BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
            getImageFieldBuilder();
          }
        }
        private static Builder create() {
          return new Builder();
        }

        public Builder clear() {
          super.clear();
          url_ = "";
          bitField0_ = (bitField0_ & ~0x00000001);
          title_ = "";
          bitField0_ = (bitField0_ & ~0x00000002);
          if (imageBuilder_ == null) {
            image_ = org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
          } else {
            imageBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000004);
          return this;
        }

        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }

        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Preview_descriptor;
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview getDefaultInstanceForType() {
          return org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.getDefaultInstance();
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview build() {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview buildPartial() {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview result = new org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.url_ = url_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.title_ = title_;
          if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
            to_bitField0_ |= 0x00000004;
          }
          if (imageBuilder_ == null) {
            result.image_ = image_;
          } else {
            result.image_ = imageBuilder_.build();
          }
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }

        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview) {
            return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }

        public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview other) {
          if (other == org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.getDefaultInstance()) return this;
          if (other.hasUrl()) {
            bitField0_ |= 0x00000001;
            url_ = other.url_;
            onChanged();
          }
          if (other.hasTitle()) {
            bitField0_ |= 0x00000002;
            title_ = other.title_;
            onChanged();
          }
          if (other.hasImage()) {
            mergeImage(other.getImage());
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }

        public final boolean isInitialized() {
          if (!hasUrl()) {
            
            return false;
          }
          if (hasImage()) {
            if (!getImage().isInitialized()) {
              
              return false;
            }
          }
          return true;
        }

        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview parsedMessage = null;
          try {
            parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
            parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview) e.getUnfinishedMessage();
            throw e;
          } finally {
            if (parsedMessage != null) {
              mergeFrom(parsedMessage);
            }
          }
          return this;
        }
        private int bitField0_;

        // required string url = 1;
        private java.lang.Object url_ = "";
        /**
         * <code>required string url = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasUrl() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>required string url = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public java.lang.String getUrl() {
          java.lang.Object ref = url_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            url_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>required string url = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public com.google.protobuf.ByteString
            getUrlBytes() {
          java.lang.Object ref = url_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            url_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>required string url = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setUrl(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
          url_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required string url = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder clearUrl() {
          bitField0_ = (bitField0_ & ~0x00000001);
          url_ = getDefaultInstance().getUrl();
          onChanged();
          return this;
        }
        /**
         * <code>required string url = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setUrlBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
          url_ = value;
          onChanged();
          return this;
        }

        // optional string title = 2;
        private java.lang.Object title_ = "";
        /**
         * <code>optional string title = 2;</code>
         */
        public boolean hasTitle() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>optional string title = 2;</code>
         */
        public java.lang.String getTitle() {
          java.lang.Object ref = title_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            title_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>optional string title = 2;</code>
         */
        public com.google.protobuf.ByteString
            getTitleBytes() {
          java.lang.Object ref = title_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            title_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>optional string title = 2;</code>
         */
        public Builder setTitle(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          title_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional string title = 2;</code>
         */
        public Builder clearTitle() {
          bitField0_ = (bitField0_ & ~0x00000002);
          title_ = getDefaultInstance().getTitle();
          onChanged();
          return this;
        }
        /**
         * <code>optional string title = 2;</code>
         */
        public Builder setTitleBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          title_ = value;
          onChanged();
          return this;
        }

        // optional .signalservice.AttachmentPointer image = 3;
        private org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer image_ = org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
        private com.google.protobuf.SingleFieldBuilder<
            org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder> imageBuilder_;
        /**
         * <code>optional .signalservice.AttachmentPointer image = 3;</code>
         */
        public boolean hasImage() {
          return ((bitField0_ & 0x00000004) == 0x00000004);
        }
        /**
         * <code>optional .signalservice.AttachmentPointer image = 3;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getImage() {
          if (imageBuilder_ == null) {
            return image_;
          } else {
            return imageBuilder_.getMessage();
          }
        }
        /**
         * <code>optional .signalservice.AttachmentPointer image = 3;</code>
         */
        public Builder setImage(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer value) {
          if (imageBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            image_ = value;
            onChanged();
          } else {
            imageBuilder_.setMessage(value);
          }
          bitField0_ |= 0x00000004;
          return this;
        }
        /**
         * <code>optional .signalservice.AttachmentPointer image = 3;</code>
         */
        public Builder setImage(
            org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder builderForValue) {
          if (imageBuilder_ == null) {
            image_ = builderForValue.build();
            onChanged();
          } else {
            imageBuilder_.setMessage(builderForValue.build());
          }
          bitField0_ |= 0x00000004;
          return this;
        }
        /**
         * <code>optional .signalservice.AttachmentPointer image = 3;</code>
         */
        public Builder mergeImage(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer value) {
          if (imageBuilder_ == null) {
            if (((bitField0_ & 0x00000004) == 0x00000004) &&
                image_ != org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance()) {
              image_ =
                org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.newBuilder(image_).mergeFrom(value).buildPartial();
            } else {
              image_ = value;
            }
            onChanged();
          } else {
            imageBuilder_.mergeFrom(value);
          }
          bitField0_ |= 0x00000004;
          return this;
        }
        /**
         * <code>optional .signalservice.AttachmentPointer image = 3;</code>
         */
        public Builder clearImage() {
          if (imageBuilder_ == null) {
            image_ = org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
            onChanged();
          } else {
            imageBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000004);
          return this;
        }
        /**
         * <code>optional .signalservice.AttachmentPointer image = 3;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder getImageBuilder() {
          bitField0_ |= 0x00000004;
          onChanged();
          return getImageFieldBuilder().getBuilder();
        }
        /**
         * <code>optional .signalservice.AttachmentPointer image = 3;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder getImageOrBuilder() {
          if (imageBuilder_ != null) {
            return imageBuilder_.getMessageOrBuilder();
          } else {
            return image_;
          }
        }
        /**
         * <code>optional .signalservice.AttachmentPointer image = 3;</code>
         */
        private com.google.protobuf.SingleFieldBuilder<
            org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder> 
            getImageFieldBuilder() {
          if (imageBuilder_ == null) {
            imageBuilder_ = new com.google.protobuf.SingleFieldBuilder<
                org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder>(
                    image_,
                    getParentForChildren(),
                    isClean());
            image_ = null;
          }
          return imageBuilder_;
        }

        // @@protoc_insertion_point(builder_scope:signalservice.DataMessage.Preview)
      }

      static {
        defaultInstance = new Preview(true);
        defaultInstance.initFields();
      }

      // @@protoc_insertion_point(class_scope:signalservice.DataMessage.Preview)
    }

    public interface LokiProfileOrBuilder
        extends com.google.protobuf.MessageOrBuilder {

      // optional string displayName = 1;
      /**
       * <code>optional string displayName = 1;</code>
       */
      boolean hasDisplayName();
      /**
       * <code>optional string displayName = 1;</code>
       */
      java.lang.String getDisplayName();
      /**
       * <code>optional string displayName = 1;</code>
       */
      com.google.protobuf.ByteString
          getDisplayNameBytes();

      // optional string profilePicture = 2;
      /**
       * <code>optional string profilePicture = 2;</code>
       */
      boolean hasProfilePicture();
      /**
       * <code>optional string profilePicture = 2;</code>
       */
      java.lang.String getProfilePicture();
      /**
       * <code>optional string profilePicture = 2;</code>
       */
      com.google.protobuf.ByteString
          getProfilePictureBytes();
    }
    /**
     * Protobuf type {@code signalservice.DataMessage.LokiProfile}
     */
    public static final class LokiProfile extends
        com.google.protobuf.GeneratedMessage
        implements LokiProfileOrBuilder {
      // Use LokiProfile.newBuilder() to construct.
      private LokiProfile(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
        super(builder);
        this.unknownFields = builder.getUnknownFields();
      }
      private LokiProfile(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

      private static final LokiProfile defaultInstance;
      public static LokiProfile getDefaultInstance() {
        return defaultInstance;
      }

      public LokiProfile getDefaultInstanceForType() {
        return defaultInstance;
      }

      private final com.google.protobuf.UnknownFieldSet unknownFields;
      @java.lang.Override
      public final com.google.protobuf.UnknownFieldSet
          getUnknownFields() {
        return this.unknownFields;
      }
      private LokiProfile(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        initFields();
        int mutable_bitField0_ = 0;
        com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder();
        try {
          boolean done = false;
          while (!done) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                done = true;
                break;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  done = true;
                }
                break;
              }
              case 10: {
                bitField0_ |= 0x00000001;
                displayName_ = input.readBytes();
                break;
              }
              case 18: {
                bitField0_ |= 0x00000002;
                profilePicture_ = input.readBytes();
                break;
              }
            }
          }
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          throw e.setUnfinishedMessage(this);
        } catch (java.io.IOException e) {
          throw new com.google.protobuf.InvalidProtocolBufferException(
              e.getMessage()).setUnfinishedMessage(this);
        } finally {
          this.unknownFields = unknownFields.build();
          makeExtensionsImmutable();
        }
      }
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_LokiProfile_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_LokiProfile_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder.class);
      }

      public static com.google.protobuf.Parser<LokiProfile> PARSER =
          new com.google.protobuf.AbstractParser<LokiProfile>() {
        public LokiProfile parsePartialFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return new LokiProfile(input, extensionRegistry);
        }
      };

      @java.lang.Override
      public com.google.protobuf.Parser<LokiProfile> getParserForType() {
        return PARSER;
      }

      private int bitField0_;
      // optional string displayName = 1;
      public static final int DISPLAYNAME_FIELD_NUMBER = 1;
      private java.lang.Object displayName_;
      /**
       * <code>optional string displayName = 1;</code>
       */
      public boolean hasDisplayName() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>optional string displayName = 1;</code>
       */
      public java.lang.String getDisplayName() {
        java.lang.Object ref = displayName_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            displayName_ = s;
          }
          return s;
        }
      }
      /**
       * <code>optional string displayName = 1;</code>
       */
      public com.google.protobuf.ByteString
          getDisplayNameBytes() {
        java.lang.Object ref = displayName_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          displayName_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // optional string profilePicture = 2;
      public static final int PROFILEPICTURE_FIELD_NUMBER = 2;
      private java.lang.Object profilePicture_;
      /**
       * <code>optional string profilePicture = 2;</code>
       */
      public boolean hasProfilePicture() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>optional string profilePicture = 2;</code>
       */
      public java.lang.String getProfilePicture() {
        java.lang.Object ref = profilePicture_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            profilePicture_ = s;
          }
          return s;
        }
      }
      /**
       * <code>optional string profilePicture = 2;</code>
       */
      public com.google.protobuf.ByteString
          getProfilePictureBytes() {
        java.lang.Object ref = profilePicture_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          profilePicture_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      private void initFields() {
        displayName_ = "";
        profilePicture_ = "";
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;

        memoizedIsInitialized = 1;
        return true;
      }

      public void writeTo(com.google.protobuf.CodedOutputStream output)
                          throws java.io.IOException {
        getSerializedSize();
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          output.writeBytes(1, getDisplayNameBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(2, getProfilePictureBytes());
        }
        getUnknownFields().writeTo(output);
      }

      private int memoizedSerializedSize = -1;
      public int getSerializedSize() {
        int size = memoizedSerializedSize;
        if (size != -1) return size;

        size = 0;
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(1, getDisplayNameBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(2, getProfilePictureBytes());
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }

      private static final long serialVersionUID = 0L;
      @java.lang.Override
      protected java.lang.Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }

      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }

      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }

      @java.lang.Override
      protected Builder newBuilderForType(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      /**
       * Protobuf type {@code signalservice.DataMessage.LokiProfile}
       */
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_LokiProfile_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_LokiProfile_fieldAccessorTable
              .ensureFieldAccessorsInitialized(
                  org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder.class);
        }

        // Construct using org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }

        private Builder(
            com.google.protobuf.GeneratedMessage.BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
          }
        }
        private static Builder create() {
          return new Builder();
        }

        public Builder clear() {
          super.clear();
          displayName_ = "";
          bitField0_ = (bitField0_ & ~0x00000001);
          profilePicture_ = "";
          bitField0_ = (bitField0_ & ~0x00000002);
          return this;
        }

        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }

        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_LokiProfile_descriptor;
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile getDefaultInstanceForType() {
          return org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.getDefaultInstance();
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile build() {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile buildPartial() {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile result = new org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.displayName_ = displayName_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.profilePicture_ = profilePicture_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }

        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile) {
            return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }

        public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile other) {
          if (other == org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.getDefaultInstance()) return this;
          if (other.hasDisplayName()) {
            bitField0_ |= 0x00000001;
            displayName_ = other.displayName_;
            onChanged();
          }
          if (other.hasProfilePicture()) {
            bitField0_ |= 0x00000002;
            profilePicture_ = other.profilePicture_;
            onChanged();
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }

        public final boolean isInitialized() {
          return true;
        }

        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile parsedMessage = null;
          try {
            parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
            parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile) e.getUnfinishedMessage();
            throw e;
          } finally {
            if (parsedMessage != null) {
              mergeFrom(parsedMessage);
            }
          }
          return this;
        }
        private int bitField0_;

        // optional string displayName = 1;
        private java.lang.Object displayName_ = "";
        /**
         * <code>optional string displayName = 1;</code>
         */
        public boolean hasDisplayName() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>optional string displayName = 1;</code>
         */
        public java.lang.String getDisplayName() {
          java.lang.Object ref = displayName_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            displayName_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>optional string displayName = 1;</code>
         */
        public com.google.protobuf.ByteString
            getDisplayNameBytes() {
          java.lang.Object ref = displayName_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            displayName_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>optional string displayName = 1;</code>
         */
        public Builder setDisplayName(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
          displayName_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional string displayName = 1;</code>
         */
        public Builder clearDisplayName() {
          bitField0_ = (bitField0_ & ~0x00000001);
          displayName_ = getDefaultInstance().getDisplayName();
          onChanged();
          return this;
        }
        /**
         * <code>optional string displayName = 1;</code>
         */
        public Builder setDisplayNameBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
          displayName_ = value;
          onChanged();
          return this;
        }

        // optional string profilePicture = 2;
        private java.lang.Object profilePicture_ = "";
        /**
         * <code>optional string profilePicture = 2;</code>
         */
        public boolean hasProfilePicture() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>optional string profilePicture = 2;</code>
         */
        public java.lang.String getProfilePicture() {
          java.lang.Object ref = profilePicture_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            profilePicture_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>optional string profilePicture = 2;</code>
         */
        public com.google.protobuf.ByteString
            getProfilePictureBytes() {
          java.lang.Object ref = profilePicture_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            profilePicture_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>optional string profilePicture = 2;</code>
         */
        public Builder setProfilePicture(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          profilePicture_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional string profilePicture = 2;</code>
         */
        public Builder clearProfilePicture() {
          bitField0_ = (bitField0_ & ~0x00000002);
          profilePicture_ = getDefaultInstance().getProfilePicture();
          onChanged();
          return this;
        }
        /**
         * <code>optional string profilePicture = 2;</code>
         */
        public Builder setProfilePictureBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          profilePicture_ = value;
          onChanged();
          return this;
        }

        // @@protoc_insertion_point(builder_scope:signalservice.DataMessage.LokiProfile)
      }

      static {
        defaultInstance = new LokiProfile(true);
        defaultInstance.initFields();
      }

      // @@protoc_insertion_point(class_scope:signalservice.DataMessage.LokiProfile)
    }

    public interface OpenGroupInvitationOrBuilder
        extends com.google.protobuf.MessageOrBuilder {

      // required string url = 1;
      /**
       * <code>required string url = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      boolean hasUrl();
      /**
       * <code>required string url = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      java.lang.String getUrl();
      /**
       * <code>required string url = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      com.google.protobuf.ByteString
          getUrlBytes();

      // required string name = 3;
      /**
       * <code>required string name = 3;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      boolean hasName();
      /**
       * <code>required string name = 3;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      java.lang.String getName();
      /**
       * <code>required string name = 3;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      com.google.protobuf.ByteString
          getNameBytes();
    }
    /**
     * Protobuf type {@code signalservice.DataMessage.OpenGroupInvitation}
     */
    public static final class OpenGroupInvitation extends
        com.google.protobuf.GeneratedMessage
        implements OpenGroupInvitationOrBuilder {
      // Use OpenGroupInvitation.newBuilder() to construct.
      private OpenGroupInvitation(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
        super(builder);
        this.unknownFields = builder.getUnknownFields();
      }
      private OpenGroupInvitation(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

      private static final OpenGroupInvitation defaultInstance;
      public static OpenGroupInvitation getDefaultInstance() {
        return defaultInstance;
      }

      public OpenGroupInvitation getDefaultInstanceForType() {
        return defaultInstance;
      }

      private final com.google.protobuf.UnknownFieldSet unknownFields;
      @java.lang.Override
      public final com.google.protobuf.UnknownFieldSet
          getUnknownFields() {
        return this.unknownFields;
      }
      private OpenGroupInvitation(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        initFields();
        int mutable_bitField0_ = 0;
        com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder();
        try {
          boolean done = false;
          while (!done) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                done = true;
                break;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  done = true;
                }
                break;
              }
              case 10: {
                bitField0_ |= 0x00000001;
                url_ = input.readBytes();
                break;
              }
              case 26: {
                bitField0_ |= 0x00000002;
                name_ = input.readBytes();
                break;
              }
            }
          }
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          throw e.setUnfinishedMessage(this);
        } catch (java.io.IOException e) {
          throw new com.google.protobuf.InvalidProtocolBufferException(
              e.getMessage()).setUnfinishedMessage(this);
        } finally {
          this.unknownFields = unknownFields.build();
          makeExtensionsImmutable();
        }
      }
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_OpenGroupInvitation_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_OpenGroupInvitation_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.Builder.class);
      }

      public static com.google.protobuf.Parser<OpenGroupInvitation> PARSER =
          new com.google.protobuf.AbstractParser<OpenGroupInvitation>() {
        public OpenGroupInvitation parsePartialFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return new OpenGroupInvitation(input, extensionRegistry);
        }
      };

      @java.lang.Override
      public com.google.protobuf.Parser<OpenGroupInvitation> getParserForType() {
        return PARSER;
      }

      private int bitField0_;
      // required string url = 1;
      public static final int URL_FIELD_NUMBER = 1;
      private java.lang.Object url_;
      /**
       * <code>required string url = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasUrl() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required string url = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public java.lang.String getUrl() {
        java.lang.Object ref = url_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            url_ = s;
          }
          return s;
        }
      }
      /**
       * <code>required string url = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public com.google.protobuf.ByteString
          getUrlBytes() {
        java.lang.Object ref = url_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          url_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // required string name = 3;
      public static final int NAME_FIELD_NUMBER = 3;
      private java.lang.Object name_;
      /**
       * <code>required string name = 3;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasName() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>required string name = 3;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public java.lang.String getName() {
        java.lang.Object ref = name_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            name_ = s;
          }
          return s;
        }
      }
      /**
       * <code>required string name = 3;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public com.google.protobuf.ByteString
          getNameBytes() {
        java.lang.Object ref = name_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          name_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      private void initFields() {
        url_ = "";
        name_ = "";
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;

        if (!hasUrl()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasName()) {
          memoizedIsInitialized = 0;
          return false;
        }
        memoizedIsInitialized = 1;
        return true;
      }

      public void writeTo(com.google.protobuf.CodedOutputStream output)
                          throws java.io.IOException {
        getSerializedSize();
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          output.writeBytes(1, getUrlBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(3, getNameBytes());
        }
        getUnknownFields().writeTo(output);
      }

      private int memoizedSerializedSize = -1;
      public int getSerializedSize() {
        int size = memoizedSerializedSize;
        if (size != -1) return size;

        size = 0;
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(1, getUrlBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(3, getNameBytes());
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }

      private static final long serialVersionUID = 0L;
      @java.lang.Override
      protected java.lang.Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }

      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }

      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }

      @java.lang.Override
      protected Builder newBuilderForType(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      /**
       * Protobuf type {@code signalservice.DataMessage.OpenGroupInvitation}
       */
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitationOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_OpenGroupInvitation_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_OpenGroupInvitation_fieldAccessorTable
              .ensureFieldAccessorsInitialized(
                  org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.Builder.class);
        }

        // Construct using org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }

        private Builder(
            com.google.protobuf.GeneratedMessage.BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
          }
        }
        private static Builder create() {
          return new Builder();
        }

        public Builder clear() {
          super.clear();
          url_ = "";
          bitField0_ = (bitField0_ & ~0x00000001);
          name_ = "";
          bitField0_ = (bitField0_ & ~0x00000002);
          return this;
        }

        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }

        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_OpenGroupInvitation_descriptor;
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation getDefaultInstanceForType() {
          return org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.getDefaultInstance();
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation build() {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation buildPartial() {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation result = new org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.url_ = url_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.name_ = name_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }

        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation) {
            return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }

        public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation other) {
          if (other == org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.getDefaultInstance()) return this;
          if (other.hasUrl()) {
            bitField0_ |= 0x00000001;
            url_ = other.url_;
            onChanged();
          }
          if (other.hasName()) {
            bitField0_ |= 0x00000002;
            name_ = other.name_;
            onChanged();
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }

        public final boolean isInitialized() {
          if (!hasUrl()) {
            
            return false;
          }
          if (!hasName()) {
            
            return false;
          }
          return true;
        }

        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation parsedMessage = null;
          try {
            parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
            parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation) e.getUnfinishedMessage();
            throw e;
          } finally {
            if (parsedMessage != null) {
              mergeFrom(parsedMessage);
            }
          }
          return this;
        }
        private int bitField0_;

        // required string url = 1;
        private java.lang.Object url_ = "";
        /**
         * <code>required string url = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasUrl() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>required string url = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public java.lang.String getUrl() {
          java.lang.Object ref = url_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            url_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>required string url = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public com.google.protobuf.ByteString
            getUrlBytes() {
          java.lang.Object ref = url_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            url_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>required string url = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setUrl(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
          url_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required string url = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder clearUrl() {
          bitField0_ = (bitField0_ & ~0x00000001);
          url_ = getDefaultInstance().getUrl();
          onChanged();
          return this;
        }
        /**
         * <code>required string url = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setUrlBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
          url_ = value;
          onChanged();
          return this;
        }

        // required string name = 3;
        private java.lang.Object name_ = "";
        /**
         * <code>required string name = 3;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasName() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>required string name = 3;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public java.lang.String getName() {
          java.lang.Object ref = name_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            name_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>required string name = 3;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public com.google.protobuf.ByteString
            getNameBytes() {
          java.lang.Object ref = name_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            name_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>required string name = 3;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setName(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required string name = 3;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder clearName() {
          bitField0_ = (bitField0_ & ~0x00000002);
          name_ = getDefaultInstance().getName();
          onChanged();
          return this;
        }
        /**
         * <code>required string name = 3;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setNameBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
          return this;
        }

        // @@protoc_insertion_point(builder_scope:signalservice.DataMessage.OpenGroupInvitation)
      }

      static {
        defaultInstance = new OpenGroupInvitation(true);
        defaultInstance.initFields();
      }

      // @@protoc_insertion_point(class_scope:signalservice.DataMessage.OpenGroupInvitation)
    }

    public interface ClosedGroupControlMessageOrBuilder
        extends com.google.protobuf.MessageOrBuilder {

      // required .signalservice.DataMessage.ClosedGroupControlMessage.Type type = 1;
      /**
       * <code>required .signalservice.DataMessage.ClosedGroupControlMessage.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      boolean hasType();
      /**
       * <code>required .signalservice.DataMessage.ClosedGroupControlMessage.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Type getType();

      // optional bytes publicKey = 2;
      /**
       * <code>optional bytes publicKey = 2;</code>
       */
      boolean hasPublicKey();
      /**
       * <code>optional bytes publicKey = 2;</code>
       */
      com.google.protobuf.ByteString getPublicKey();

      // optional string name = 3;
      /**
       * <code>optional string name = 3;</code>
       */
      boolean hasName();
      /**
       * <code>optional string name = 3;</code>
       */
      java.lang.String getName();
      /**
       * <code>optional string name = 3;</code>
       */
      com.google.protobuf.ByteString
          getNameBytes();

      // optional .signalservice.KeyPair encryptionKeyPair = 4;
      /**
       * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
       */
      boolean hasEncryptionKeyPair();
      /**
       * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
       */
      org.session.libsignal.protos.SignalServiceProtos.KeyPair getEncryptionKeyPair();
      /**
       * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
       */
      org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder getEncryptionKeyPairOrBuilder();

      // repeated bytes members = 5;
      /**
       * <code>repeated bytes members = 5;</code>
       */
      java.util.List<com.google.protobuf.ByteString> getMembersList();
      /**
       * <code>repeated bytes members = 5;</code>
       */
      int getMembersCount();
      /**
       * <code>repeated bytes members = 5;</code>
       */
      com.google.protobuf.ByteString getMembers(int index);

      // repeated bytes admins = 6;
      /**
       * <code>repeated bytes admins = 6;</code>
       */
      java.util.List<com.google.protobuf.ByteString> getAdminsList();
      /**
       * <code>repeated bytes admins = 6;</code>
       */
      int getAdminsCount();
      /**
       * <code>repeated bytes admins = 6;</code>
       */
      com.google.protobuf.ByteString getAdmins(int index);

      // repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;
      /**
       * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
       */
      java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper> 
          getWrappersList();
      /**
       * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
       */
      org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper getWrappers(int index);
      /**
       * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
       */
      int getWrappersCount();
      /**
       * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
       */
      java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapperOrBuilder> 
          getWrappersOrBuilderList();
      /**
       * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
       */
      org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapperOrBuilder getWrappersOrBuilder(
          int index);

      // optional uint32 expirationTimer = 8;
      /**
       * <code>optional uint32 expirationTimer = 8;</code>
       */
      boolean hasExpirationTimer();
      /**
       * <code>optional uint32 expirationTimer = 8;</code>
       */
      int getExpirationTimer();
    }
    /**
     * Protobuf type {@code signalservice.DataMessage.ClosedGroupControlMessage}
     */
    public static final class ClosedGroupControlMessage extends
        com.google.protobuf.GeneratedMessage
        implements ClosedGroupControlMessageOrBuilder {
      // Use ClosedGroupControlMessage.newBuilder() to construct.
      private ClosedGroupControlMessage(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
        super(builder);
        this.unknownFields = builder.getUnknownFields();
      }
      private ClosedGroupControlMessage(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

      private static final ClosedGroupControlMessage defaultInstance;
      public static ClosedGroupControlMessage getDefaultInstance() {
        return defaultInstance;
      }

      public ClosedGroupControlMessage getDefaultInstanceForType() {
        return defaultInstance;
      }

      private final com.google.protobuf.UnknownFieldSet unknownFields;
      @java.lang.Override
      public final com.google.protobuf.UnknownFieldSet
          getUnknownFields() {
        return this.unknownFields;
      }
      private ClosedGroupControlMessage(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        initFields();
        int mutable_bitField0_ = 0;
        com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder();
        try {
          boolean done = false;
          while (!done) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                done = true;
                break;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  done = true;
                }
                break;
              }
              case 8: {
                int rawValue = input.readEnum();
                org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Type value = org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Type.valueOf(rawValue);
                if (value == null) {
                  unknownFields.mergeVarintField(1, rawValue);
                } else {
                  bitField0_ |= 0x00000001;
                  type_ = value;
                }
                break;
              }
              case 18: {
                bitField0_ |= 0x00000002;
                publicKey_ = input.readBytes();
                break;
              }
              case 26: {
                bitField0_ |= 0x00000004;
                name_ = input.readBytes();
                break;
              }
              case 34: {
                org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder subBuilder = null;
                if (((bitField0_ & 0x00000008) == 0x00000008)) {
                  subBuilder = encryptionKeyPair_.toBuilder();
                }
                encryptionKeyPair_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.KeyPair.PARSER, extensionRegistry);
                if (subBuilder != null) {
                  subBuilder.mergeFrom(encryptionKeyPair_);
                  encryptionKeyPair_ = subBuilder.buildPartial();
                }
                bitField0_ |= 0x00000008;
                break;
              }
              case 42: {
                if (!((mutable_bitField0_ & 0x00000010) == 0x00000010)) {
                  members_ = new java.util.ArrayList<com.google.protobuf.ByteString>();
                  mutable_bitField0_ |= 0x00000010;
                }
                members_.add(input.readBytes());
                break;
              }
              case 50: {
                if (!((mutable_bitField0_ & 0x00000020) == 0x00000020)) {
                  admins_ = new java.util.ArrayList<com.google.protobuf.ByteString>();
                  mutable_bitField0_ |= 0x00000020;
                }
                admins_.add(input.readBytes());
                break;
              }
              case 58: {
                if (!((mutable_bitField0_ & 0x00000040) == 0x00000040)) {
                  wrappers_ = new java.util.ArrayList<org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper>();
                  mutable_bitField0_ |= 0x00000040;
                }
                wrappers_.add(input.readMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.PARSER, extensionRegistry));
                break;
              }
              case 64: {
                bitField0_ |= 0x00000010;
                expirationTimer_ = input.readUInt32();
                break;
              }
            }
          }
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          throw e.setUnfinishedMessage(this);
        } catch (java.io.IOException e) {
          throw new com.google.protobuf.InvalidProtocolBufferException(
              e.getMessage()).setUnfinishedMessage(this);
        } finally {
          if (((mutable_bitField0_ & 0x00000010) == 0x00000010)) {
            members_ = java.util.Collections.unmodifiableList(members_);
          }
          if (((mutable_bitField0_ & 0x00000020) == 0x00000020)) {
            admins_ = java.util.Collections.unmodifiableList(admins_);
          }
          if (((mutable_bitField0_ & 0x00000040) == 0x00000040)) {
            wrappers_ = java.util.Collections.unmodifiableList(wrappers_);
          }
          this.unknownFields = unknownFields.build();
          makeExtensionsImmutable();
        }
      }
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_ClosedGroupControlMessage_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_ClosedGroupControlMessage_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Builder.class);
      }

      public static com.google.protobuf.Parser<ClosedGroupControlMessage> PARSER =
          new com.google.protobuf.AbstractParser<ClosedGroupControlMessage>() {
        public ClosedGroupControlMessage parsePartialFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return new ClosedGroupControlMessage(input, extensionRegistry);
        }
      };

      @java.lang.Override
      public com.google.protobuf.Parser<ClosedGroupControlMessage> getParserForType() {
        return PARSER;
      }

      /**
       * Protobuf enum {@code signalservice.DataMessage.ClosedGroupControlMessage.Type}
       */
      public enum Type
          implements com.google.protobuf.ProtocolMessageEnum {
        /**
         * <code>NEW = 1;</code>
         *
         * <pre>
         * publicKey, name, encryptionKeyPair, members, admins, expireTimer
         * </pre>
         */
        NEW(0, 1),
        /**
         * <code>ENCRYPTION_KEY_PAIR = 3;</code>
         *
         * <pre>
         * publicKey, wrappers
         * </pre>
         */
        ENCRYPTION_KEY_PAIR(1, 3),
        /**
         * <code>NAME_CHANGE = 4;</code>
         *
         * <pre>
         * name
         * </pre>
         */
        NAME_CHANGE(2, 4),
        /**
         * <code>MEMBERS_ADDED = 5;</code>
         *
         * <pre>
         * members
         * </pre>
         */
        MEMBERS_ADDED(3, 5),
        /**
         * <code>MEMBERS_REMOVED = 6;</code>
         *
         * <pre>
         * members
         * </pre>
         */
        MEMBERS_REMOVED(4, 6),
        /**
         * <code>MEMBER_LEFT = 7;</code>
         */
        MEMBER_LEFT(5, 7),
        ;

        /**
         * <code>NEW = 1;</code>
         *
         * <pre>
         * publicKey, name, encryptionKeyPair, members, admins, expireTimer
         * </pre>
         */
        public static final int NEW_VALUE = 1;
        /**
         * <code>ENCRYPTION_KEY_PAIR = 3;</code>
         *
         * <pre>
         * publicKey, wrappers
         * </pre>
         */
        public static final int ENCRYPTION_KEY_PAIR_VALUE = 3;
        /**
         * <code>NAME_CHANGE = 4;</code>
         *
         * <pre>
         * name
         * </pre>
         */
        public static final int NAME_CHANGE_VALUE = 4;
        /**
         * <code>MEMBERS_ADDED = 5;</code>
         *
         * <pre>
         * members
         * </pre>
         */
        public static final int MEMBERS_ADDED_VALUE = 5;
        /**
         * <code>MEMBERS_REMOVED = 6;</code>
         *
         * <pre>
         * members
         * </pre>
         */
        public static final int MEMBERS_REMOVED_VALUE = 6;
        /**
         * <code>MEMBER_LEFT = 7;</code>
         */
        public static final int MEMBER_LEFT_VALUE = 7;


        public final int getNumber() { return value; }

        public static Type valueOf(int value) {
          switch (value) {
            case 1: return NEW;
            case 3: return ENCRYPTION_KEY_PAIR;
            case 4: return NAME_CHANGE;
            case 5: return MEMBERS_ADDED;
            case 6: return MEMBERS_REMOVED;
            case 7: return MEMBER_LEFT;
            default: return null;
          }
        }

        public static com.google.protobuf.Internal.EnumLiteMap<Type>
            internalGetValueMap() {
          return internalValueMap;
        }
        private static com.google.protobuf.Internal.EnumLiteMap<Type>
            internalValueMap =
              new com.google.protobuf.Internal.EnumLiteMap<Type>() {
                public Type findValueByNumber(int number) {
                  return Type.valueOf(number);
                }
              };

        public final com.google.protobuf.Descriptors.EnumValueDescriptor
            getValueDescriptor() {
          return getDescriptor().getValues().get(index);
        }
        public final com.google.protobuf.Descriptors.EnumDescriptor
            getDescriptorForType() {
          return getDescriptor();
        }
        public static final com.google.protobuf.Descriptors.EnumDescriptor
            getDescriptor() {
          return org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.getDescriptor().getEnumTypes().get(0);
        }

        private static final Type[] VALUES = values();

        public static Type valueOf(
            com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
          if (desc.getType() != getDescriptor()) {
            throw new java.lang.IllegalArgumentException(
              "EnumValueDescriptor is not for this type.");
          }
          return VALUES[desc.getIndex()];
        }

        private final int index;
        private final int value;

        private Type(int index, int value) {
          this.index = index;
          this.value = value;
        }

        // @@protoc_insertion_point(enum_scope:signalservice.DataMessage.ClosedGroupControlMessage.Type)
      }

      public interface KeyPairWrapperOrBuilder
          extends com.google.protobuf.MessageOrBuilder {

        // required bytes publicKey = 1;
        /**
         * <code>required bytes publicKey = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        boolean hasPublicKey();
        /**
         * <code>required bytes publicKey = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        com.google.protobuf.ByteString getPublicKey();

        // required bytes encryptedKeyPair = 2;
        /**
         * <code>required bytes encryptedKeyPair = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        boolean hasEncryptedKeyPair();
        /**
         * <code>required bytes encryptedKeyPair = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        com.google.protobuf.ByteString getEncryptedKeyPair();
      }
      /**
       * Protobuf type {@code signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper}
       */
      public static final class KeyPairWrapper extends
          com.google.protobuf.GeneratedMessage
          implements KeyPairWrapperOrBuilder {
        // Use KeyPairWrapper.newBuilder() to construct.
        private KeyPairWrapper(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
          super(builder);
          this.unknownFields = builder.getUnknownFields();
        }
        private KeyPairWrapper(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

        private static final KeyPairWrapper defaultInstance;
        public static KeyPairWrapper getDefaultInstance() {
          return defaultInstance;
        }

        public KeyPairWrapper getDefaultInstanceForType() {
          return defaultInstance;
        }

        private final com.google.protobuf.UnknownFieldSet unknownFields;
        @java.lang.Override
        public final com.google.protobuf.UnknownFieldSet
            getUnknownFields() {
          return this.unknownFields;
        }
        private KeyPairWrapper(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          initFields();
          int mutable_bitField0_ = 0;
          com.google.protobuf.UnknownFieldSet.Builder unknownFields =
              com.google.protobuf.UnknownFieldSet.newBuilder();
          try {
            boolean done = false;
            while (!done) {
              int tag = input.readTag();
              switch (tag) {
                case 0:
                  done = true;
                  break;
                default: {
                  if (!parseUnknownField(input, unknownFields,
                                         extensionRegistry, tag)) {
                    done = true;
                  }
                  break;
                }
                case 10: {
                  bitField0_ |= 0x00000001;
                  publicKey_ = input.readBytes();
                  break;
                }
                case 18: {
                  bitField0_ |= 0x00000002;
                  encryptedKeyPair_ = input.readBytes();
                  break;
                }
              }
            }
          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
            throw e.setUnfinishedMessage(this);
          } catch (java.io.IOException e) {
            throw new com.google.protobuf.InvalidProtocolBufferException(
                e.getMessage()).setUnfinishedMessage(this);
          } finally {
            this.unknownFields = unknownFields.build();
            makeExtensionsImmutable();
          }
        }
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_ClosedGroupControlMessage_KeyPairWrapper_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_ClosedGroupControlMessage_KeyPairWrapper_fieldAccessorTable
              .ensureFieldAccessorsInitialized(
                  org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.Builder.class);
        }

        public static com.google.protobuf.Parser<KeyPairWrapper> PARSER =
            new com.google.protobuf.AbstractParser<KeyPairWrapper>() {
          public KeyPairWrapper parsePartialFrom(
              com.google.protobuf.CodedInputStream input,
              com.google.protobuf.ExtensionRegistryLite extensionRegistry)
              throws com.google.protobuf.InvalidProtocolBufferException {
            return new KeyPairWrapper(input, extensionRegistry);
          }
        };

        @java.lang.Override
        public com.google.protobuf.Parser<KeyPairWrapper> getParserForType() {
          return PARSER;
        }

        private int bitField0_;
        // required bytes publicKey = 1;
        public static final int PUBLICKEY_FIELD_NUMBER = 1;
        private com.google.protobuf.ByteString publicKey_;
        /**
         * <code>required bytes publicKey = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasPublicKey() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>required bytes publicKey = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public com.google.protobuf.ByteString getPublicKey() {
          return publicKey_;
        }

        // required bytes encryptedKeyPair = 2;
        public static final int ENCRYPTEDKEYPAIR_FIELD_NUMBER = 2;
        private com.google.protobuf.ByteString encryptedKeyPair_;
        /**
         * <code>required bytes encryptedKeyPair = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasEncryptedKeyPair() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>required bytes encryptedKeyPair = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public com.google.protobuf.ByteString getEncryptedKeyPair() {
          return encryptedKeyPair_;
        }

        private void initFields() {
          publicKey_ = com.google.protobuf.ByteString.EMPTY;
          encryptedKeyPair_ = com.google.protobuf.ByteString.EMPTY;
        }
        private byte memoizedIsInitialized = -1;
        public final boolean isInitialized() {
          byte isInitialized = memoizedIsInitialized;
          if (isInitialized != -1) return isInitialized == 1;

          if (!hasPublicKey()) {
            memoizedIsInitialized = 0;
            return false;
          }
          if (!hasEncryptedKeyPair()) {
            memoizedIsInitialized = 0;
            return false;
          }
          memoizedIsInitialized = 1;
          return true;
        }

        public void writeTo(com.google.protobuf.CodedOutputStream output)
                            throws java.io.IOException {
          getSerializedSize();
          if (((bitField0_ & 0x00000001) == 0x00000001)) {
            output.writeBytes(1, publicKey_);
          }
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            output.writeBytes(2, encryptedKeyPair_);
          }
          getUnknownFields().writeTo(output);
        }

        private int memoizedSerializedSize = -1;
        public int getSerializedSize() {
          int size = memoizedSerializedSize;
          if (size != -1) return size;

          size = 0;
          if (((bitField0_ & 0x00000001) == 0x00000001)) {
            size += com.google.protobuf.CodedOutputStream
              .computeBytesSize(1, publicKey_);
          }
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            size += com.google.protobuf.CodedOutputStream
              .computeBytesSize(2, encryptedKeyPair_);
          }
          size += getUnknownFields().getSerializedSize();
          memoizedSerializedSize = size;
          return size;
        }

        private static final long serialVersionUID = 0L;
        @java.lang.Override
        protected java.lang.Object writeReplace()
            throws java.io.ObjectStreamException {
          return super.writeReplace();
        }

        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper parseFrom(
            com.google.protobuf.ByteString data)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return PARSER.parseFrom(data);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper parseFrom(
            com.google.protobuf.ByteString data,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return PARSER.parseFrom(data, extensionRegistry);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper parseFrom(byte[] data)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return PARSER.parseFrom(data);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper parseFrom(
            byte[] data,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return PARSER.parseFrom(data, extensionRegistry);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper parseFrom(java.io.InputStream input)
            throws java.io.IOException {
          return PARSER.parseFrom(input);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper parseFrom(
            java.io.InputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return PARSER.parseFrom(input, extensionRegistry);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper parseDelimitedFrom(java.io.InputStream input)
            throws java.io.IOException {
          return PARSER.parseDelimitedFrom(input);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper parseDelimitedFrom(
            java.io.InputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return PARSER.parseDelimitedFrom(input, extensionRegistry);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper parseFrom(
            com.google.protobuf.CodedInputStream input)
            throws java.io.IOException {
          return PARSER.parseFrom(input);
        }
        public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper parseFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return PARSER.parseFrom(input, extensionRegistry);
        }

        public static Builder newBuilder() { return Builder.create(); }
        public Builder newBuilderForType() { return newBuilder(); }
        public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper prototype) {
          return newBuilder().mergeFrom(prototype);
        }
        public Builder toBuilder() { return newBuilder(this); }

        @java.lang.Override
        protected Builder newBuilderForType(
            com.google.protobuf.GeneratedMessage.BuilderParent parent) {
          Builder builder = new Builder(parent);
          return builder;
        }
        /**
         * Protobuf type {@code signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper}
         */
        public static final class Builder extends
            com.google.protobuf.GeneratedMessage.Builder<Builder>
           implements org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapperOrBuilder {
          public static final com.google.protobuf.Descriptors.Descriptor
              getDescriptor() {
            return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_ClosedGroupControlMessage_KeyPairWrapper_descriptor;
          }

          protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
              internalGetFieldAccessorTable() {
            return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_ClosedGroupControlMessage_KeyPairWrapper_fieldAccessorTable
                .ensureFieldAccessorsInitialized(
                    org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.Builder.class);
          }

          // Construct using org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.newBuilder()
          private Builder() {
            maybeForceBuilderInitialization();
          }

          private Builder(
              com.google.protobuf.GeneratedMessage.BuilderParent parent) {
            super(parent);
            maybeForceBuilderInitialization();
          }
          private void maybeForceBuilderInitialization() {
            if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
            }
          }
          private static Builder create() {
            return new Builder();
          }

          public Builder clear() {
            super.clear();
            publicKey_ = com.google.protobuf.ByteString.EMPTY;
            bitField0_ = (bitField0_ & ~0x00000001);
            encryptedKeyPair_ = com.google.protobuf.ByteString.EMPTY;
            bitField0_ = (bitField0_ & ~0x00000002);
            return this;
          }

          public Builder clone() {
            return create().mergeFrom(buildPartial());
          }

          public com.google.protobuf.Descriptors.Descriptor
              getDescriptorForType() {
            return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_ClosedGroupControlMessage_KeyPairWrapper_descriptor;
          }

          public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper getDefaultInstanceForType() {
            return org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.getDefaultInstance();
          }

          public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper build() {
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper result = buildPartial();
            if (!result.isInitialized()) {
              throw newUninitializedMessageException(result);
            }
            return result;
          }

          public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper buildPartial() {
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper result = new org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper(this);
            int from_bitField0_ = bitField0_;
            int to_bitField0_ = 0;
            if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
              to_bitField0_ |= 0x00000001;
            }
            result.publicKey_ = publicKey_;
            if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
              to_bitField0_ |= 0x00000002;
            }
            result.encryptedKeyPair_ = encryptedKeyPair_;
            result.bitField0_ = to_bitField0_;
            onBuilt();
            return result;
          }

          public Builder mergeFrom(com.google.protobuf.Message other) {
            if (other instanceof org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper) {
              return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper)other);
            } else {
              super.mergeFrom(other);
              return this;
            }
          }

          public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper other) {
            if (other == org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.getDefaultInstance()) return this;
            if (other.hasPublicKey()) {
              setPublicKey(other.getPublicKey());
            }
            if (other.hasEncryptedKeyPair()) {
              setEncryptedKeyPair(other.getEncryptedKeyPair());
            }
            this.mergeUnknownFields(other.getUnknownFields());
            return this;
          }

          public final boolean isInitialized() {
            if (!hasPublicKey()) {
              
              return false;
            }
            if (!hasEncryptedKeyPair()) {
              
              return false;
            }
            return true;
          }

          public Builder mergeFrom(
              com.google.protobuf.CodedInputStream input,
              com.google.protobuf.ExtensionRegistryLite extensionRegistry)
              throws java.io.IOException {
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper parsedMessage = null;
            try {
              parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
            } catch (com.google.protobuf.InvalidProtocolBufferException e) {
              parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper) e.getUnfinishedMessage();
              throw e;
            } finally {
              if (parsedMessage != null) {
                mergeFrom(parsedMessage);
              }
            }
            return this;
          }
          private int bitField0_;

          // required bytes publicKey = 1;
          private com.google.protobuf.ByteString publicKey_ = com.google.protobuf.ByteString.EMPTY;
          /**
           * <code>required bytes publicKey = 1;</code>
           *
           * <pre>
           * @required
           * </pre>
           */
          public boolean hasPublicKey() {
            return ((bitField0_ & 0x00000001) == 0x00000001);
          }
          /**
           * <code>required bytes publicKey = 1;</code>
           *
           * <pre>
           * @required
           * </pre>
           */
          public com.google.protobuf.ByteString getPublicKey() {
            return publicKey_;
          }
          /**
           * <code>required bytes publicKey = 1;</code>
           *
           * <pre>
           * @required
           * </pre>
           */
          public Builder setPublicKey(com.google.protobuf.ByteString value) {
            if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
            publicKey_ = value;
            onChanged();
            return this;
          }
          /**
           * <code>required bytes publicKey = 1;</code>
           *
           * <pre>
           * @required
           * </pre>
           */
          public Builder clearPublicKey() {
            bitField0_ = (bitField0_ & ~0x00000001);
            publicKey_ = getDefaultInstance().getPublicKey();
            onChanged();
            return this;
          }

          // required bytes encryptedKeyPair = 2;
          private com.google.protobuf.ByteString encryptedKeyPair_ = com.google.protobuf.ByteString.EMPTY;
          /**
           * <code>required bytes encryptedKeyPair = 2;</code>
           *
           * <pre>
           * @required
           * </pre>
           */
          public boolean hasEncryptedKeyPair() {
            return ((bitField0_ & 0x00000002) == 0x00000002);
          }
          /**
           * <code>required bytes encryptedKeyPair = 2;</code>
           *
           * <pre>
           * @required
           * </pre>
           */
          public com.google.protobuf.ByteString getEncryptedKeyPair() {
            return encryptedKeyPair_;
          }
          /**
           * <code>required bytes encryptedKeyPair = 2;</code>
           *
           * <pre>
           * @required
           * </pre>
           */
          public Builder setEncryptedKeyPair(com.google.protobuf.ByteString value) {
            if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
            encryptedKeyPair_ = value;
            onChanged();
            return this;
          }
          /**
           * <code>required bytes encryptedKeyPair = 2;</code>
           *
           * <pre>
           * @required
           * </pre>
           */
          public Builder clearEncryptedKeyPair() {
            bitField0_ = (bitField0_ & ~0x00000002);
            encryptedKeyPair_ = getDefaultInstance().getEncryptedKeyPair();
            onChanged();
            return this;
          }

          // @@protoc_insertion_point(builder_scope:signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper)
        }

        static {
          defaultInstance = new KeyPairWrapper(true);
          defaultInstance.initFields();
        }

        // @@protoc_insertion_point(class_scope:signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper)
      }

      private int bitField0_;
      // required .signalservice.DataMessage.ClosedGroupControlMessage.Type type = 1;
      public static final int TYPE_FIELD_NUMBER = 1;
      private org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Type type_;
      /**
       * <code>required .signalservice.DataMessage.ClosedGroupControlMessage.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasType() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required .signalservice.DataMessage.ClosedGroupControlMessage.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Type getType() {
        return type_;
      }

      // optional bytes publicKey = 2;
      public static final int PUBLICKEY_FIELD_NUMBER = 2;
      private com.google.protobuf.ByteString publicKey_;
      /**
       * <code>optional bytes publicKey = 2;</code>
       */
      public boolean hasPublicKey() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>optional bytes publicKey = 2;</code>
       */
      public com.google.protobuf.ByteString getPublicKey() {
        return publicKey_;
      }

      // optional string name = 3;
      public static final int NAME_FIELD_NUMBER = 3;
      private java.lang.Object name_;
      /**
       * <code>optional string name = 3;</code>
       */
      public boolean hasName() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional string name = 3;</code>
       */
      public java.lang.String getName() {
        java.lang.Object ref = name_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            name_ = s;
          }
          return s;
        }
      }
      /**
       * <code>optional string name = 3;</code>
       */
      public com.google.protobuf.ByteString
          getNameBytes() {
        java.lang.Object ref = name_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          name_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // optional .signalservice.KeyPair encryptionKeyPair = 4;
      public static final int ENCRYPTIONKEYPAIR_FIELD_NUMBER = 4;
      private org.session.libsignal.protos.SignalServiceProtos.KeyPair encryptionKeyPair_;
      /**
       * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
       */
      public boolean hasEncryptionKeyPair() {
        return ((bitField0_ & 0x00000008) == 0x00000008);
      }
      /**
       * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.KeyPair getEncryptionKeyPair() {
        return encryptionKeyPair_;
      }
      /**
       * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder getEncryptionKeyPairOrBuilder() {
        return encryptionKeyPair_;
      }

      // repeated bytes members = 5;
      public static final int MEMBERS_FIELD_NUMBER = 5;
      private java.util.List<com.google.protobuf.ByteString> members_;
      /**
       * <code>repeated bytes members = 5;</code>
       */
      public java.util.List<com.google.protobuf.ByteString>
          getMembersList() {
        return members_;
      }
      /**
       * <code>repeated bytes members = 5;</code>
       */
      public int getMembersCount() {
        return members_.size();
      }
      /**
       * <code>repeated bytes members = 5;</code>
       */
      public com.google.protobuf.ByteString getMembers(int index) {
        return members_.get(index);
      }

      // repeated bytes admins = 6;
      public static final int ADMINS_FIELD_NUMBER = 6;
      private java.util.List<com.google.protobuf.ByteString> admins_;
      /**
       * <code>repeated bytes admins = 6;</code>
       */
      public java.util.List<com.google.protobuf.ByteString>
          getAdminsList() {
        return admins_;
      }
      /**
       * <code>repeated bytes admins = 6;</code>
       */
      public int getAdminsCount() {
        return admins_.size();
      }
      /**
       * <code>repeated bytes admins = 6;</code>
       */
      public com.google.protobuf.ByteString getAdmins(int index) {
        return admins_.get(index);
      }

      // repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;
      public static final int WRAPPERS_FIELD_NUMBER = 7;
      private java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper> wrappers_;
      /**
       * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
       */
      public java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper> getWrappersList() {
        return wrappers_;
      }
      /**
       * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
       */
      public java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapperOrBuilder> 
          getWrappersOrBuilderList() {
        return wrappers_;
      }
      /**
       * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
       */
      public int getWrappersCount() {
        return wrappers_.size();
      }
      /**
       * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper getWrappers(int index) {
        return wrappers_.get(index);
      }
      /**
       * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapperOrBuilder getWrappersOrBuilder(
          int index) {
        return wrappers_.get(index);
      }

      // optional uint32 expirationTimer = 8;
      public static final int EXPIRATIONTIMER_FIELD_NUMBER = 8;
      private int expirationTimer_;
      /**
       * <code>optional uint32 expirationTimer = 8;</code>
       */
      public boolean hasExpirationTimer() {
        return ((bitField0_ & 0x00000010) == 0x00000010);
      }
      /**
       * <code>optional uint32 expirationTimer = 8;</code>
       */
      public int getExpirationTimer() {
        return expirationTimer_;
      }

      private void initFields() {
        type_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Type.NEW;
        publicKey_ = com.google.protobuf.ByteString.EMPTY;
        name_ = "";
        encryptionKeyPair_ = org.session.libsignal.protos.SignalServiceProtos.KeyPair.getDefaultInstance();
        members_ = java.util.Collections.emptyList();
        admins_ = java.util.Collections.emptyList();
        wrappers_ = java.util.Collections.emptyList();
        expirationTimer_ = 0;
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;

        if (!hasType()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (hasEncryptionKeyPair()) {
          if (!getEncryptionKeyPair().isInitialized()) {
            memoizedIsInitialized = 0;
            return false;
          }
        }
        for (int i = 0; i < getWrappersCount(); i++) {
          if (!getWrappers(i).isInitialized()) {
            memoizedIsInitialized = 0;
            return false;
          }
        }
        memoizedIsInitialized = 1;
        return true;
      }

      public void writeTo(com.google.protobuf.CodedOutputStream output)
                          throws java.io.IOException {
        getSerializedSize();
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          output.writeEnum(1, type_.getNumber());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(2, publicKey_);
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          output.writeBytes(3, getNameBytes());
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          output.writeMessage(4, encryptionKeyPair_);
        }
        for (int i = 0; i < members_.size(); i++) {
          output.writeBytes(5, members_.get(i));
        }
        for (int i = 0; i < admins_.size(); i++) {
          output.writeBytes(6, admins_.get(i));
        }
        for (int i = 0; i < wrappers_.size(); i++) {
          output.writeMessage(7, wrappers_.get(i));
        }
        if (((bitField0_ & 0x00000010) == 0x00000010)) {
          output.writeUInt32(8, expirationTimer_);
        }
        getUnknownFields().writeTo(output);
      }

      private int memoizedSerializedSize = -1;
      public int getSerializedSize() {
        int size = memoizedSerializedSize;
        if (size != -1) return size;

        size = 0;
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          size += com.google.protobuf.CodedOutputStream
            .computeEnumSize(1, type_.getNumber());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(2, publicKey_);
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(3, getNameBytes());
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(4, encryptionKeyPair_);
        }
        {
          int dataSize = 0;
          for (int i = 0; i < members_.size(); i++) {
            dataSize += com.google.protobuf.CodedOutputStream
              .computeBytesSizeNoTag(members_.get(i));
          }
          size += dataSize;
          size += 1 * getMembersList().size();
        }
        {
          int dataSize = 0;
          for (int i = 0; i < admins_.size(); i++) {
            dataSize += com.google.protobuf.CodedOutputStream
              .computeBytesSizeNoTag(admins_.get(i));
          }
          size += dataSize;
          size += 1 * getAdminsList().size();
        }
        for (int i = 0; i < wrappers_.size(); i++) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(7, wrappers_.get(i));
        }
        if (((bitField0_ & 0x00000010) == 0x00000010)) {
          size += com.google.protobuf.CodedOutputStream
            .computeUInt32Size(8, expirationTimer_);
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }

      private static final long serialVersionUID = 0L;
      @java.lang.Override
      protected java.lang.Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }

      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }

      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }

      @java.lang.Override
      protected Builder newBuilderForType(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      /**
       * Protobuf type {@code signalservice.DataMessage.ClosedGroupControlMessage}
       */
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessageOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_ClosedGroupControlMessage_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_ClosedGroupControlMessage_fieldAccessorTable
              .ensureFieldAccessorsInitialized(
                  org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Builder.class);
        }

        // Construct using org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }

        private Builder(
            com.google.protobuf.GeneratedMessage.BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
            getEncryptionKeyPairFieldBuilder();
            getWrappersFieldBuilder();
          }
        }
        private static Builder create() {
          return new Builder();
        }

        public Builder clear() {
          super.clear();
          type_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Type.NEW;
          bitField0_ = (bitField0_ & ~0x00000001);
          publicKey_ = com.google.protobuf.ByteString.EMPTY;
          bitField0_ = (bitField0_ & ~0x00000002);
          name_ = "";
          bitField0_ = (bitField0_ & ~0x00000004);
          if (encryptionKeyPairBuilder_ == null) {
            encryptionKeyPair_ = org.session.libsignal.protos.SignalServiceProtos.KeyPair.getDefaultInstance();
          } else {
            encryptionKeyPairBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000008);
          members_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000010);
          admins_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000020);
          if (wrappersBuilder_ == null) {
            wrappers_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000040);
          } else {
            wrappersBuilder_.clear();
          }
          expirationTimer_ = 0;
          bitField0_ = (bitField0_ & ~0x00000080);
          return this;
        }

        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }

        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_ClosedGroupControlMessage_descriptor;
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage getDefaultInstanceForType() {
          return org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.getDefaultInstance();
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage build() {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage buildPartial() {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage result = new org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.type_ = type_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.publicKey_ = publicKey_;
          if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
            to_bitField0_ |= 0x00000004;
          }
          result.name_ = name_;
          if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
            to_bitField0_ |= 0x00000008;
          }
          if (encryptionKeyPairBuilder_ == null) {
            result.encryptionKeyPair_ = encryptionKeyPair_;
          } else {
            result.encryptionKeyPair_ = encryptionKeyPairBuilder_.build();
          }
          if (((bitField0_ & 0x00000010) == 0x00000010)) {
            members_ = java.util.Collections.unmodifiableList(members_);
            bitField0_ = (bitField0_ & ~0x00000010);
          }
          result.members_ = members_;
          if (((bitField0_ & 0x00000020) == 0x00000020)) {
            admins_ = java.util.Collections.unmodifiableList(admins_);
            bitField0_ = (bitField0_ & ~0x00000020);
          }
          result.admins_ = admins_;
          if (wrappersBuilder_ == null) {
            if (((bitField0_ & 0x00000040) == 0x00000040)) {
              wrappers_ = java.util.Collections.unmodifiableList(wrappers_);
              bitField0_ = (bitField0_ & ~0x00000040);
            }
            result.wrappers_ = wrappers_;
          } else {
            result.wrappers_ = wrappersBuilder_.build();
          }
          if (((from_bitField0_ & 0x00000080) == 0x00000080)) {
            to_bitField0_ |= 0x00000010;
          }
          result.expirationTimer_ = expirationTimer_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }

        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage) {
            return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }

        public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage other) {
          if (other == org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.getDefaultInstance()) return this;
          if (other.hasType()) {
            setType(other.getType());
          }
          if (other.hasPublicKey()) {
            setPublicKey(other.getPublicKey());
          }
          if (other.hasName()) {
            bitField0_ |= 0x00000004;
            name_ = other.name_;
            onChanged();
          }
          if (other.hasEncryptionKeyPair()) {
            mergeEncryptionKeyPair(other.getEncryptionKeyPair());
          }
          if (!other.members_.isEmpty()) {
            if (members_.isEmpty()) {
              members_ = other.members_;
              bitField0_ = (bitField0_ & ~0x00000010);
            } else {
              ensureMembersIsMutable();
              members_.addAll(other.members_);
            }
            onChanged();
          }
          if (!other.admins_.isEmpty()) {
            if (admins_.isEmpty()) {
              admins_ = other.admins_;
              bitField0_ = (bitField0_ & ~0x00000020);
            } else {
              ensureAdminsIsMutable();
              admins_.addAll(other.admins_);
            }
            onChanged();
          }
          if (wrappersBuilder_ == null) {
            if (!other.wrappers_.isEmpty()) {
              if (wrappers_.isEmpty()) {
                wrappers_ = other.wrappers_;
                bitField0_ = (bitField0_ & ~0x00000040);
              } else {
                ensureWrappersIsMutable();
                wrappers_.addAll(other.wrappers_);
              }
              onChanged();
            }
          } else {
            if (!other.wrappers_.isEmpty()) {
              if (wrappersBuilder_.isEmpty()) {
                wrappersBuilder_.dispose();
                wrappersBuilder_ = null;
                wrappers_ = other.wrappers_;
                bitField0_ = (bitField0_ & ~0x00000040);
                wrappersBuilder_ = 
                  com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                     getWrappersFieldBuilder() : null;
              } else {
                wrappersBuilder_.addAllMessages(other.wrappers_);
              }
            }
          }
          if (other.hasExpirationTimer()) {
            setExpirationTimer(other.getExpirationTimer());
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }

        public final boolean isInitialized() {
          if (!hasType()) {
            
            return false;
          }
          if (hasEncryptionKeyPair()) {
            if (!getEncryptionKeyPair().isInitialized()) {
              
              return false;
            }
          }
          for (int i = 0; i < getWrappersCount(); i++) {
            if (!getWrappers(i).isInitialized()) {
              
              return false;
            }
          }
          return true;
        }

        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage parsedMessage = null;
          try {
            parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
            parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage) e.getUnfinishedMessage();
            throw e;
          } finally {
            if (parsedMessage != null) {
              mergeFrom(parsedMessage);
            }
          }
          return this;
        }
        private int bitField0_;

        // required .signalservice.DataMessage.ClosedGroupControlMessage.Type type = 1;
        private org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Type type_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Type.NEW;
        /**
         * <code>required .signalservice.DataMessage.ClosedGroupControlMessage.Type type = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasType() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>required .signalservice.DataMessage.ClosedGroupControlMessage.Type type = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Type getType() {
          return type_;
        }
        /**
         * <code>required .signalservice.DataMessage.ClosedGroupControlMessage.Type type = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setType(org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Type value) {
          if (value == null) {
            throw new NullPointerException();
          }
          bitField0_ |= 0x00000001;
          type_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required .signalservice.DataMessage.ClosedGroupControlMessage.Type type = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder clearType() {
          bitField0_ = (bitField0_ & ~0x00000001);
          type_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Type.NEW;
          onChanged();
          return this;
        }

        // optional bytes publicKey = 2;
        private com.google.protobuf.ByteString publicKey_ = com.google.protobuf.ByteString.EMPTY;
        /**
         * <code>optional bytes publicKey = 2;</code>
         */
        public boolean hasPublicKey() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>optional bytes publicKey = 2;</code>
         */
        public com.google.protobuf.ByteString getPublicKey() {
          return publicKey_;
        }
        /**
         * <code>optional bytes publicKey = 2;</code>
         */
        public Builder setPublicKey(com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          publicKey_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional bytes publicKey = 2;</code>
         */
        public Builder clearPublicKey() {
          bitField0_ = (bitField0_ & ~0x00000002);
          publicKey_ = getDefaultInstance().getPublicKey();
          onChanged();
          return this;
        }

        // optional string name = 3;
        private java.lang.Object name_ = "";
        /**
         * <code>optional string name = 3;</code>
         */
        public boolean hasName() {
          return ((bitField0_ & 0x00000004) == 0x00000004);
        }
        /**
         * <code>optional string name = 3;</code>
         */
        public java.lang.String getName() {
          java.lang.Object ref = name_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            name_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>optional string name = 3;</code>
         */
        public com.google.protobuf.ByteString
            getNameBytes() {
          java.lang.Object ref = name_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            name_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>optional string name = 3;</code>
         */
        public Builder setName(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
          name_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional string name = 3;</code>
         */
        public Builder clearName() {
          bitField0_ = (bitField0_ & ~0x00000004);
          name_ = getDefaultInstance().getName();
          onChanged();
          return this;
        }
        /**
         * <code>optional string name = 3;</code>
         */
        public Builder setNameBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
          name_ = value;
          onChanged();
          return this;
        }

        // optional .signalservice.KeyPair encryptionKeyPair = 4;
        private org.session.libsignal.protos.SignalServiceProtos.KeyPair encryptionKeyPair_ = org.session.libsignal.protos.SignalServiceProtos.KeyPair.getDefaultInstance();
        private com.google.protobuf.SingleFieldBuilder<
            org.session.libsignal.protos.SignalServiceProtos.KeyPair, org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder, org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder> encryptionKeyPairBuilder_;
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
         */
        public boolean hasEncryptionKeyPair() {
          return ((bitField0_ & 0x00000008) == 0x00000008);
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.KeyPair getEncryptionKeyPair() {
          if (encryptionKeyPairBuilder_ == null) {
            return encryptionKeyPair_;
          } else {
            return encryptionKeyPairBuilder_.getMessage();
          }
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
         */
        public Builder setEncryptionKeyPair(org.session.libsignal.protos.SignalServiceProtos.KeyPair value) {
          if (encryptionKeyPairBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            encryptionKeyPair_ = value;
            onChanged();
          } else {
            encryptionKeyPairBuilder_.setMessage(value);
          }
          bitField0_ |= 0x00000008;
          return this;
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
         */
        public Builder setEncryptionKeyPair(
            org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder builderForValue) {
          if (encryptionKeyPairBuilder_ == null) {
            encryptionKeyPair_ = builderForValue.build();
            onChanged();
          } else {
            encryptionKeyPairBuilder_.setMessage(builderForValue.build());
          }
          bitField0_ |= 0x00000008;
          return this;
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
         */
        public Builder mergeEncryptionKeyPair(org.session.libsignal.protos.SignalServiceProtos.KeyPair value) {
          if (encryptionKeyPairBuilder_ == null) {
            if (((bitField0_ & 0x00000008) == 0x00000008) &&
                encryptionKeyPair_ != org.session.libsignal.protos.SignalServiceProtos.KeyPair.getDefaultInstance()) {
              encryptionKeyPair_ =
                org.session.libsignal.protos.SignalServiceProtos.KeyPair.newBuilder(encryptionKeyPair_).mergeFrom(value).buildPartial();
            } else {
              encryptionKeyPair_ = value;
            }
            onChanged();
          } else {
            encryptionKeyPairBuilder_.mergeFrom(value);
          }
          bitField0_ |= 0x00000008;
          return this;
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
         */
        public Builder clearEncryptionKeyPair() {
          if (encryptionKeyPairBuilder_ == null) {
            encryptionKeyPair_ = org.session.libsignal.protos.SignalServiceProtos.KeyPair.getDefaultInstance();
            onChanged();
          } else {
            encryptionKeyPairBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000008);
          return this;
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder getEncryptionKeyPairBuilder() {
          bitField0_ |= 0x00000008;
          onChanged();
          return getEncryptionKeyPairFieldBuilder().getBuilder();
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder getEncryptionKeyPairOrBuilder() {
          if (encryptionKeyPairBuilder_ != null) {
            return encryptionKeyPairBuilder_.getMessageOrBuilder();
          } else {
            return encryptionKeyPair_;
          }
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 4;</code>
         */
        private com.google.protobuf.SingleFieldBuilder<
            org.session.libsignal.protos.SignalServiceProtos.KeyPair, org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder, org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder> 
            getEncryptionKeyPairFieldBuilder() {
          if (encryptionKeyPairBuilder_ == null) {
            encryptionKeyPairBuilder_ = new com.google.protobuf.SingleFieldBuilder<
                org.session.libsignal.protos.SignalServiceProtos.KeyPair, org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder, org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder>(
                    encryptionKeyPair_,
                    getParentForChildren(),
                    isClean());
            encryptionKeyPair_ = null;
          }
          return encryptionKeyPairBuilder_;
        }

        // repeated bytes members = 5;
        private java.util.List<com.google.protobuf.ByteString> members_ = java.util.Collections.emptyList();
        private void ensureMembersIsMutable() {
          if (!((bitField0_ & 0x00000010) == 0x00000010)) {
            members_ = new java.util.ArrayList<com.google.protobuf.ByteString>(members_);
            bitField0_ |= 0x00000010;
           }
        }
        /**
         * <code>repeated bytes members = 5;</code>
         */
        public java.util.List<com.google.protobuf.ByteString>
            getMembersList() {
          return java.util.Collections.unmodifiableList(members_);
        }
        /**
         * <code>repeated bytes members = 5;</code>
         */
        public int getMembersCount() {
          return members_.size();
        }
        /**
         * <code>repeated bytes members = 5;</code>
         */
        public com.google.protobuf.ByteString getMembers(int index) {
          return members_.get(index);
        }
        /**
         * <code>repeated bytes members = 5;</code>
         */
        public Builder setMembers(
            int index, com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  ensureMembersIsMutable();
          members_.set(index, value);
          onChanged();
          return this;
        }
        /**
         * <code>repeated bytes members = 5;</code>
         */
        public Builder addMembers(com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  ensureMembersIsMutable();
          members_.add(value);
          onChanged();
          return this;
        }
        /**
         * <code>repeated bytes members = 5;</code>
         */
        public Builder addAllMembers(
            java.lang.Iterable<? extends com.google.protobuf.ByteString> values) {
          ensureMembersIsMutable();
          super.addAll(values, members_);
          onChanged();
          return this;
        }
        /**
         * <code>repeated bytes members = 5;</code>
         */
        public Builder clearMembers() {
          members_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000010);
          onChanged();
          return this;
        }

        // repeated bytes admins = 6;
        private java.util.List<com.google.protobuf.ByteString> admins_ = java.util.Collections.emptyList();
        private void ensureAdminsIsMutable() {
          if (!((bitField0_ & 0x00000020) == 0x00000020)) {
            admins_ = new java.util.ArrayList<com.google.protobuf.ByteString>(admins_);
            bitField0_ |= 0x00000020;
           }
        }
        /**
         * <code>repeated bytes admins = 6;</code>
         */
        public java.util.List<com.google.protobuf.ByteString>
            getAdminsList() {
          return java.util.Collections.unmodifiableList(admins_);
        }
        /**
         * <code>repeated bytes admins = 6;</code>
         */
        public int getAdminsCount() {
          return admins_.size();
        }
        /**
         * <code>repeated bytes admins = 6;</code>
         */
        public com.google.protobuf.ByteString getAdmins(int index) {
          return admins_.get(index);
        }
        /**
         * <code>repeated bytes admins = 6;</code>
         */
        public Builder setAdmins(
            int index, com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  ensureAdminsIsMutable();
          admins_.set(index, value);
          onChanged();
          return this;
        }
        /**
         * <code>repeated bytes admins = 6;</code>
         */
        public Builder addAdmins(com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  ensureAdminsIsMutable();
          admins_.add(value);
          onChanged();
          return this;
        }
        /**
         * <code>repeated bytes admins = 6;</code>
         */
        public Builder addAllAdmins(
            java.lang.Iterable<? extends com.google.protobuf.ByteString> values) {
          ensureAdminsIsMutable();
          super.addAll(values, admins_);
          onChanged();
          return this;
        }
        /**
         * <code>repeated bytes admins = 6;</code>
         */
        public Builder clearAdmins() {
          admins_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000020);
          onChanged();
          return this;
        }

        // repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;
        private java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper> wrappers_ =
          java.util.Collections.emptyList();
        private void ensureWrappersIsMutable() {
          if (!((bitField0_ & 0x00000040) == 0x00000040)) {
            wrappers_ = new java.util.ArrayList<org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper>(wrappers_);
            bitField0_ |= 0x00000040;
           }
        }

        private com.google.protobuf.RepeatedFieldBuilder<
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapperOrBuilder> wrappersBuilder_;

        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper> getWrappersList() {
          if (wrappersBuilder_ == null) {
            return java.util.Collections.unmodifiableList(wrappers_);
          } else {
            return wrappersBuilder_.getMessageList();
          }
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public int getWrappersCount() {
          if (wrappersBuilder_ == null) {
            return wrappers_.size();
          } else {
            return wrappersBuilder_.getCount();
          }
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper getWrappers(int index) {
          if (wrappersBuilder_ == null) {
            return wrappers_.get(index);
          } else {
            return wrappersBuilder_.getMessage(index);
          }
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public Builder setWrappers(
            int index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper value) {
          if (wrappersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureWrappersIsMutable();
            wrappers_.set(index, value);
            onChanged();
          } else {
            wrappersBuilder_.setMessage(index, value);
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public Builder setWrappers(
            int index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.Builder builderForValue) {
          if (wrappersBuilder_ == null) {
            ensureWrappersIsMutable();
            wrappers_.set(index, builderForValue.build());
            onChanged();
          } else {
            wrappersBuilder_.setMessage(index, builderForValue.build());
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public Builder addWrappers(org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper value) {
          if (wrappersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureWrappersIsMutable();
            wrappers_.add(value);
            onChanged();
          } else {
            wrappersBuilder_.addMessage(value);
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public Builder addWrappers(
            int index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper value) {
          if (wrappersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureWrappersIsMutable();
            wrappers_.add(index, value);
            onChanged();
          } else {
            wrappersBuilder_.addMessage(index, value);
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public Builder addWrappers(
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.Builder builderForValue) {
          if (wrappersBuilder_ == null) {
            ensureWrappersIsMutable();
            wrappers_.add(builderForValue.build());
            onChanged();
          } else {
            wrappersBuilder_.addMessage(builderForValue.build());
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public Builder addWrappers(
            int index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.Builder builderForValue) {
          if (wrappersBuilder_ == null) {
            ensureWrappersIsMutable();
            wrappers_.add(index, builderForValue.build());
            onChanged();
          } else {
            wrappersBuilder_.addMessage(index, builderForValue.build());
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public Builder addAllWrappers(
            java.lang.Iterable<? extends org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper> values) {
          if (wrappersBuilder_ == null) {
            ensureWrappersIsMutable();
            super.addAll(values, wrappers_);
            onChanged();
          } else {
            wrappersBuilder_.addAllMessages(values);
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public Builder clearWrappers() {
          if (wrappersBuilder_ == null) {
            wrappers_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000040);
            onChanged();
          } else {
            wrappersBuilder_.clear();
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public Builder removeWrappers(int index) {
          if (wrappersBuilder_ == null) {
            ensureWrappersIsMutable();
            wrappers_.remove(index);
            onChanged();
          } else {
            wrappersBuilder_.remove(index);
          }
          return this;
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.Builder getWrappersBuilder(
            int index) {
          return getWrappersFieldBuilder().getBuilder(index);
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapperOrBuilder getWrappersOrBuilder(
            int index) {
          if (wrappersBuilder_ == null) {
            return wrappers_.get(index);  } else {
            return wrappersBuilder_.getMessageOrBuilder(index);
          }
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapperOrBuilder> 
             getWrappersOrBuilderList() {
          if (wrappersBuilder_ != null) {
            return wrappersBuilder_.getMessageOrBuilderList();
          } else {
            return java.util.Collections.unmodifiableList(wrappers_);
          }
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.Builder addWrappersBuilder() {
          return getWrappersFieldBuilder().addBuilder(
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.getDefaultInstance());
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.Builder addWrappersBuilder(
            int index) {
          return getWrappersFieldBuilder().addBuilder(
              index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.getDefaultInstance());
        }
        /**
         * <code>repeated .signalservice.DataMessage.ClosedGroupControlMessage.KeyPairWrapper wrappers = 7;</code>
         */
        public java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.Builder> 
             getWrappersBuilderList() {
          return getWrappersFieldBuilder().getBuilderList();
        }
        private com.google.protobuf.RepeatedFieldBuilder<
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapperOrBuilder> 
            getWrappersFieldBuilder() {
          if (wrappersBuilder_ == null) {
            wrappersBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
                org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapper.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.KeyPairWrapperOrBuilder>(
                    wrappers_,
                    ((bitField0_ & 0x00000040) == 0x00000040),
                    getParentForChildren(),
                    isClean());
            wrappers_ = null;
          }
          return wrappersBuilder_;
        }

        // optional uint32 expirationTimer = 8;
        private int expirationTimer_ ;
        /**
         * <code>optional uint32 expirationTimer = 8;</code>
         */
        public boolean hasExpirationTimer() {
          return ((bitField0_ & 0x00000080) == 0x00000080);
        }
        /**
         * <code>optional uint32 expirationTimer = 8;</code>
         */
        public int getExpirationTimer() {
          return expirationTimer_;
        }
        /**
         * <code>optional uint32 expirationTimer = 8;</code>
         */
        public Builder setExpirationTimer(int value) {
          bitField0_ |= 0x00000080;
          expirationTimer_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional uint32 expirationTimer = 8;</code>
         */
        public Builder clearExpirationTimer() {
          bitField0_ = (bitField0_ & ~0x00000080);
          expirationTimer_ = 0;
          onChanged();
          return this;
        }

        // @@protoc_insertion_point(builder_scope:signalservice.DataMessage.ClosedGroupControlMessage)
      }

      static {
        defaultInstance = new ClosedGroupControlMessage(true);
        defaultInstance.initFields();
      }

      // @@protoc_insertion_point(class_scope:signalservice.DataMessage.ClosedGroupControlMessage)
    }

    public interface ReactionOrBuilder
        extends com.google.protobuf.MessageOrBuilder {

      // required uint64 id = 1;
      /**
       * <code>required uint64 id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      boolean hasId();
      /**
       * <code>required uint64 id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      long getId();

      // required string author = 2;
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      boolean hasAuthor();
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      java.lang.String getAuthor();
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      com.google.protobuf.ByteString
          getAuthorBytes();

      // optional string emoji = 3;
      /**
       * <code>optional string emoji = 3;</code>
       */
      boolean hasEmoji();
      /**
       * <code>optional string emoji = 3;</code>
       */
      java.lang.String getEmoji();
      /**
       * <code>optional string emoji = 3;</code>
       */
      com.google.protobuf.ByteString
          getEmojiBytes();

      // required .signalservice.DataMessage.Reaction.Action action = 4;
      /**
       * <code>required .signalservice.DataMessage.Reaction.Action action = 4;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      boolean hasAction();
      /**
       * <code>required .signalservice.DataMessage.Reaction.Action action = 4;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Action getAction();
    }
    /**
     * Protobuf type {@code signalservice.DataMessage.Reaction}
     */
    public static final class Reaction extends
        com.google.protobuf.GeneratedMessage
        implements ReactionOrBuilder {
      // Use Reaction.newBuilder() to construct.
      private Reaction(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
        super(builder);
        this.unknownFields = builder.getUnknownFields();
      }
      private Reaction(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

      private static final Reaction defaultInstance;
      public static Reaction getDefaultInstance() {
        return defaultInstance;
      }

      public Reaction getDefaultInstanceForType() {
        return defaultInstance;
      }

      private final com.google.protobuf.UnknownFieldSet unknownFields;
      @java.lang.Override
      public final com.google.protobuf.UnknownFieldSet
          getUnknownFields() {
        return this.unknownFields;
      }
      private Reaction(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        initFields();
        int mutable_bitField0_ = 0;
        com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder();
        try {
          boolean done = false;
          while (!done) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                done = true;
                break;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  done = true;
                }
                break;
              }
              case 8: {
                bitField0_ |= 0x00000001;
                id_ = input.readUInt64();
                break;
              }
              case 18: {
                bitField0_ |= 0x00000002;
                author_ = input.readBytes();
                break;
              }
              case 26: {
                bitField0_ |= 0x00000004;
                emoji_ = input.readBytes();
                break;
              }
              case 32: {
                int rawValue = input.readEnum();
                org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Action value = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Action.valueOf(rawValue);
                if (value == null) {
                  unknownFields.mergeVarintField(4, rawValue);
                } else {
                  bitField0_ |= 0x00000008;
                  action_ = value;
                }
                break;
              }
            }
          }
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          throw e.setUnfinishedMessage(this);
        } catch (java.io.IOException e) {
          throw new com.google.protobuf.InvalidProtocolBufferException(
              e.getMessage()).setUnfinishedMessage(this);
        } finally {
          this.unknownFields = unknownFields.build();
          makeExtensionsImmutable();
        }
      }
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Reaction_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Reaction_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Builder.class);
      }

      public static com.google.protobuf.Parser<Reaction> PARSER =
          new com.google.protobuf.AbstractParser<Reaction>() {
        public Reaction parsePartialFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return new Reaction(input, extensionRegistry);
        }
      };

      @java.lang.Override
      public com.google.protobuf.Parser<Reaction> getParserForType() {
        return PARSER;
      }

      /**
       * Protobuf enum {@code signalservice.DataMessage.Reaction.Action}
       */
      public enum Action
          implements com.google.protobuf.ProtocolMessageEnum {
        /**
         * <code>REACT = 0;</code>
         */
        REACT(0, 0),
        /**
         * <code>REMOVE = 1;</code>
         */
        REMOVE(1, 1),
        ;

        /**
         * <code>REACT = 0;</code>
         */
        public static final int REACT_VALUE = 0;
        /**
         * <code>REMOVE = 1;</code>
         */
        public static final int REMOVE_VALUE = 1;


        public final int getNumber() { return value; }

        public static Action valueOf(int value) {
          switch (value) {
            case 0: return REACT;
            case 1: return REMOVE;
            default: return null;
          }
        }

        public static com.google.protobuf.Internal.EnumLiteMap<Action>
            internalGetValueMap() {
          return internalValueMap;
        }
        private static com.google.protobuf.Internal.EnumLiteMap<Action>
            internalValueMap =
              new com.google.protobuf.Internal.EnumLiteMap<Action>() {
                public Action findValueByNumber(int number) {
                  return Action.valueOf(number);
                }
              };

        public final com.google.protobuf.Descriptors.EnumValueDescriptor
            getValueDescriptor() {
          return getDescriptor().getValues().get(index);
        }
        public final com.google.protobuf.Descriptors.EnumDescriptor
            getDescriptorForType() {
          return getDescriptor();
        }
        public static final com.google.protobuf.Descriptors.EnumDescriptor
            getDescriptor() {
          return org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.getDescriptor().getEnumTypes().get(0);
        }

        private static final Action[] VALUES = values();

        public static Action valueOf(
            com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
          if (desc.getType() != getDescriptor()) {
            throw new java.lang.IllegalArgumentException(
              "EnumValueDescriptor is not for this type.");
          }
          return VALUES[desc.getIndex()];
        }

        private final int index;
        private final int value;

        private Action(int index, int value) {
          this.index = index;
          this.value = value;
        }

        // @@protoc_insertion_point(enum_scope:signalservice.DataMessage.Reaction.Action)
      }

      private int bitField0_;
      // required uint64 id = 1;
      public static final int ID_FIELD_NUMBER = 1;
      private long id_;
      /**
       * <code>required uint64 id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasId() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required uint64 id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public long getId() {
        return id_;
      }

      // required string author = 2;
      public static final int AUTHOR_FIELD_NUMBER = 2;
      private java.lang.Object author_;
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasAuthor() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public java.lang.String getAuthor() {
        java.lang.Object ref = author_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            author_ = s;
          }
          return s;
        }
      }
      /**
       * <code>required string author = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public com.google.protobuf.ByteString
          getAuthorBytes() {
        java.lang.Object ref = author_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          author_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // optional string emoji = 3;
      public static final int EMOJI_FIELD_NUMBER = 3;
      private java.lang.Object emoji_;
      /**
       * <code>optional string emoji = 3;</code>
       */
      public boolean hasEmoji() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional string emoji = 3;</code>
       */
      public java.lang.String getEmoji() {
        java.lang.Object ref = emoji_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            emoji_ = s;
          }
          return s;
        }
      }
      /**
       * <code>optional string emoji = 3;</code>
       */
      public com.google.protobuf.ByteString
          getEmojiBytes() {
        java.lang.Object ref = emoji_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          emoji_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // required .signalservice.DataMessage.Reaction.Action action = 4;
      public static final int ACTION_FIELD_NUMBER = 4;
      private org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Action action_;
      /**
       * <code>required .signalservice.DataMessage.Reaction.Action action = 4;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasAction() {
        return ((bitField0_ & 0x00000008) == 0x00000008);
      }
      /**
       * <code>required .signalservice.DataMessage.Reaction.Action action = 4;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Action getAction() {
        return action_;
      }

      private void initFields() {
        id_ = 0L;
        author_ = "";
        emoji_ = "";
        action_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Action.REACT;
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;

        if (!hasId()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasAuthor()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasAction()) {
          memoizedIsInitialized = 0;
          return false;
        }
        memoizedIsInitialized = 1;
        return true;
      }

      public void writeTo(com.google.protobuf.CodedOutputStream output)
                          throws java.io.IOException {
        getSerializedSize();
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          output.writeUInt64(1, id_);
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(2, getAuthorBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          output.writeBytes(3, getEmojiBytes());
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          output.writeEnum(4, action_.getNumber());
        }
        getUnknownFields().writeTo(output);
      }

      private int memoizedSerializedSize = -1;
      public int getSerializedSize() {
        int size = memoizedSerializedSize;
        if (size != -1) return size;

        size = 0;
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          size += com.google.protobuf.CodedOutputStream
            .computeUInt64Size(1, id_);
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(2, getAuthorBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(3, getEmojiBytes());
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          size += com.google.protobuf.CodedOutputStream
            .computeEnumSize(4, action_.getNumber());
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }

      private static final long serialVersionUID = 0L;
      @java.lang.Override
      protected java.lang.Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }

      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }

      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }

      @java.lang.Override
      protected Builder newBuilderForType(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      /**
       * Protobuf type {@code signalservice.DataMessage.Reaction}
       */
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements org.session.libsignal.protos.SignalServiceProtos.DataMessage.ReactionOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Reaction_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Reaction_fieldAccessorTable
              .ensureFieldAccessorsInitialized(
                  org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Builder.class);
        }

        // Construct using org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }

        private Builder(
            com.google.protobuf.GeneratedMessage.BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
          }
        }
        private static Builder create() {
          return new Builder();
        }

        public Builder clear() {
          super.clear();
          id_ = 0L;
          bitField0_ = (bitField0_ & ~0x00000001);
          author_ = "";
          bitField0_ = (bitField0_ & ~0x00000002);
          emoji_ = "";
          bitField0_ = (bitField0_ & ~0x00000004);
          action_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Action.REACT;
          bitField0_ = (bitField0_ & ~0x00000008);
          return this;
        }

        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }

        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_Reaction_descriptor;
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction getDefaultInstanceForType() {
          return org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.getDefaultInstance();
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction build() {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }

        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction buildPartial() {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction result = new org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.id_ = id_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.author_ = author_;
          if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
            to_bitField0_ |= 0x00000004;
          }
          result.emoji_ = emoji_;
          if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
            to_bitField0_ |= 0x00000008;
          }
          result.action_ = action_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }

        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction) {
            return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }

        public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction other) {
          if (other == org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.getDefaultInstance()) return this;
          if (other.hasId()) {
            setId(other.getId());
          }
          if (other.hasAuthor()) {
            bitField0_ |= 0x00000002;
            author_ = other.author_;
            onChanged();
          }
          if (other.hasEmoji()) {
            bitField0_ |= 0x00000004;
            emoji_ = other.emoji_;
            onChanged();
          }
          if (other.hasAction()) {
            setAction(other.getAction());
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }

        public final boolean isInitialized() {
          if (!hasId()) {
            
            return false;
          }
          if (!hasAuthor()) {
            
            return false;
          }
          if (!hasAction()) {
            
            return false;
          }
          return true;
        }

        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction parsedMessage = null;
          try {
            parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
            parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction) e.getUnfinishedMessage();
            throw e;
          } finally {
            if (parsedMessage != null) {
              mergeFrom(parsedMessage);
            }
          }
          return this;
        }
        private int bitField0_;

        // required uint64 id = 1;
        private long id_ ;
        /**
         * <code>required uint64 id = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasId() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>required uint64 id = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public long getId() {
          return id_;
        }
        /**
         * <code>required uint64 id = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setId(long value) {
          bitField0_ |= 0x00000001;
          id_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required uint64 id = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder clearId() {
          bitField0_ = (bitField0_ & ~0x00000001);
          id_ = 0L;
          onChanged();
          return this;
        }

        // required string author = 2;
        private java.lang.Object author_ = "";
        /**
         * <code>required string author = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasAuthor() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>required string author = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public java.lang.String getAuthor() {
          java.lang.Object ref = author_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            author_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>required string author = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public com.google.protobuf.ByteString
            getAuthorBytes() {
          java.lang.Object ref = author_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            author_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>required string author = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setAuthor(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          author_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required string author = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder clearAuthor() {
          bitField0_ = (bitField0_ & ~0x00000002);
          author_ = getDefaultInstance().getAuthor();
          onChanged();
          return this;
        }
        /**
         * <code>required string author = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setAuthorBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          author_ = value;
          onChanged();
          return this;
        }

        // optional string emoji = 3;
        private java.lang.Object emoji_ = "";
        /**
         * <code>optional string emoji = 3;</code>
         */
        public boolean hasEmoji() {
          return ((bitField0_ & 0x00000004) == 0x00000004);
        }
        /**
         * <code>optional string emoji = 3;</code>
         */
        public java.lang.String getEmoji() {
          java.lang.Object ref = emoji_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            emoji_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>optional string emoji = 3;</code>
         */
        public com.google.protobuf.ByteString
            getEmojiBytes() {
          java.lang.Object ref = emoji_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            emoji_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>optional string emoji = 3;</code>
         */
        public Builder setEmoji(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
          emoji_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional string emoji = 3;</code>
         */
        public Builder clearEmoji() {
          bitField0_ = (bitField0_ & ~0x00000004);
          emoji_ = getDefaultInstance().getEmoji();
          onChanged();
          return this;
        }
        /**
         * <code>optional string emoji = 3;</code>
         */
        public Builder setEmojiBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
          emoji_ = value;
          onChanged();
          return this;
        }

        // required .signalservice.DataMessage.Reaction.Action action = 4;
        private org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Action action_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Action.REACT;
        /**
         * <code>required .signalservice.DataMessage.Reaction.Action action = 4;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasAction() {
          return ((bitField0_ & 0x00000008) == 0x00000008);
        }
        /**
         * <code>required .signalservice.DataMessage.Reaction.Action action = 4;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Action getAction() {
          return action_;
        }
        /**
         * <code>required .signalservice.DataMessage.Reaction.Action action = 4;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setAction(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Action value) {
          if (value == null) {
            throw new NullPointerException();
          }
          bitField0_ |= 0x00000008;
          action_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required .signalservice.DataMessage.Reaction.Action action = 4;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder clearAction() {
          bitField0_ = (bitField0_ & ~0x00000008);
          action_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Action.REACT;
          onChanged();
          return this;
        }

        // @@protoc_insertion_point(builder_scope:signalservice.DataMessage.Reaction)
      }

      static {
        defaultInstance = new Reaction(true);
        defaultInstance.initFields();
      }

      // @@protoc_insertion_point(class_scope:signalservice.DataMessage.Reaction)
    }

    private int bitField0_;
    // optional string body = 1;
    public static final int BODY_FIELD_NUMBER = 1;
    private java.lang.Object body_;
    /**
     * <code>optional string body = 1;</code>
     */
    public boolean hasBody() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>optional string body = 1;</code>
     */
    public java.lang.String getBody() {
      java.lang.Object ref = body_;
      if (ref instanceof java.lang.String) {
        return (java.lang.String) ref;
      } else {
        com.google.protobuf.ByteString bs = 
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          body_ = s;
        }
        return s;
      }
    }
    /**
     * <code>optional string body = 1;</code>
     */
    public com.google.protobuf.ByteString
        getBodyBytes() {
      java.lang.Object ref = body_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        body_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    // repeated .signalservice.AttachmentPointer attachments = 2;
    public static final int ATTACHMENTS_FIELD_NUMBER = 2;
    private java.util.List<org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer> attachments_;
    /**
     * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
     */
    public java.util.List<org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer> getAttachmentsList() {
      return attachments_;
    }
    /**
     * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
     */
    public java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder> 
        getAttachmentsOrBuilderList() {
      return attachments_;
    }
    /**
     * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
     */
    public int getAttachmentsCount() {
      return attachments_.size();
    }
    /**
     * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getAttachments(int index) {
      return attachments_.get(index);
    }
    /**
     * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder getAttachmentsOrBuilder(
        int index) {
      return attachments_.get(index);
    }

    // optional .signalservice.GroupContext group = 3;
    public static final int GROUP_FIELD_NUMBER = 3;
    private org.session.libsignal.protos.SignalServiceProtos.GroupContext group_;
    /**
     * <code>optional .signalservice.GroupContext group = 3;</code>
     */
    public boolean hasGroup() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>optional .signalservice.GroupContext group = 3;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.GroupContext getGroup() {
      return group_;
    }
    /**
     * <code>optional .signalservice.GroupContext group = 3;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.GroupContextOrBuilder getGroupOrBuilder() {
      return group_;
    }

    // optional uint32 flags = 4;
    public static final int FLAGS_FIELD_NUMBER = 4;
    private int flags_;
    /**
     * <code>optional uint32 flags = 4;</code>
     */
    public boolean hasFlags() {
      return ((bitField0_ & 0x00000004) == 0x00000004);
    }
    /**
     * <code>optional uint32 flags = 4;</code>
     */
    public int getFlags() {
      return flags_;
    }

    // optional uint32 expireTimer = 5;
    public static final int EXPIRETIMER_FIELD_NUMBER = 5;
    private int expireTimer_;
    /**
     * <code>optional uint32 expireTimer = 5;</code>
     */
    public boolean hasExpireTimer() {
      return ((bitField0_ & 0x00000008) == 0x00000008);
    }
    /**
     * <code>optional uint32 expireTimer = 5;</code>
     */
    public int getExpireTimer() {
      return expireTimer_;
    }

    // optional bytes profileKey = 6;
    public static final int PROFILEKEY_FIELD_NUMBER = 6;
    private com.google.protobuf.ByteString profileKey_;
    /**
     * <code>optional bytes profileKey = 6;</code>
     */
    public boolean hasProfileKey() {
      return ((bitField0_ & 0x00000010) == 0x00000010);
    }
    /**
     * <code>optional bytes profileKey = 6;</code>
     */
    public com.google.protobuf.ByteString getProfileKey() {
      return profileKey_;
    }

    // optional uint64 timestamp = 7;
    public static final int TIMESTAMP_FIELD_NUMBER = 7;
    private long timestamp_;
    /**
     * <code>optional uint64 timestamp = 7;</code>
     */
    public boolean hasTimestamp() {
      return ((bitField0_ & 0x00000020) == 0x00000020);
    }
    /**
     * <code>optional uint64 timestamp = 7;</code>
     */
    public long getTimestamp() {
      return timestamp_;
    }

    // optional .signalservice.DataMessage.Quote quote = 8;
    public static final int QUOTE_FIELD_NUMBER = 8;
    private org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote quote_;
    /**
     * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
     */
    public boolean hasQuote() {
      return ((bitField0_ & 0x00000040) == 0x00000040);
    }
    /**
     * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote getQuote() {
      return quote_;
    }
    /**
     * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.QuoteOrBuilder getQuoteOrBuilder() {
      return quote_;
    }

    // repeated .signalservice.DataMessage.Preview preview = 10;
    public static final int PREVIEW_FIELD_NUMBER = 10;
    private java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview> preview_;
    /**
     * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
     */
    public java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview> getPreviewList() {
      return preview_;
    }
    /**
     * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
     */
    public java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.DataMessage.PreviewOrBuilder> 
        getPreviewOrBuilderList() {
      return preview_;
    }
    /**
     * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
     */
    public int getPreviewCount() {
      return preview_.size();
    }
    /**
     * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview getPreview(int index) {
      return preview_.get(index);
    }
    /**
     * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.PreviewOrBuilder getPreviewOrBuilder(
        int index) {
      return preview_.get(index);
    }

    // optional .signalservice.DataMessage.Reaction reaction = 11;
    public static final int REACTION_FIELD_NUMBER = 11;
    private org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction reaction_;
    /**
     * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
     */
    public boolean hasReaction() {
      return ((bitField0_ & 0x00000080) == 0x00000080);
    }
    /**
     * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction getReaction() {
      return reaction_;
    }
    /**
     * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ReactionOrBuilder getReactionOrBuilder() {
      return reaction_;
    }

    // optional .signalservice.DataMessage.LokiProfile profile = 101;
    public static final int PROFILE_FIELD_NUMBER = 101;
    private org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile profile_;
    /**
     * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
     */
    public boolean hasProfile() {
      return ((bitField0_ & 0x00000100) == 0x00000100);
    }
    /**
     * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile getProfile() {
      return profile_;
    }
    /**
     * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder getProfileOrBuilder() {
      return profile_;
    }

    // optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;
    public static final int OPENGROUPINVITATION_FIELD_NUMBER = 102;
    private org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation openGroupInvitation_;
    /**
     * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
     */
    public boolean hasOpenGroupInvitation() {
      return ((bitField0_ & 0x00000200) == 0x00000200);
    }
    /**
     * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation getOpenGroupInvitation() {
      return openGroupInvitation_;
    }
    /**
     * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitationOrBuilder getOpenGroupInvitationOrBuilder() {
      return openGroupInvitation_;
    }

    // optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;
    public static final int CLOSEDGROUPCONTROLMESSAGE_FIELD_NUMBER = 104;
    private org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage closedGroupControlMessage_;
    /**
     * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
     */
    public boolean hasClosedGroupControlMessage() {
      return ((bitField0_ & 0x00000400) == 0x00000400);
    }
    /**
     * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage getClosedGroupControlMessage() {
      return closedGroupControlMessage_;
    }
    /**
     * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessageOrBuilder getClosedGroupControlMessageOrBuilder() {
      return closedGroupControlMessage_;
    }

    // optional string syncTarget = 105;
    public static final int SYNCTARGET_FIELD_NUMBER = 105;
    private java.lang.Object syncTarget_;
    /**
     * <code>optional string syncTarget = 105;</code>
     */
    public boolean hasSyncTarget() {
      return ((bitField0_ & 0x00000800) == 0x00000800);
    }
    /**
     * <code>optional string syncTarget = 105;</code>
     */
    public java.lang.String getSyncTarget() {
      java.lang.Object ref = syncTarget_;
      if (ref instanceof java.lang.String) {
        return (java.lang.String) ref;
      } else {
        com.google.protobuf.ByteString bs = 
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          syncTarget_ = s;
        }
        return s;
      }
    }
    /**
     * <code>optional string syncTarget = 105;</code>
     */
    public com.google.protobuf.ByteString
        getSyncTargetBytes() {
      java.lang.Object ref = syncTarget_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        syncTarget_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    private void initFields() {
      body_ = "";
      attachments_ = java.util.Collections.emptyList();
      group_ = org.session.libsignal.protos.SignalServiceProtos.GroupContext.getDefaultInstance();
      flags_ = 0;
      expireTimer_ = 0;
      profileKey_ = com.google.protobuf.ByteString.EMPTY;
      timestamp_ = 0L;
      quote_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.getDefaultInstance();
      preview_ = java.util.Collections.emptyList();
      reaction_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.getDefaultInstance();
      profile_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.getDefaultInstance();
      openGroupInvitation_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.getDefaultInstance();
      closedGroupControlMessage_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.getDefaultInstance();
      syncTarget_ = "";
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      for (int i = 0; i < getAttachmentsCount(); i++) {
        if (!getAttachments(i).isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      if (hasGroup()) {
        if (!getGroup().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      if (hasQuote()) {
        if (!getQuote().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      for (int i = 0; i < getPreviewCount(); i++) {
        if (!getPreview(i).isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      if (hasReaction()) {
        if (!getReaction().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      if (hasOpenGroupInvitation()) {
        if (!getOpenGroupInvitation().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      if (hasClosedGroupControlMessage()) {
        if (!getClosedGroupControlMessage().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeBytes(1, getBodyBytes());
      }
      for (int i = 0; i < attachments_.size(); i++) {
        output.writeMessage(2, attachments_.get(i));
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeMessage(3, group_);
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        output.writeUInt32(4, flags_);
      }
      if (((bitField0_ & 0x00000008) == 0x00000008)) {
        output.writeUInt32(5, expireTimer_);
      }
      if (((bitField0_ & 0x00000010) == 0x00000010)) {
        output.writeBytes(6, profileKey_);
      }
      if (((bitField0_ & 0x00000020) == 0x00000020)) {
        output.writeUInt64(7, timestamp_);
      }
      if (((bitField0_ & 0x00000040) == 0x00000040)) {
        output.writeMessage(8, quote_);
      }
      for (int i = 0; i < preview_.size(); i++) {
        output.writeMessage(10, preview_.get(i));
      }
      if (((bitField0_ & 0x00000080) == 0x00000080)) {
        output.writeMessage(11, reaction_);
      }
      if (((bitField0_ & 0x00000100) == 0x00000100)) {
        output.writeMessage(101, profile_);
      }
      if (((bitField0_ & 0x00000200) == 0x00000200)) {
        output.writeMessage(102, openGroupInvitation_);
      }
      if (((bitField0_ & 0x00000400) == 0x00000400)) {
        output.writeMessage(104, closedGroupControlMessage_);
      }
      if (((bitField0_ & 0x00000800) == 0x00000800)) {
        output.writeBytes(105, getSyncTargetBytes());
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(1, getBodyBytes());
      }
      for (int i = 0; i < attachments_.size(); i++) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(2, attachments_.get(i));
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(3, group_);
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt32Size(4, flags_);
      }
      if (((bitField0_ & 0x00000008) == 0x00000008)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt32Size(5, expireTimer_);
      }
      if (((bitField0_ & 0x00000010) == 0x00000010)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(6, profileKey_);
      }
      if (((bitField0_ & 0x00000020) == 0x00000020)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt64Size(7, timestamp_);
      }
      if (((bitField0_ & 0x00000040) == 0x00000040)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(8, quote_);
      }
      for (int i = 0; i < preview_.size(); i++) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(10, preview_.get(i));
      }
      if (((bitField0_ & 0x00000080) == 0x00000080)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(11, reaction_);
      }
      if (((bitField0_ & 0x00000100) == 0x00000100)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(101, profile_);
      }
      if (((bitField0_ & 0x00000200) == 0x00000200)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(102, openGroupInvitation_);
      }
      if (((bitField0_ & 0x00000400) == 0x00000400)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(104, closedGroupControlMessage_);
      }
      if (((bitField0_ & 0x00000800) == 0x00000800)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(105, getSyncTargetBytes());
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.DataMessage parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataMessage parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataMessage parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataMessage parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataMessage parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataMessage parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataMessage parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataMessage parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataMessage parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.DataMessage parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.DataMessage prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.DataMessage}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.DataMessageOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.DataMessage.class, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.DataMessage.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
          getAttachmentsFieldBuilder();
          getGroupFieldBuilder();
          getQuoteFieldBuilder();
          getPreviewFieldBuilder();
          getReactionFieldBuilder();
          getProfileFieldBuilder();
          getOpenGroupInvitationFieldBuilder();
          getClosedGroupControlMessageFieldBuilder();
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        body_ = "";
        bitField0_ = (bitField0_ & ~0x00000001);
        if (attachmentsBuilder_ == null) {
          attachments_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000002);
        } else {
          attachmentsBuilder_.clear();
        }
        if (groupBuilder_ == null) {
          group_ = org.session.libsignal.protos.SignalServiceProtos.GroupContext.getDefaultInstance();
        } else {
          groupBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000004);
        flags_ = 0;
        bitField0_ = (bitField0_ & ~0x00000008);
        expireTimer_ = 0;
        bitField0_ = (bitField0_ & ~0x00000010);
        profileKey_ = com.google.protobuf.ByteString.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000020);
        timestamp_ = 0L;
        bitField0_ = (bitField0_ & ~0x00000040);
        if (quoteBuilder_ == null) {
          quote_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.getDefaultInstance();
        } else {
          quoteBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000080);
        if (previewBuilder_ == null) {
          preview_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000100);
        } else {
          previewBuilder_.clear();
        }
        if (reactionBuilder_ == null) {
          reaction_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.getDefaultInstance();
        } else {
          reactionBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000200);
        if (profileBuilder_ == null) {
          profile_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.getDefaultInstance();
        } else {
          profileBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000400);
        if (openGroupInvitationBuilder_ == null) {
          openGroupInvitation_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.getDefaultInstance();
        } else {
          openGroupInvitationBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000800);
        if (closedGroupControlMessageBuilder_ == null) {
          closedGroupControlMessage_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.getDefaultInstance();
        } else {
          closedGroupControlMessageBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00001000);
        syncTarget_ = "";
        bitField0_ = (bitField0_ & ~0x00002000);
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_DataMessage_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.DataMessage getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.DataMessage.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.DataMessage build() {
        org.session.libsignal.protos.SignalServiceProtos.DataMessage result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.DataMessage buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.DataMessage result = new org.session.libsignal.protos.SignalServiceProtos.DataMessage(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.body_ = body_;
        if (attachmentsBuilder_ == null) {
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            attachments_ = java.util.Collections.unmodifiableList(attachments_);
            bitField0_ = (bitField0_ & ~0x00000002);
          }
          result.attachments_ = attachments_;
        } else {
          result.attachments_ = attachmentsBuilder_.build();
        }
        if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
          to_bitField0_ |= 0x00000002;
        }
        if (groupBuilder_ == null) {
          result.group_ = group_;
        } else {
          result.group_ = groupBuilder_.build();
        }
        if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
          to_bitField0_ |= 0x00000004;
        }
        result.flags_ = flags_;
        if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
          to_bitField0_ |= 0x00000008;
        }
        result.expireTimer_ = expireTimer_;
        if (((from_bitField0_ & 0x00000020) == 0x00000020)) {
          to_bitField0_ |= 0x00000010;
        }
        result.profileKey_ = profileKey_;
        if (((from_bitField0_ & 0x00000040) == 0x00000040)) {
          to_bitField0_ |= 0x00000020;
        }
        result.timestamp_ = timestamp_;
        if (((from_bitField0_ & 0x00000080) == 0x00000080)) {
          to_bitField0_ |= 0x00000040;
        }
        if (quoteBuilder_ == null) {
          result.quote_ = quote_;
        } else {
          result.quote_ = quoteBuilder_.build();
        }
        if (previewBuilder_ == null) {
          if (((bitField0_ & 0x00000100) == 0x00000100)) {
            preview_ = java.util.Collections.unmodifiableList(preview_);
            bitField0_ = (bitField0_ & ~0x00000100);
          }
          result.preview_ = preview_;
        } else {
          result.preview_ = previewBuilder_.build();
        }
        if (((from_bitField0_ & 0x00000200) == 0x00000200)) {
          to_bitField0_ |= 0x00000080;
        }
        if (reactionBuilder_ == null) {
          result.reaction_ = reaction_;
        } else {
          result.reaction_ = reactionBuilder_.build();
        }
        if (((from_bitField0_ & 0x00000400) == 0x00000400)) {
          to_bitField0_ |= 0x00000100;
        }
        if (profileBuilder_ == null) {
          result.profile_ = profile_;
        } else {
          result.profile_ = profileBuilder_.build();
        }
        if (((from_bitField0_ & 0x00000800) == 0x00000800)) {
          to_bitField0_ |= 0x00000200;
        }
        if (openGroupInvitationBuilder_ == null) {
          result.openGroupInvitation_ = openGroupInvitation_;
        } else {
          result.openGroupInvitation_ = openGroupInvitationBuilder_.build();
        }
        if (((from_bitField0_ & 0x00001000) == 0x00001000)) {
          to_bitField0_ |= 0x00000400;
        }
        if (closedGroupControlMessageBuilder_ == null) {
          result.closedGroupControlMessage_ = closedGroupControlMessage_;
        } else {
          result.closedGroupControlMessage_ = closedGroupControlMessageBuilder_.build();
        }
        if (((from_bitField0_ & 0x00002000) == 0x00002000)) {
          to_bitField0_ |= 0x00000800;
        }
        result.syncTarget_ = syncTarget_;
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.DataMessage) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.DataMessage)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.DataMessage other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.DataMessage.getDefaultInstance()) return this;
        if (other.hasBody()) {
          bitField0_ |= 0x00000001;
          body_ = other.body_;
          onChanged();
        }
        if (attachmentsBuilder_ == null) {
          if (!other.attachments_.isEmpty()) {
            if (attachments_.isEmpty()) {
              attachments_ = other.attachments_;
              bitField0_ = (bitField0_ & ~0x00000002);
            } else {
              ensureAttachmentsIsMutable();
              attachments_.addAll(other.attachments_);
            }
            onChanged();
          }
        } else {
          if (!other.attachments_.isEmpty()) {
            if (attachmentsBuilder_.isEmpty()) {
              attachmentsBuilder_.dispose();
              attachmentsBuilder_ = null;
              attachments_ = other.attachments_;
              bitField0_ = (bitField0_ & ~0x00000002);
              attachmentsBuilder_ = 
                com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                   getAttachmentsFieldBuilder() : null;
            } else {
              attachmentsBuilder_.addAllMessages(other.attachments_);
            }
          }
        }
        if (other.hasGroup()) {
          mergeGroup(other.getGroup());
        }
        if (other.hasFlags()) {
          setFlags(other.getFlags());
        }
        if (other.hasExpireTimer()) {
          setExpireTimer(other.getExpireTimer());
        }
        if (other.hasProfileKey()) {
          setProfileKey(other.getProfileKey());
        }
        if (other.hasTimestamp()) {
          setTimestamp(other.getTimestamp());
        }
        if (other.hasQuote()) {
          mergeQuote(other.getQuote());
        }
        if (previewBuilder_ == null) {
          if (!other.preview_.isEmpty()) {
            if (preview_.isEmpty()) {
              preview_ = other.preview_;
              bitField0_ = (bitField0_ & ~0x00000100);
            } else {
              ensurePreviewIsMutable();
              preview_.addAll(other.preview_);
            }
            onChanged();
          }
        } else {
          if (!other.preview_.isEmpty()) {
            if (previewBuilder_.isEmpty()) {
              previewBuilder_.dispose();
              previewBuilder_ = null;
              preview_ = other.preview_;
              bitField0_ = (bitField0_ & ~0x00000100);
              previewBuilder_ = 
                com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                   getPreviewFieldBuilder() : null;
            } else {
              previewBuilder_.addAllMessages(other.preview_);
            }
          }
        }
        if (other.hasReaction()) {
          mergeReaction(other.getReaction());
        }
        if (other.hasProfile()) {
          mergeProfile(other.getProfile());
        }
        if (other.hasOpenGroupInvitation()) {
          mergeOpenGroupInvitation(other.getOpenGroupInvitation());
        }
        if (other.hasClosedGroupControlMessage()) {
          mergeClosedGroupControlMessage(other.getClosedGroupControlMessage());
        }
        if (other.hasSyncTarget()) {
          bitField0_ |= 0x00002000;
          syncTarget_ = other.syncTarget_;
          onChanged();
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        for (int i = 0; i < getAttachmentsCount(); i++) {
          if (!getAttachments(i).isInitialized()) {
            
            return false;
          }
        }
        if (hasGroup()) {
          if (!getGroup().isInitialized()) {
            
            return false;
          }
        }
        if (hasQuote()) {
          if (!getQuote().isInitialized()) {
            
            return false;
          }
        }
        for (int i = 0; i < getPreviewCount(); i++) {
          if (!getPreview(i).isInitialized()) {
            
            return false;
          }
        }
        if (hasReaction()) {
          if (!getReaction().isInitialized()) {
            
            return false;
          }
        }
        if (hasOpenGroupInvitation()) {
          if (!getOpenGroupInvitation().isInitialized()) {
            
            return false;
          }
        }
        if (hasClosedGroupControlMessage()) {
          if (!getClosedGroupControlMessage().isInitialized()) {
            
            return false;
          }
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.DataMessage parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.DataMessage) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // optional string body = 1;
      private java.lang.Object body_ = "";
      /**
       * <code>optional string body = 1;</code>
       */
      public boolean hasBody() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>optional string body = 1;</code>
       */
      public java.lang.String getBody() {
        java.lang.Object ref = body_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          body_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>optional string body = 1;</code>
       */
      public com.google.protobuf.ByteString
          getBodyBytes() {
        java.lang.Object ref = body_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          body_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>optional string body = 1;</code>
       */
      public Builder setBody(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
        body_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional string body = 1;</code>
       */
      public Builder clearBody() {
        bitField0_ = (bitField0_ & ~0x00000001);
        body_ = getDefaultInstance().getBody();
        onChanged();
        return this;
      }
      /**
       * <code>optional string body = 1;</code>
       */
      public Builder setBodyBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
        body_ = value;
        onChanged();
        return this;
      }

      // repeated .signalservice.AttachmentPointer attachments = 2;
      private java.util.List<org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer> attachments_ =
        java.util.Collections.emptyList();
      private void ensureAttachmentsIsMutable() {
        if (!((bitField0_ & 0x00000002) == 0x00000002)) {
          attachments_ = new java.util.ArrayList<org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer>(attachments_);
          bitField0_ |= 0x00000002;
         }
      }

      private com.google.protobuf.RepeatedFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder> attachmentsBuilder_;

      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public java.util.List<org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer> getAttachmentsList() {
        if (attachmentsBuilder_ == null) {
          return java.util.Collections.unmodifiableList(attachments_);
        } else {
          return attachmentsBuilder_.getMessageList();
        }
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public int getAttachmentsCount() {
        if (attachmentsBuilder_ == null) {
          return attachments_.size();
        } else {
          return attachmentsBuilder_.getCount();
        }
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getAttachments(int index) {
        if (attachmentsBuilder_ == null) {
          return attachments_.get(index);
        } else {
          return attachmentsBuilder_.getMessage(index);
        }
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public Builder setAttachments(
          int index, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer value) {
        if (attachmentsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureAttachmentsIsMutable();
          attachments_.set(index, value);
          onChanged();
        } else {
          attachmentsBuilder_.setMessage(index, value);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public Builder setAttachments(
          int index, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder builderForValue) {
        if (attachmentsBuilder_ == null) {
          ensureAttachmentsIsMutable();
          attachments_.set(index, builderForValue.build());
          onChanged();
        } else {
          attachmentsBuilder_.setMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public Builder addAttachments(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer value) {
        if (attachmentsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureAttachmentsIsMutable();
          attachments_.add(value);
          onChanged();
        } else {
          attachmentsBuilder_.addMessage(value);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public Builder addAttachments(
          int index, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer value) {
        if (attachmentsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureAttachmentsIsMutable();
          attachments_.add(index, value);
          onChanged();
        } else {
          attachmentsBuilder_.addMessage(index, value);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public Builder addAttachments(
          org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder builderForValue) {
        if (attachmentsBuilder_ == null) {
          ensureAttachmentsIsMutable();
          attachments_.add(builderForValue.build());
          onChanged();
        } else {
          attachmentsBuilder_.addMessage(builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public Builder addAttachments(
          int index, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder builderForValue) {
        if (attachmentsBuilder_ == null) {
          ensureAttachmentsIsMutable();
          attachments_.add(index, builderForValue.build());
          onChanged();
        } else {
          attachmentsBuilder_.addMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public Builder addAllAttachments(
          java.lang.Iterable<? extends org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer> values) {
        if (attachmentsBuilder_ == null) {
          ensureAttachmentsIsMutable();
          super.addAll(values, attachments_);
          onChanged();
        } else {
          attachmentsBuilder_.addAllMessages(values);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public Builder clearAttachments() {
        if (attachmentsBuilder_ == null) {
          attachments_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000002);
          onChanged();
        } else {
          attachmentsBuilder_.clear();
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public Builder removeAttachments(int index) {
        if (attachmentsBuilder_ == null) {
          ensureAttachmentsIsMutable();
          attachments_.remove(index);
          onChanged();
        } else {
          attachmentsBuilder_.remove(index);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder getAttachmentsBuilder(
          int index) {
        return getAttachmentsFieldBuilder().getBuilder(index);
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder getAttachmentsOrBuilder(
          int index) {
        if (attachmentsBuilder_ == null) {
          return attachments_.get(index);  } else {
          return attachmentsBuilder_.getMessageOrBuilder(index);
        }
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder> 
           getAttachmentsOrBuilderList() {
        if (attachmentsBuilder_ != null) {
          return attachmentsBuilder_.getMessageOrBuilderList();
        } else {
          return java.util.Collections.unmodifiableList(attachments_);
        }
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder addAttachmentsBuilder() {
        return getAttachmentsFieldBuilder().addBuilder(
            org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance());
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder addAttachmentsBuilder(
          int index) {
        return getAttachmentsFieldBuilder().addBuilder(
            index, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance());
      }
      /**
       * <code>repeated .signalservice.AttachmentPointer attachments = 2;</code>
       */
      public java.util.List<org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder> 
           getAttachmentsBuilderList() {
        return getAttachmentsFieldBuilder().getBuilderList();
      }
      private com.google.protobuf.RepeatedFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder> 
          getAttachmentsFieldBuilder() {
        if (attachmentsBuilder_ == null) {
          attachmentsBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder>(
                  attachments_,
                  ((bitField0_ & 0x00000002) == 0x00000002),
                  getParentForChildren(),
                  isClean());
          attachments_ = null;
        }
        return attachmentsBuilder_;
      }

      // optional .signalservice.GroupContext group = 3;
      private org.session.libsignal.protos.SignalServiceProtos.GroupContext group_ = org.session.libsignal.protos.SignalServiceProtos.GroupContext.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.GroupContext, org.session.libsignal.protos.SignalServiceProtos.GroupContext.Builder, org.session.libsignal.protos.SignalServiceProtos.GroupContextOrBuilder> groupBuilder_;
      /**
       * <code>optional .signalservice.GroupContext group = 3;</code>
       */
      public boolean hasGroup() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional .signalservice.GroupContext group = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.GroupContext getGroup() {
        if (groupBuilder_ == null) {
          return group_;
        } else {
          return groupBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.GroupContext group = 3;</code>
       */
      public Builder setGroup(org.session.libsignal.protos.SignalServiceProtos.GroupContext value) {
        if (groupBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          group_ = value;
          onChanged();
        } else {
          groupBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000004;
        return this;
      }
      /**
       * <code>optional .signalservice.GroupContext group = 3;</code>
       */
      public Builder setGroup(
          org.session.libsignal.protos.SignalServiceProtos.GroupContext.Builder builderForValue) {
        if (groupBuilder_ == null) {
          group_ = builderForValue.build();
          onChanged();
        } else {
          groupBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000004;
        return this;
      }
      /**
       * <code>optional .signalservice.GroupContext group = 3;</code>
       */
      public Builder mergeGroup(org.session.libsignal.protos.SignalServiceProtos.GroupContext value) {
        if (groupBuilder_ == null) {
          if (((bitField0_ & 0x00000004) == 0x00000004) &&
              group_ != org.session.libsignal.protos.SignalServiceProtos.GroupContext.getDefaultInstance()) {
            group_ =
              org.session.libsignal.protos.SignalServiceProtos.GroupContext.newBuilder(group_).mergeFrom(value).buildPartial();
          } else {
            group_ = value;
          }
          onChanged();
        } else {
          groupBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000004;
        return this;
      }
      /**
       * <code>optional .signalservice.GroupContext group = 3;</code>
       */
      public Builder clearGroup() {
        if (groupBuilder_ == null) {
          group_ = org.session.libsignal.protos.SignalServiceProtos.GroupContext.getDefaultInstance();
          onChanged();
        } else {
          groupBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000004);
        return this;
      }
      /**
       * <code>optional .signalservice.GroupContext group = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.GroupContext.Builder getGroupBuilder() {
        bitField0_ |= 0x00000004;
        onChanged();
        return getGroupFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.GroupContext group = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.GroupContextOrBuilder getGroupOrBuilder() {
        if (groupBuilder_ != null) {
          return groupBuilder_.getMessageOrBuilder();
        } else {
          return group_;
        }
      }
      /**
       * <code>optional .signalservice.GroupContext group = 3;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.GroupContext, org.session.libsignal.protos.SignalServiceProtos.GroupContext.Builder, org.session.libsignal.protos.SignalServiceProtos.GroupContextOrBuilder> 
          getGroupFieldBuilder() {
        if (groupBuilder_ == null) {
          groupBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.GroupContext, org.session.libsignal.protos.SignalServiceProtos.GroupContext.Builder, org.session.libsignal.protos.SignalServiceProtos.GroupContextOrBuilder>(
                  group_,
                  getParentForChildren(),
                  isClean());
          group_ = null;
        }
        return groupBuilder_;
      }

      // optional uint32 flags = 4;
      private int flags_ ;
      /**
       * <code>optional uint32 flags = 4;</code>
       */
      public boolean hasFlags() {
        return ((bitField0_ & 0x00000008) == 0x00000008);
      }
      /**
       * <code>optional uint32 flags = 4;</code>
       */
      public int getFlags() {
        return flags_;
      }
      /**
       * <code>optional uint32 flags = 4;</code>
       */
      public Builder setFlags(int value) {
        bitField0_ |= 0x00000008;
        flags_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional uint32 flags = 4;</code>
       */
      public Builder clearFlags() {
        bitField0_ = (bitField0_ & ~0x00000008);
        flags_ = 0;
        onChanged();
        return this;
      }

      // optional uint32 expireTimer = 5;
      private int expireTimer_ ;
      /**
       * <code>optional uint32 expireTimer = 5;</code>
       */
      public boolean hasExpireTimer() {
        return ((bitField0_ & 0x00000010) == 0x00000010);
      }
      /**
       * <code>optional uint32 expireTimer = 5;</code>
       */
      public int getExpireTimer() {
        return expireTimer_;
      }
      /**
       * <code>optional uint32 expireTimer = 5;</code>
       */
      public Builder setExpireTimer(int value) {
        bitField0_ |= 0x00000010;
        expireTimer_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional uint32 expireTimer = 5;</code>
       */
      public Builder clearExpireTimer() {
        bitField0_ = (bitField0_ & ~0x00000010);
        expireTimer_ = 0;
        onChanged();
        return this;
      }

      // optional bytes profileKey = 6;
      private com.google.protobuf.ByteString profileKey_ = com.google.protobuf.ByteString.EMPTY;
      /**
       * <code>optional bytes profileKey = 6;</code>
       */
      public boolean hasProfileKey() {
        return ((bitField0_ & 0x00000020) == 0x00000020);
      }
      /**
       * <code>optional bytes profileKey = 6;</code>
       */
      public com.google.protobuf.ByteString getProfileKey() {
        return profileKey_;
      }
      /**
       * <code>optional bytes profileKey = 6;</code>
       */
      public Builder setProfileKey(com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000020;
        profileKey_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional bytes profileKey = 6;</code>
       */
      public Builder clearProfileKey() {
        bitField0_ = (bitField0_ & ~0x00000020);
        profileKey_ = getDefaultInstance().getProfileKey();
        onChanged();
        return this;
      }

      // optional uint64 timestamp = 7;
      private long timestamp_ ;
      /**
       * <code>optional uint64 timestamp = 7;</code>
       */
      public boolean hasTimestamp() {
        return ((bitField0_ & 0x00000040) == 0x00000040);
      }
      /**
       * <code>optional uint64 timestamp = 7;</code>
       */
      public long getTimestamp() {
        return timestamp_;
      }
      /**
       * <code>optional uint64 timestamp = 7;</code>
       */
      public Builder setTimestamp(long value) {
        bitField0_ |= 0x00000040;
        timestamp_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional uint64 timestamp = 7;</code>
       */
      public Builder clearTimestamp() {
        bitField0_ = (bitField0_ & ~0x00000040);
        timestamp_ = 0L;
        onChanged();
        return this;
      }

      // optional .signalservice.DataMessage.Quote quote = 8;
      private org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote quote_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.QuoteOrBuilder> quoteBuilder_;
      /**
       * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
       */
      public boolean hasQuote() {
        return ((bitField0_ & 0x00000080) == 0x00000080);
      }
      /**
       * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote getQuote() {
        if (quoteBuilder_ == null) {
          return quote_;
        } else {
          return quoteBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
       */
      public Builder setQuote(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote value) {
        if (quoteBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          quote_ = value;
          onChanged();
        } else {
          quoteBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000080;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
       */
      public Builder setQuote(
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.Builder builderForValue) {
        if (quoteBuilder_ == null) {
          quote_ = builderForValue.build();
          onChanged();
        } else {
          quoteBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000080;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
       */
      public Builder mergeQuote(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote value) {
        if (quoteBuilder_ == null) {
          if (((bitField0_ & 0x00000080) == 0x00000080) &&
              quote_ != org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.getDefaultInstance()) {
            quote_ =
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.newBuilder(quote_).mergeFrom(value).buildPartial();
          } else {
            quote_ = value;
          }
          onChanged();
        } else {
          quoteBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000080;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
       */
      public Builder clearQuote() {
        if (quoteBuilder_ == null) {
          quote_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.getDefaultInstance();
          onChanged();
        } else {
          quoteBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000080);
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.Builder getQuoteBuilder() {
        bitField0_ |= 0x00000080;
        onChanged();
        return getQuoteFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.QuoteOrBuilder getQuoteOrBuilder() {
        if (quoteBuilder_ != null) {
          return quoteBuilder_.getMessageOrBuilder();
        } else {
          return quote_;
        }
      }
      /**
       * <code>optional .signalservice.DataMessage.Quote quote = 8;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.QuoteOrBuilder> 
          getQuoteFieldBuilder() {
        if (quoteBuilder_ == null) {
          quoteBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Quote.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.QuoteOrBuilder>(
                  quote_,
                  getParentForChildren(),
                  isClean());
          quote_ = null;
        }
        return quoteBuilder_;
      }

      // repeated .signalservice.DataMessage.Preview preview = 10;
      private java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview> preview_ =
        java.util.Collections.emptyList();
      private void ensurePreviewIsMutable() {
        if (!((bitField0_ & 0x00000100) == 0x00000100)) {
          preview_ = new java.util.ArrayList<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview>(preview_);
          bitField0_ |= 0x00000100;
         }
      }

      private com.google.protobuf.RepeatedFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.PreviewOrBuilder> previewBuilder_;

      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview> getPreviewList() {
        if (previewBuilder_ == null) {
          return java.util.Collections.unmodifiableList(preview_);
        } else {
          return previewBuilder_.getMessageList();
        }
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public int getPreviewCount() {
        if (previewBuilder_ == null) {
          return preview_.size();
        } else {
          return previewBuilder_.getCount();
        }
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview getPreview(int index) {
        if (previewBuilder_ == null) {
          return preview_.get(index);
        } else {
          return previewBuilder_.getMessage(index);
        }
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public Builder setPreview(
          int index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview value) {
        if (previewBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensurePreviewIsMutable();
          preview_.set(index, value);
          onChanged();
        } else {
          previewBuilder_.setMessage(index, value);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public Builder setPreview(
          int index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.Builder builderForValue) {
        if (previewBuilder_ == null) {
          ensurePreviewIsMutable();
          preview_.set(index, builderForValue.build());
          onChanged();
        } else {
          previewBuilder_.setMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public Builder addPreview(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview value) {
        if (previewBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensurePreviewIsMutable();
          preview_.add(value);
          onChanged();
        } else {
          previewBuilder_.addMessage(value);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public Builder addPreview(
          int index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview value) {
        if (previewBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensurePreviewIsMutable();
          preview_.add(index, value);
          onChanged();
        } else {
          previewBuilder_.addMessage(index, value);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public Builder addPreview(
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.Builder builderForValue) {
        if (previewBuilder_ == null) {
          ensurePreviewIsMutable();
          preview_.add(builderForValue.build());
          onChanged();
        } else {
          previewBuilder_.addMessage(builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public Builder addPreview(
          int index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.Builder builderForValue) {
        if (previewBuilder_ == null) {
          ensurePreviewIsMutable();
          preview_.add(index, builderForValue.build());
          onChanged();
        } else {
          previewBuilder_.addMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public Builder addAllPreview(
          java.lang.Iterable<? extends org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview> values) {
        if (previewBuilder_ == null) {
          ensurePreviewIsMutable();
          super.addAll(values, preview_);
          onChanged();
        } else {
          previewBuilder_.addAllMessages(values);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public Builder clearPreview() {
        if (previewBuilder_ == null) {
          preview_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000100);
          onChanged();
        } else {
          previewBuilder_.clear();
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public Builder removePreview(int index) {
        if (previewBuilder_ == null) {
          ensurePreviewIsMutable();
          preview_.remove(index);
          onChanged();
        } else {
          previewBuilder_.remove(index);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.Builder getPreviewBuilder(
          int index) {
        return getPreviewFieldBuilder().getBuilder(index);
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.PreviewOrBuilder getPreviewOrBuilder(
          int index) {
        if (previewBuilder_ == null) {
          return preview_.get(index);  } else {
          return previewBuilder_.getMessageOrBuilder(index);
        }
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.DataMessage.PreviewOrBuilder> 
           getPreviewOrBuilderList() {
        if (previewBuilder_ != null) {
          return previewBuilder_.getMessageOrBuilderList();
        } else {
          return java.util.Collections.unmodifiableList(preview_);
        }
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.Builder addPreviewBuilder() {
        return getPreviewFieldBuilder().addBuilder(
            org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.getDefaultInstance());
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.Builder addPreviewBuilder(
          int index) {
        return getPreviewFieldBuilder().addBuilder(
            index, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.getDefaultInstance());
      }
      /**
       * <code>repeated .signalservice.DataMessage.Preview preview = 10;</code>
       */
      public java.util.List<org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.Builder> 
           getPreviewBuilderList() {
        return getPreviewFieldBuilder().getBuilderList();
      }
      private com.google.protobuf.RepeatedFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.PreviewOrBuilder> 
          getPreviewFieldBuilder() {
        if (previewBuilder_ == null) {
          previewBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Preview.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.PreviewOrBuilder>(
                  preview_,
                  ((bitField0_ & 0x00000100) == 0x00000100),
                  getParentForChildren(),
                  isClean());
          preview_ = null;
        }
        return previewBuilder_;
      }

      // optional .signalservice.DataMessage.Reaction reaction = 11;
      private org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction reaction_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ReactionOrBuilder> reactionBuilder_;
      /**
       * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
       */
      public boolean hasReaction() {
        return ((bitField0_ & 0x00000200) == 0x00000200);
      }
      /**
       * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction getReaction() {
        if (reactionBuilder_ == null) {
          return reaction_;
        } else {
          return reactionBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
       */
      public Builder setReaction(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction value) {
        if (reactionBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          reaction_ = value;
          onChanged();
        } else {
          reactionBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000200;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
       */
      public Builder setReaction(
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Builder builderForValue) {
        if (reactionBuilder_ == null) {
          reaction_ = builderForValue.build();
          onChanged();
        } else {
          reactionBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000200;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
       */
      public Builder mergeReaction(org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction value) {
        if (reactionBuilder_ == null) {
          if (((bitField0_ & 0x00000200) == 0x00000200) &&
              reaction_ != org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.getDefaultInstance()) {
            reaction_ =
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.newBuilder(reaction_).mergeFrom(value).buildPartial();
          } else {
            reaction_ = value;
          }
          onChanged();
        } else {
          reactionBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000200;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
       */
      public Builder clearReaction() {
        if (reactionBuilder_ == null) {
          reaction_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.getDefaultInstance();
          onChanged();
        } else {
          reactionBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000200);
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Builder getReactionBuilder() {
        bitField0_ |= 0x00000200;
        onChanged();
        return getReactionFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ReactionOrBuilder getReactionOrBuilder() {
        if (reactionBuilder_ != null) {
          return reactionBuilder_.getMessageOrBuilder();
        } else {
          return reaction_;
        }
      }
      /**
       * <code>optional .signalservice.DataMessage.Reaction reaction = 11;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ReactionOrBuilder> 
          getReactionFieldBuilder() {
        if (reactionBuilder_ == null) {
          reactionBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction, org.session.libsignal.protos.SignalServiceProtos.DataMessage.Reaction.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ReactionOrBuilder>(
                  reaction_,
                  getParentForChildren(),
                  isClean());
          reaction_ = null;
        }
        return reactionBuilder_;
      }

      // optional .signalservice.DataMessage.LokiProfile profile = 101;
      private org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile profile_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder> profileBuilder_;
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
       */
      public boolean hasProfile() {
        return ((bitField0_ & 0x00000400) == 0x00000400);
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile getProfile() {
        if (profileBuilder_ == null) {
          return profile_;
        } else {
          return profileBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
       */
      public Builder setProfile(org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile value) {
        if (profileBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          profile_ = value;
          onChanged();
        } else {
          profileBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000400;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
       */
      public Builder setProfile(
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder builderForValue) {
        if (profileBuilder_ == null) {
          profile_ = builderForValue.build();
          onChanged();
        } else {
          profileBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000400;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
       */
      public Builder mergeProfile(org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile value) {
        if (profileBuilder_ == null) {
          if (((bitField0_ & 0x00000400) == 0x00000400) &&
              profile_ != org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.getDefaultInstance()) {
            profile_ =
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.newBuilder(profile_).mergeFrom(value).buildPartial();
          } else {
            profile_ = value;
          }
          onChanged();
        } else {
          profileBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000400;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
       */
      public Builder clearProfile() {
        if (profileBuilder_ == null) {
          profile_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.getDefaultInstance();
          onChanged();
        } else {
          profileBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000400);
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder getProfileBuilder() {
        bitField0_ |= 0x00000400;
        onChanged();
        return getProfileFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder getProfileOrBuilder() {
        if (profileBuilder_ != null) {
          return profileBuilder_.getMessageOrBuilder();
        } else {
          return profile_;
        }
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 101;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder> 
          getProfileFieldBuilder() {
        if (profileBuilder_ == null) {
          profileBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder>(
                  profile_,
                  getParentForChildren(),
                  isClean());
          profile_ = null;
        }
        return profileBuilder_;
      }

      // optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;
      private org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation openGroupInvitation_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation, org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitationOrBuilder> openGroupInvitationBuilder_;
      /**
       * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
       */
      public boolean hasOpenGroupInvitation() {
        return ((bitField0_ & 0x00000800) == 0x00000800);
      }
      /**
       * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation getOpenGroupInvitation() {
        if (openGroupInvitationBuilder_ == null) {
          return openGroupInvitation_;
        } else {
          return openGroupInvitationBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
       */
      public Builder setOpenGroupInvitation(org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation value) {
        if (openGroupInvitationBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          openGroupInvitation_ = value;
          onChanged();
        } else {
          openGroupInvitationBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000800;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
       */
      public Builder setOpenGroupInvitation(
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.Builder builderForValue) {
        if (openGroupInvitationBuilder_ == null) {
          openGroupInvitation_ = builderForValue.build();
          onChanged();
        } else {
          openGroupInvitationBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000800;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
       */
      public Builder mergeOpenGroupInvitation(org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation value) {
        if (openGroupInvitationBuilder_ == null) {
          if (((bitField0_ & 0x00000800) == 0x00000800) &&
              openGroupInvitation_ != org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.getDefaultInstance()) {
            openGroupInvitation_ =
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.newBuilder(openGroupInvitation_).mergeFrom(value).buildPartial();
          } else {
            openGroupInvitation_ = value;
          }
          onChanged();
        } else {
          openGroupInvitationBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000800;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
       */
      public Builder clearOpenGroupInvitation() {
        if (openGroupInvitationBuilder_ == null) {
          openGroupInvitation_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.getDefaultInstance();
          onChanged();
        } else {
          openGroupInvitationBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000800);
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.Builder getOpenGroupInvitationBuilder() {
        bitField0_ |= 0x00000800;
        onChanged();
        return getOpenGroupInvitationFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitationOrBuilder getOpenGroupInvitationOrBuilder() {
        if (openGroupInvitationBuilder_ != null) {
          return openGroupInvitationBuilder_.getMessageOrBuilder();
        } else {
          return openGroupInvitation_;
        }
      }
      /**
       * <code>optional .signalservice.DataMessage.OpenGroupInvitation openGroupInvitation = 102;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation, org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitationOrBuilder> 
          getOpenGroupInvitationFieldBuilder() {
        if (openGroupInvitationBuilder_ == null) {
          openGroupInvitationBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation, org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitation.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.OpenGroupInvitationOrBuilder>(
                  openGroupInvitation_,
                  getParentForChildren(),
                  isClean());
          openGroupInvitation_ = null;
        }
        return openGroupInvitationBuilder_;
      }

      // optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;
      private org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage closedGroupControlMessage_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessageOrBuilder> closedGroupControlMessageBuilder_;
      /**
       * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
       */
      public boolean hasClosedGroupControlMessage() {
        return ((bitField0_ & 0x00001000) == 0x00001000);
      }
      /**
       * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage getClosedGroupControlMessage() {
        if (closedGroupControlMessageBuilder_ == null) {
          return closedGroupControlMessage_;
        } else {
          return closedGroupControlMessageBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
       */
      public Builder setClosedGroupControlMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage value) {
        if (closedGroupControlMessageBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          closedGroupControlMessage_ = value;
          onChanged();
        } else {
          closedGroupControlMessageBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00001000;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
       */
      public Builder setClosedGroupControlMessage(
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Builder builderForValue) {
        if (closedGroupControlMessageBuilder_ == null) {
          closedGroupControlMessage_ = builderForValue.build();
          onChanged();
        } else {
          closedGroupControlMessageBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00001000;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
       */
      public Builder mergeClosedGroupControlMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage value) {
        if (closedGroupControlMessageBuilder_ == null) {
          if (((bitField0_ & 0x00001000) == 0x00001000) &&
              closedGroupControlMessage_ != org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.getDefaultInstance()) {
            closedGroupControlMessage_ =
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.newBuilder(closedGroupControlMessage_).mergeFrom(value).buildPartial();
          } else {
            closedGroupControlMessage_ = value;
          }
          onChanged();
        } else {
          closedGroupControlMessageBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00001000;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
       */
      public Builder clearClosedGroupControlMessage() {
        if (closedGroupControlMessageBuilder_ == null) {
          closedGroupControlMessage_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.getDefaultInstance();
          onChanged();
        } else {
          closedGroupControlMessageBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00001000);
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Builder getClosedGroupControlMessageBuilder() {
        bitField0_ |= 0x00001000;
        onChanged();
        return getClosedGroupControlMessageFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessageOrBuilder getClosedGroupControlMessageOrBuilder() {
        if (closedGroupControlMessageBuilder_ != null) {
          return closedGroupControlMessageBuilder_.getMessageOrBuilder();
        } else {
          return closedGroupControlMessage_;
        }
      }
      /**
       * <code>optional .signalservice.DataMessage.ClosedGroupControlMessage closedGroupControlMessage = 104;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessageOrBuilder> 
          getClosedGroupControlMessageFieldBuilder() {
        if (closedGroupControlMessageBuilder_ == null) {
          closedGroupControlMessageBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessage.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.ClosedGroupControlMessageOrBuilder>(
                  closedGroupControlMessage_,
                  getParentForChildren(),
                  isClean());
          closedGroupControlMessage_ = null;
        }
        return closedGroupControlMessageBuilder_;
      }

      // optional string syncTarget = 105;
      private java.lang.Object syncTarget_ = "";
      /**
       * <code>optional string syncTarget = 105;</code>
       */
      public boolean hasSyncTarget() {
        return ((bitField0_ & 0x00002000) == 0x00002000);
      }
      /**
       * <code>optional string syncTarget = 105;</code>
       */
      public java.lang.String getSyncTarget() {
        java.lang.Object ref = syncTarget_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          syncTarget_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>optional string syncTarget = 105;</code>
       */
      public com.google.protobuf.ByteString
          getSyncTargetBytes() {
        java.lang.Object ref = syncTarget_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          syncTarget_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>optional string syncTarget = 105;</code>
       */
      public Builder setSyncTarget(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00002000;
        syncTarget_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional string syncTarget = 105;</code>
       */
      public Builder clearSyncTarget() {
        bitField0_ = (bitField0_ & ~0x00002000);
        syncTarget_ = getDefaultInstance().getSyncTarget();
        onChanged();
        return this;
      }
      /**
       * <code>optional string syncTarget = 105;</code>
       */
      public Builder setSyncTargetBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00002000;
        syncTarget_ = value;
        onChanged();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.DataMessage)
    }

    static {
      defaultInstance = new DataMessage(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.DataMessage)
  }

  public interface CallMessageOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // required .signalservice.CallMessage.Type type = 1;
    /**
     * <code>required .signalservice.CallMessage.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasType();
    /**
     * <code>required .signalservice.CallMessage.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    org.session.libsignal.protos.SignalServiceProtos.CallMessage.Type getType();

    // repeated string sdps = 2;
    /**
     * <code>repeated string sdps = 2;</code>
     */
    java.util.List<java.lang.String>
    getSdpsList();
    /**
     * <code>repeated string sdps = 2;</code>
     */
    int getSdpsCount();
    /**
     * <code>repeated string sdps = 2;</code>
     */
    java.lang.String getSdps(int index);
    /**
     * <code>repeated string sdps = 2;</code>
     */
    com.google.protobuf.ByteString
        getSdpsBytes(int index);

    // repeated uint32 sdpMLineIndexes = 3;
    /**
     * <code>repeated uint32 sdpMLineIndexes = 3;</code>
     */
    java.util.List<java.lang.Integer> getSdpMLineIndexesList();
    /**
     * <code>repeated uint32 sdpMLineIndexes = 3;</code>
     */
    int getSdpMLineIndexesCount();
    /**
     * <code>repeated uint32 sdpMLineIndexes = 3;</code>
     */
    int getSdpMLineIndexes(int index);

    // repeated string sdpMids = 4;
    /**
     * <code>repeated string sdpMids = 4;</code>
     */
    java.util.List<java.lang.String>
    getSdpMidsList();
    /**
     * <code>repeated string sdpMids = 4;</code>
     */
    int getSdpMidsCount();
    /**
     * <code>repeated string sdpMids = 4;</code>
     */
    java.lang.String getSdpMids(int index);
    /**
     * <code>repeated string sdpMids = 4;</code>
     */
    com.google.protobuf.ByteString
        getSdpMidsBytes(int index);

    // required string uuid = 5;
    /**
     * <code>required string uuid = 5;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasUuid();
    /**
     * <code>required string uuid = 5;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    java.lang.String getUuid();
    /**
     * <code>required string uuid = 5;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    com.google.protobuf.ByteString
        getUuidBytes();
  }
  /**
   * Protobuf type {@code signalservice.CallMessage}
   */
  public static final class CallMessage extends
      com.google.protobuf.GeneratedMessage
      implements CallMessageOrBuilder {
    // Use CallMessage.newBuilder() to construct.
    private CallMessage(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private CallMessage(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final CallMessage defaultInstance;
    public static CallMessage getDefaultInstance() {
      return defaultInstance;
    }

    public CallMessage getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private CallMessage(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 8: {
              int rawValue = input.readEnum();
              org.session.libsignal.protos.SignalServiceProtos.CallMessage.Type value = org.session.libsignal.protos.SignalServiceProtos.CallMessage.Type.valueOf(rawValue);
              if (value == null) {
                unknownFields.mergeVarintField(1, rawValue);
              } else {
                bitField0_ |= 0x00000001;
                type_ = value;
              }
              break;
            }
            case 18: {
              if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
                sdps_ = new com.google.protobuf.LazyStringArrayList();
                mutable_bitField0_ |= 0x00000002;
              }
              sdps_.add(input.readBytes());
              break;
            }
            case 24: {
              if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
                sdpMLineIndexes_ = new java.util.ArrayList<java.lang.Integer>();
                mutable_bitField0_ |= 0x00000004;
              }
              sdpMLineIndexes_.add(input.readUInt32());
              break;
            }
            case 26: {
              int length = input.readRawVarint32();
              int limit = input.pushLimit(length);
              if (!((mutable_bitField0_ & 0x00000004) == 0x00000004) && input.getBytesUntilLimit() > 0) {
                sdpMLineIndexes_ = new java.util.ArrayList<java.lang.Integer>();
                mutable_bitField0_ |= 0x00000004;
              }
              while (input.getBytesUntilLimit() > 0) {
                sdpMLineIndexes_.add(input.readUInt32());
              }
              input.popLimit(limit);
              break;
            }
            case 34: {
              if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
                sdpMids_ = new com.google.protobuf.LazyStringArrayList();
                mutable_bitField0_ |= 0x00000008;
              }
              sdpMids_.add(input.readBytes());
              break;
            }
            case 42: {
              bitField0_ |= 0x00000002;
              uuid_ = input.readBytes();
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
          sdps_ = new com.google.protobuf.UnmodifiableLazyStringList(sdps_);
        }
        if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
          sdpMLineIndexes_ = java.util.Collections.unmodifiableList(sdpMLineIndexes_);
        }
        if (((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
          sdpMids_ = new com.google.protobuf.UnmodifiableLazyStringList(sdpMids_);
        }
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_CallMessage_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_CallMessage_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.CallMessage.class, org.session.libsignal.protos.SignalServiceProtos.CallMessage.Builder.class);
    }

    public static com.google.protobuf.Parser<CallMessage> PARSER =
        new com.google.protobuf.AbstractParser<CallMessage>() {
      public CallMessage parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new CallMessage(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<CallMessage> getParserForType() {
      return PARSER;
    }

    /**
     * Protobuf enum {@code signalservice.CallMessage.Type}
     */
    public enum Type
        implements com.google.protobuf.ProtocolMessageEnum {
      /**
       * <code>PRE_OFFER = 6;</code>
       */
      PRE_OFFER(0, 6),
      /**
       * <code>OFFER = 1;</code>
       */
      OFFER(1, 1),
      /**
       * <code>ANSWER = 2;</code>
       */
      ANSWER(2, 2),
      /**
       * <code>PROVISIONAL_ANSWER = 3;</code>
       */
      PROVISIONAL_ANSWER(3, 3),
      /**
       * <code>ICE_CANDIDATES = 4;</code>
       */
      ICE_CANDIDATES(4, 4),
      /**
       * <code>END_CALL = 5;</code>
       */
      END_CALL(5, 5),
      ;

      /**
       * <code>PRE_OFFER = 6;</code>
       */
      public static final int PRE_OFFER_VALUE = 6;
      /**
       * <code>OFFER = 1;</code>
       */
      public static final int OFFER_VALUE = 1;
      /**
       * <code>ANSWER = 2;</code>
       */
      public static final int ANSWER_VALUE = 2;
      /**
       * <code>PROVISIONAL_ANSWER = 3;</code>
       */
      public static final int PROVISIONAL_ANSWER_VALUE = 3;
      /**
       * <code>ICE_CANDIDATES = 4;</code>
       */
      public static final int ICE_CANDIDATES_VALUE = 4;
      /**
       * <code>END_CALL = 5;</code>
       */
      public static final int END_CALL_VALUE = 5;


      public final int getNumber() { return value; }

      public static Type valueOf(int value) {
        switch (value) {
          case 6: return PRE_OFFER;
          case 1: return OFFER;
          case 2: return ANSWER;
          case 3: return PROVISIONAL_ANSWER;
          case 4: return ICE_CANDIDATES;
          case 5: return END_CALL;
          default: return null;
        }
      }

      public static com.google.protobuf.Internal.EnumLiteMap<Type>
          internalGetValueMap() {
        return internalValueMap;
      }
      private static com.google.protobuf.Internal.EnumLiteMap<Type>
          internalValueMap =
            new com.google.protobuf.Internal.EnumLiteMap<Type>() {
              public Type findValueByNumber(int number) {
                return Type.valueOf(number);
              }
            };

      public final com.google.protobuf.Descriptors.EnumValueDescriptor
          getValueDescriptor() {
        return getDescriptor().getValues().get(index);
      }
      public final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptorForType() {
        return getDescriptor();
      }
      public static final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.CallMessage.getDescriptor().getEnumTypes().get(0);
      }

      private static final Type[] VALUES = values();

      public static Type valueOf(
          com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
        if (desc.getType() != getDescriptor()) {
          throw new java.lang.IllegalArgumentException(
            "EnumValueDescriptor is not for this type.");
        }
        return VALUES[desc.getIndex()];
      }

      private final int index;
      private final int value;

      private Type(int index, int value) {
        this.index = index;
        this.value = value;
      }

      // @@protoc_insertion_point(enum_scope:signalservice.CallMessage.Type)
    }

    private int bitField0_;
    // required .signalservice.CallMessage.Type type = 1;
    public static final int TYPE_FIELD_NUMBER = 1;
    private org.session.libsignal.protos.SignalServiceProtos.CallMessage.Type type_;
    /**
     * <code>required .signalservice.CallMessage.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasType() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>required .signalservice.CallMessage.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public org.session.libsignal.protos.SignalServiceProtos.CallMessage.Type getType() {
      return type_;
    }

    // repeated string sdps = 2;
    public static final int SDPS_FIELD_NUMBER = 2;
    private com.google.protobuf.LazyStringList sdps_;
    /**
     * <code>repeated string sdps = 2;</code>
     */
    public java.util.List<java.lang.String>
        getSdpsList() {
      return sdps_;
    }
    /**
     * <code>repeated string sdps = 2;</code>
     */
    public int getSdpsCount() {
      return sdps_.size();
    }
    /**
     * <code>repeated string sdps = 2;</code>
     */
    public java.lang.String getSdps(int index) {
      return sdps_.get(index);
    }
    /**
     * <code>repeated string sdps = 2;</code>
     */
    public com.google.protobuf.ByteString
        getSdpsBytes(int index) {
      return sdps_.getByteString(index);
    }

    // repeated uint32 sdpMLineIndexes = 3;
    public static final int SDPMLINEINDEXES_FIELD_NUMBER = 3;
    private java.util.List<java.lang.Integer> sdpMLineIndexes_;
    /**
     * <code>repeated uint32 sdpMLineIndexes = 3;</code>
     */
    public java.util.List<java.lang.Integer>
        getSdpMLineIndexesList() {
      return sdpMLineIndexes_;
    }
    /**
     * <code>repeated uint32 sdpMLineIndexes = 3;</code>
     */
    public int getSdpMLineIndexesCount() {
      return sdpMLineIndexes_.size();
    }
    /**
     * <code>repeated uint32 sdpMLineIndexes = 3;</code>
     */
    public int getSdpMLineIndexes(int index) {
      return sdpMLineIndexes_.get(index);
    }

    // repeated string sdpMids = 4;
    public static final int SDPMIDS_FIELD_NUMBER = 4;
    private com.google.protobuf.LazyStringList sdpMids_;
    /**
     * <code>repeated string sdpMids = 4;</code>
     */
    public java.util.List<java.lang.String>
        getSdpMidsList() {
      return sdpMids_;
    }
    /**
     * <code>repeated string sdpMids = 4;</code>
     */
    public int getSdpMidsCount() {
      return sdpMids_.size();
    }
    /**
     * <code>repeated string sdpMids = 4;</code>
     */
    public java.lang.String getSdpMids(int index) {
      return sdpMids_.get(index);
    }
    /**
     * <code>repeated string sdpMids = 4;</code>
     */
    public com.google.protobuf.ByteString
        getSdpMidsBytes(int index) {
      return sdpMids_.getByteString(index);
    }

    // required string uuid = 5;
    public static final int UUID_FIELD_NUMBER = 5;
    private java.lang.Object uuid_;
    /**
     * <code>required string uuid = 5;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasUuid() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>required string uuid = 5;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public java.lang.String getUuid() {
      java.lang.Object ref = uuid_;
      if (ref instanceof java.lang.String) {
        return (java.lang.String) ref;
      } else {
        com.google.protobuf.ByteString bs = 
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          uuid_ = s;
        }
        return s;
      }
    }
    /**
     * <code>required string uuid = 5;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public com.google.protobuf.ByteString
        getUuidBytes() {
      java.lang.Object ref = uuid_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        uuid_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    private void initFields() {
      type_ = org.session.libsignal.protos.SignalServiceProtos.CallMessage.Type.PRE_OFFER;
      sdps_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      sdpMLineIndexes_ = java.util.Collections.emptyList();
      sdpMids_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      uuid_ = "";
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      if (!hasType()) {
        memoizedIsInitialized = 0;
        return false;
      }
      if (!hasUuid()) {
        memoizedIsInitialized = 0;
        return false;
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeEnum(1, type_.getNumber());
      }
      for (int i = 0; i < sdps_.size(); i++) {
        output.writeBytes(2, sdps_.getByteString(i));
      }
      for (int i = 0; i < sdpMLineIndexes_.size(); i++) {
        output.writeUInt32(3, sdpMLineIndexes_.get(i));
      }
      for (int i = 0; i < sdpMids_.size(); i++) {
        output.writeBytes(4, sdpMids_.getByteString(i));
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeBytes(5, getUuidBytes());
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeEnumSize(1, type_.getNumber());
      }
      {
        int dataSize = 0;
        for (int i = 0; i < sdps_.size(); i++) {
          dataSize += com.google.protobuf.CodedOutputStream
            .computeBytesSizeNoTag(sdps_.getByteString(i));
        }
        size += dataSize;
        size += 1 * getSdpsList().size();
      }
      {
        int dataSize = 0;
        for (int i = 0; i < sdpMLineIndexes_.size(); i++) {
          dataSize += com.google.protobuf.CodedOutputStream
            .computeUInt32SizeNoTag(sdpMLineIndexes_.get(i));
        }
        size += dataSize;
        size += 1 * getSdpMLineIndexesList().size();
      }
      {
        int dataSize = 0;
        for (int i = 0; i < sdpMids_.size(); i++) {
          dataSize += com.google.protobuf.CodedOutputStream
            .computeBytesSizeNoTag(sdpMids_.getByteString(i));
        }
        size += dataSize;
        size += 1 * getSdpMidsList().size();
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(5, getUuidBytes());
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.CallMessage parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.CallMessage parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.CallMessage parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.CallMessage parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.CallMessage parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.CallMessage parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.CallMessage parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.CallMessage parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.CallMessage parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.CallMessage parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.CallMessage prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.CallMessage}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.CallMessageOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_CallMessage_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_CallMessage_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.CallMessage.class, org.session.libsignal.protos.SignalServiceProtos.CallMessage.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.CallMessage.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        type_ = org.session.libsignal.protos.SignalServiceProtos.CallMessage.Type.PRE_OFFER;
        bitField0_ = (bitField0_ & ~0x00000001);
        sdps_ = com.google.protobuf.LazyStringArrayList.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000002);
        sdpMLineIndexes_ = java.util.Collections.emptyList();
        bitField0_ = (bitField0_ & ~0x00000004);
        sdpMids_ = com.google.protobuf.LazyStringArrayList.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000008);
        uuid_ = "";
        bitField0_ = (bitField0_ & ~0x00000010);
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_CallMessage_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.CallMessage getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.CallMessage.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.CallMessage build() {
        org.session.libsignal.protos.SignalServiceProtos.CallMessage result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.CallMessage buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.CallMessage result = new org.session.libsignal.protos.SignalServiceProtos.CallMessage(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.type_ = type_;
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          sdps_ = new com.google.protobuf.UnmodifiableLazyStringList(
              sdps_);
          bitField0_ = (bitField0_ & ~0x00000002);
        }
        result.sdps_ = sdps_;
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          sdpMLineIndexes_ = java.util.Collections.unmodifiableList(sdpMLineIndexes_);
          bitField0_ = (bitField0_ & ~0x00000004);
        }
        result.sdpMLineIndexes_ = sdpMLineIndexes_;
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          sdpMids_ = new com.google.protobuf.UnmodifiableLazyStringList(
              sdpMids_);
          bitField0_ = (bitField0_ & ~0x00000008);
        }
        result.sdpMids_ = sdpMids_;
        if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
          to_bitField0_ |= 0x00000002;
        }
        result.uuid_ = uuid_;
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.CallMessage) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.CallMessage)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.CallMessage other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.CallMessage.getDefaultInstance()) return this;
        if (other.hasType()) {
          setType(other.getType());
        }
        if (!other.sdps_.isEmpty()) {
          if (sdps_.isEmpty()) {
            sdps_ = other.sdps_;
            bitField0_ = (bitField0_ & ~0x00000002);
          } else {
            ensureSdpsIsMutable();
            sdps_.addAll(other.sdps_);
          }
          onChanged();
        }
        if (!other.sdpMLineIndexes_.isEmpty()) {
          if (sdpMLineIndexes_.isEmpty()) {
            sdpMLineIndexes_ = other.sdpMLineIndexes_;
            bitField0_ = (bitField0_ & ~0x00000004);
          } else {
            ensureSdpMLineIndexesIsMutable();
            sdpMLineIndexes_.addAll(other.sdpMLineIndexes_);
          }
          onChanged();
        }
        if (!other.sdpMids_.isEmpty()) {
          if (sdpMids_.isEmpty()) {
            sdpMids_ = other.sdpMids_;
            bitField0_ = (bitField0_ & ~0x00000008);
          } else {
            ensureSdpMidsIsMutable();
            sdpMids_.addAll(other.sdpMids_);
          }
          onChanged();
        }
        if (other.hasUuid()) {
          bitField0_ |= 0x00000010;
          uuid_ = other.uuid_;
          onChanged();
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        if (!hasType()) {
          
          return false;
        }
        if (!hasUuid()) {
          
          return false;
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.CallMessage parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.CallMessage) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // required .signalservice.CallMessage.Type type = 1;
      private org.session.libsignal.protos.SignalServiceProtos.CallMessage.Type type_ = org.session.libsignal.protos.SignalServiceProtos.CallMessage.Type.PRE_OFFER;
      /**
       * <code>required .signalservice.CallMessage.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasType() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required .signalservice.CallMessage.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public org.session.libsignal.protos.SignalServiceProtos.CallMessage.Type getType() {
        return type_;
      }
      /**
       * <code>required .signalservice.CallMessage.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setType(org.session.libsignal.protos.SignalServiceProtos.CallMessage.Type value) {
        if (value == null) {
          throw new NullPointerException();
        }
        bitField0_ |= 0x00000001;
        type_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required .signalservice.CallMessage.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearType() {
        bitField0_ = (bitField0_ & ~0x00000001);
        type_ = org.session.libsignal.protos.SignalServiceProtos.CallMessage.Type.PRE_OFFER;
        onChanged();
        return this;
      }

      // repeated string sdps = 2;
      private com.google.protobuf.LazyStringList sdps_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      private void ensureSdpsIsMutable() {
        if (!((bitField0_ & 0x00000002) == 0x00000002)) {
          sdps_ = new com.google.protobuf.LazyStringArrayList(sdps_);
          bitField0_ |= 0x00000002;
         }
      }
      /**
       * <code>repeated string sdps = 2;</code>
       */
      public java.util.List<java.lang.String>
          getSdpsList() {
        return java.util.Collections.unmodifiableList(sdps_);
      }
      /**
       * <code>repeated string sdps = 2;</code>
       */
      public int getSdpsCount() {
        return sdps_.size();
      }
      /**
       * <code>repeated string sdps = 2;</code>
       */
      public java.lang.String getSdps(int index) {
        return sdps_.get(index);
      }
      /**
       * <code>repeated string sdps = 2;</code>
       */
      public com.google.protobuf.ByteString
          getSdpsBytes(int index) {
        return sdps_.getByteString(index);
      }
      /**
       * <code>repeated string sdps = 2;</code>
       */
      public Builder setSdps(
          int index, java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureSdpsIsMutable();
        sdps_.set(index, value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string sdps = 2;</code>
       */
      public Builder addSdps(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureSdpsIsMutable();
        sdps_.add(value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string sdps = 2;</code>
       */
      public Builder addAllSdps(
          java.lang.Iterable<java.lang.String> values) {
        ensureSdpsIsMutable();
        super.addAll(values, sdps_);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string sdps = 2;</code>
       */
      public Builder clearSdps() {
        sdps_ = com.google.protobuf.LazyStringArrayList.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000002);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string sdps = 2;</code>
       */
      public Builder addSdpsBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureSdpsIsMutable();
        sdps_.add(value);
        onChanged();
        return this;
      }

      // repeated uint32 sdpMLineIndexes = 3;
      private java.util.List<java.lang.Integer> sdpMLineIndexes_ = java.util.Collections.emptyList();
      private void ensureSdpMLineIndexesIsMutable() {
        if (!((bitField0_ & 0x00000004) == 0x00000004)) {
          sdpMLineIndexes_ = new java.util.ArrayList<java.lang.Integer>(sdpMLineIndexes_);
          bitField0_ |= 0x00000004;
         }
      }
      /**
       * <code>repeated uint32 sdpMLineIndexes = 3;</code>
       */
      public java.util.List<java.lang.Integer>
          getSdpMLineIndexesList() {
        return java.util.Collections.unmodifiableList(sdpMLineIndexes_);
      }
      /**
       * <code>repeated uint32 sdpMLineIndexes = 3;</code>
       */
      public int getSdpMLineIndexesCount() {
        return sdpMLineIndexes_.size();
      }
      /**
       * <code>repeated uint32 sdpMLineIndexes = 3;</code>
       */
      public int getSdpMLineIndexes(int index) {
        return sdpMLineIndexes_.get(index);
      }
      /**
       * <code>repeated uint32 sdpMLineIndexes = 3;</code>
       */
      public Builder setSdpMLineIndexes(
          int index, int value) {
        ensureSdpMLineIndexesIsMutable();
        sdpMLineIndexes_.set(index, value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated uint32 sdpMLineIndexes = 3;</code>
       */
      public Builder addSdpMLineIndexes(int value) {
        ensureSdpMLineIndexesIsMutable();
        sdpMLineIndexes_.add(value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated uint32 sdpMLineIndexes = 3;</code>
       */
      public Builder addAllSdpMLineIndexes(
          java.lang.Iterable<? extends java.lang.Integer> values) {
        ensureSdpMLineIndexesIsMutable();
        super.addAll(values, sdpMLineIndexes_);
        onChanged();
        return this;
      }
      /**
       * <code>repeated uint32 sdpMLineIndexes = 3;</code>
       */
      public Builder clearSdpMLineIndexes() {
        sdpMLineIndexes_ = java.util.Collections.emptyList();
        bitField0_ = (bitField0_ & ~0x00000004);
        onChanged();
        return this;
      }

      // repeated string sdpMids = 4;
      private com.google.protobuf.LazyStringList sdpMids_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      private void ensureSdpMidsIsMutable() {
        if (!((bitField0_ & 0x00000008) == 0x00000008)) {
          sdpMids_ = new com.google.protobuf.LazyStringArrayList(sdpMids_);
          bitField0_ |= 0x00000008;
         }
      }
      /**
       * <code>repeated string sdpMids = 4;</code>
       */
      public java.util.List<java.lang.String>
          getSdpMidsList() {
        return java.util.Collections.unmodifiableList(sdpMids_);
      }
      /**
       * <code>repeated string sdpMids = 4;</code>
       */
      public int getSdpMidsCount() {
        return sdpMids_.size();
      }
      /**
       * <code>repeated string sdpMids = 4;</code>
       */
      public java.lang.String getSdpMids(int index) {
        return sdpMids_.get(index);
      }
      /**
       * <code>repeated string sdpMids = 4;</code>
       */
      public com.google.protobuf.ByteString
          getSdpMidsBytes(int index) {
        return sdpMids_.getByteString(index);
      }
      /**
       * <code>repeated string sdpMids = 4;</code>
       */
      public Builder setSdpMids(
          int index, java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureSdpMidsIsMutable();
        sdpMids_.set(index, value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string sdpMids = 4;</code>
       */
      public Builder addSdpMids(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureSdpMidsIsMutable();
        sdpMids_.add(value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string sdpMids = 4;</code>
       */
      public Builder addAllSdpMids(
          java.lang.Iterable<java.lang.String> values) {
        ensureSdpMidsIsMutable();
        super.addAll(values, sdpMids_);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string sdpMids = 4;</code>
       */
      public Builder clearSdpMids() {
        sdpMids_ = com.google.protobuf.LazyStringArrayList.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000008);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string sdpMids = 4;</code>
       */
      public Builder addSdpMidsBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureSdpMidsIsMutable();
        sdpMids_.add(value);
        onChanged();
        return this;
      }

      // required string uuid = 5;
      private java.lang.Object uuid_ = "";
      /**
       * <code>required string uuid = 5;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasUuid() {
        return ((bitField0_ & 0x00000010) == 0x00000010);
      }
      /**
       * <code>required string uuid = 5;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public java.lang.String getUuid() {
        java.lang.Object ref = uuid_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          uuid_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>required string uuid = 5;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public com.google.protobuf.ByteString
          getUuidBytes() {
        java.lang.Object ref = uuid_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          uuid_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>required string uuid = 5;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setUuid(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000010;
        uuid_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required string uuid = 5;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearUuid() {
        bitField0_ = (bitField0_ & ~0x00000010);
        uuid_ = getDefaultInstance().getUuid();
        onChanged();
        return this;
      }
      /**
       * <code>required string uuid = 5;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setUuidBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000010;
        uuid_ = value;
        onChanged();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.CallMessage)
    }

    static {
      defaultInstance = new CallMessage(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.CallMessage)
  }

  public interface ConfigurationMessageOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;
    /**
     * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
     */
    java.util.List<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup> 
        getClosedGroupsList();
    /**
     * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup getClosedGroups(int index);
    /**
     * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
     */
    int getClosedGroupsCount();
    /**
     * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
     */
    java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroupOrBuilder> 
        getClosedGroupsOrBuilderList();
    /**
     * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroupOrBuilder getClosedGroupsOrBuilder(
        int index);

    // repeated string openGroups = 2;
    /**
     * <code>repeated string openGroups = 2;</code>
     */
    java.util.List<java.lang.String>
    getOpenGroupsList();
    /**
     * <code>repeated string openGroups = 2;</code>
     */
    int getOpenGroupsCount();
    /**
     * <code>repeated string openGroups = 2;</code>
     */
    java.lang.String getOpenGroups(int index);
    /**
     * <code>repeated string openGroups = 2;</code>
     */
    com.google.protobuf.ByteString
        getOpenGroupsBytes(int index);

    // optional string displayName = 3;
    /**
     * <code>optional string displayName = 3;</code>
     */
    boolean hasDisplayName();
    /**
     * <code>optional string displayName = 3;</code>
     */
    java.lang.String getDisplayName();
    /**
     * <code>optional string displayName = 3;</code>
     */
    com.google.protobuf.ByteString
        getDisplayNameBytes();

    // optional string profilePicture = 4;
    /**
     * <code>optional string profilePicture = 4;</code>
     */
    boolean hasProfilePicture();
    /**
     * <code>optional string profilePicture = 4;</code>
     */
    java.lang.String getProfilePicture();
    /**
     * <code>optional string profilePicture = 4;</code>
     */
    com.google.protobuf.ByteString
        getProfilePictureBytes();

    // optional bytes profileKey = 5;
    /**
     * <code>optional bytes profileKey = 5;</code>
     */
    boolean hasProfileKey();
    /**
     * <code>optional bytes profileKey = 5;</code>
     */
    com.google.protobuf.ByteString getProfileKey();

    // repeated .signalservice.ConfigurationMessage.Contact contacts = 6;
    /**
     * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
     */
    java.util.List<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact> 
        getContactsList();
    /**
     * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact getContacts(int index);
    /**
     * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
     */
    int getContactsCount();
    /**
     * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
     */
    java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ContactOrBuilder> 
        getContactsOrBuilderList();
    /**
     * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ContactOrBuilder getContactsOrBuilder(
        int index);
  }
  /**
   * Protobuf type {@code signalservice.ConfigurationMessage}
   */
  public static final class ConfigurationMessage extends
      com.google.protobuf.GeneratedMessage
      implements ConfigurationMessageOrBuilder {
    // Use ConfigurationMessage.newBuilder() to construct.
    private ConfigurationMessage(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private ConfigurationMessage(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final ConfigurationMessage defaultInstance;
    public static ConfigurationMessage getDefaultInstance() {
      return defaultInstance;
    }

    public ConfigurationMessage getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private ConfigurationMessage(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 10: {
              if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) {
                closedGroups_ = new java.util.ArrayList<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup>();
                mutable_bitField0_ |= 0x00000001;
              }
              closedGroups_.add(input.readMessage(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.PARSER, extensionRegistry));
              break;
            }
            case 18: {
              if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
                openGroups_ = new com.google.protobuf.LazyStringArrayList();
                mutable_bitField0_ |= 0x00000002;
              }
              openGroups_.add(input.readBytes());
              break;
            }
            case 26: {
              bitField0_ |= 0x00000001;
              displayName_ = input.readBytes();
              break;
            }
            case 34: {
              bitField0_ |= 0x00000002;
              profilePicture_ = input.readBytes();
              break;
            }
            case 42: {
              bitField0_ |= 0x00000004;
              profileKey_ = input.readBytes();
              break;
            }
            case 50: {
              if (!((mutable_bitField0_ & 0x00000020) == 0x00000020)) {
                contacts_ = new java.util.ArrayList<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact>();
                mutable_bitField0_ |= 0x00000020;
              }
              contacts_.add(input.readMessage(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.PARSER, extensionRegistry));
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) {
          closedGroups_ = java.util.Collections.unmodifiableList(closedGroups_);
        }
        if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
          openGroups_ = new com.google.protobuf.UnmodifiableLazyStringList(openGroups_);
        }
        if (((mutable_bitField0_ & 0x00000020) == 0x00000020)) {
          contacts_ = java.util.Collections.unmodifiableList(contacts_);
        }
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.class, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Builder.class);
    }

    public static com.google.protobuf.Parser<ConfigurationMessage> PARSER =
        new com.google.protobuf.AbstractParser<ConfigurationMessage>() {
      public ConfigurationMessage parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new ConfigurationMessage(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<ConfigurationMessage> getParserForType() {
      return PARSER;
    }

    public interface ClosedGroupOrBuilder
        extends com.google.protobuf.MessageOrBuilder {

      // optional bytes publicKey = 1;
      /**
       * <code>optional bytes publicKey = 1;</code>
       */
      boolean hasPublicKey();
      /**
       * <code>optional bytes publicKey = 1;</code>
       */
      com.google.protobuf.ByteString getPublicKey();

      // optional string name = 2;
      /**
       * <code>optional string name = 2;</code>
       */
      boolean hasName();
      /**
       * <code>optional string name = 2;</code>
       */
      java.lang.String getName();
      /**
       * <code>optional string name = 2;</code>
       */
      com.google.protobuf.ByteString
          getNameBytes();

      // optional .signalservice.KeyPair encryptionKeyPair = 3;
      /**
       * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
       */
      boolean hasEncryptionKeyPair();
      /**
       * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
       */
      org.session.libsignal.protos.SignalServiceProtos.KeyPair getEncryptionKeyPair();
      /**
       * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
       */
      org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder getEncryptionKeyPairOrBuilder();

      // repeated bytes members = 4;
      /**
       * <code>repeated bytes members = 4;</code>
       */
      java.util.List<com.google.protobuf.ByteString> getMembersList();
      /**
       * <code>repeated bytes members = 4;</code>
       */
      int getMembersCount();
      /**
       * <code>repeated bytes members = 4;</code>
       */
      com.google.protobuf.ByteString getMembers(int index);

      // repeated bytes admins = 5;
      /**
       * <code>repeated bytes admins = 5;</code>
       */
      java.util.List<com.google.protobuf.ByteString> getAdminsList();
      /**
       * <code>repeated bytes admins = 5;</code>
       */
      int getAdminsCount();
      /**
       * <code>repeated bytes admins = 5;</code>
       */
      com.google.protobuf.ByteString getAdmins(int index);

      // optional uint32 expirationTimer = 6;
      /**
       * <code>optional uint32 expirationTimer = 6;</code>
       */
      boolean hasExpirationTimer();
      /**
       * <code>optional uint32 expirationTimer = 6;</code>
       */
      int getExpirationTimer();
    }
    /**
     * Protobuf type {@code signalservice.ConfigurationMessage.ClosedGroup}
     */
    public static final class ClosedGroup extends
        com.google.protobuf.GeneratedMessage
        implements ClosedGroupOrBuilder {
      // Use ClosedGroup.newBuilder() to construct.
      private ClosedGroup(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
        super(builder);
        this.unknownFields = builder.getUnknownFields();
      }
      private ClosedGroup(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

      private static final ClosedGroup defaultInstance;
      public static ClosedGroup getDefaultInstance() {
        return defaultInstance;
      }

      public ClosedGroup getDefaultInstanceForType() {
        return defaultInstance;
      }

      private final com.google.protobuf.UnknownFieldSet unknownFields;
      @java.lang.Override
      public final com.google.protobuf.UnknownFieldSet
          getUnknownFields() {
        return this.unknownFields;
      }
      private ClosedGroup(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        initFields();
        int mutable_bitField0_ = 0;
        com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder();
        try {
          boolean done = false;
          while (!done) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                done = true;
                break;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  done = true;
                }
                break;
              }
              case 10: {
                bitField0_ |= 0x00000001;
                publicKey_ = input.readBytes();
                break;
              }
              case 18: {
                bitField0_ |= 0x00000002;
                name_ = input.readBytes();
                break;
              }
              case 26: {
                org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder subBuilder = null;
                if (((bitField0_ & 0x00000004) == 0x00000004)) {
                  subBuilder = encryptionKeyPair_.toBuilder();
                }
                encryptionKeyPair_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.KeyPair.PARSER, extensionRegistry);
                if (subBuilder != null) {
                  subBuilder.mergeFrom(encryptionKeyPair_);
                  encryptionKeyPair_ = subBuilder.buildPartial();
                }
                bitField0_ |= 0x00000004;
                break;
              }
              case 34: {
                if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
                  members_ = new java.util.ArrayList<com.google.protobuf.ByteString>();
                  mutable_bitField0_ |= 0x00000008;
                }
                members_.add(input.readBytes());
                break;
              }
              case 42: {
                if (!((mutable_bitField0_ & 0x00000010) == 0x00000010)) {
                  admins_ = new java.util.ArrayList<com.google.protobuf.ByteString>();
                  mutable_bitField0_ |= 0x00000010;
                }
                admins_.add(input.readBytes());
                break;
              }
              case 48: {
                bitField0_ |= 0x00000008;
                expirationTimer_ = input.readUInt32();
                break;
              }
            }
          }
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          throw e.setUnfinishedMessage(this);
        } catch (java.io.IOException e) {
          throw new com.google.protobuf.InvalidProtocolBufferException(
              e.getMessage()).setUnfinishedMessage(this);
        } finally {
          if (((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
            members_ = java.util.Collections.unmodifiableList(members_);
          }
          if (((mutable_bitField0_ & 0x00000010) == 0x00000010)) {
            admins_ = java.util.Collections.unmodifiableList(admins_);
          }
          this.unknownFields = unknownFields.build();
          makeExtensionsImmutable();
        }
      }
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_ClosedGroup_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_ClosedGroup_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.class, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.Builder.class);
      }

      public static com.google.protobuf.Parser<ClosedGroup> PARSER =
          new com.google.protobuf.AbstractParser<ClosedGroup>() {
        public ClosedGroup parsePartialFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return new ClosedGroup(input, extensionRegistry);
        }
      };

      @java.lang.Override
      public com.google.protobuf.Parser<ClosedGroup> getParserForType() {
        return PARSER;
      }

      private int bitField0_;
      // optional bytes publicKey = 1;
      public static final int PUBLICKEY_FIELD_NUMBER = 1;
      private com.google.protobuf.ByteString publicKey_;
      /**
       * <code>optional bytes publicKey = 1;</code>
       */
      public boolean hasPublicKey() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>optional bytes publicKey = 1;</code>
       */
      public com.google.protobuf.ByteString getPublicKey() {
        return publicKey_;
      }

      // optional string name = 2;
      public static final int NAME_FIELD_NUMBER = 2;
      private java.lang.Object name_;
      /**
       * <code>optional string name = 2;</code>
       */
      public boolean hasName() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>optional string name = 2;</code>
       */
      public java.lang.String getName() {
        java.lang.Object ref = name_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            name_ = s;
          }
          return s;
        }
      }
      /**
       * <code>optional string name = 2;</code>
       */
      public com.google.protobuf.ByteString
          getNameBytes() {
        java.lang.Object ref = name_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          name_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // optional .signalservice.KeyPair encryptionKeyPair = 3;
      public static final int ENCRYPTIONKEYPAIR_FIELD_NUMBER = 3;
      private org.session.libsignal.protos.SignalServiceProtos.KeyPair encryptionKeyPair_;
      /**
       * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
       */
      public boolean hasEncryptionKeyPair() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.KeyPair getEncryptionKeyPair() {
        return encryptionKeyPair_;
      }
      /**
       * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder getEncryptionKeyPairOrBuilder() {
        return encryptionKeyPair_;
      }

      // repeated bytes members = 4;
      public static final int MEMBERS_FIELD_NUMBER = 4;
      private java.util.List<com.google.protobuf.ByteString> members_;
      /**
       * <code>repeated bytes members = 4;</code>
       */
      public java.util.List<com.google.protobuf.ByteString>
          getMembersList() {
        return members_;
      }
      /**
       * <code>repeated bytes members = 4;</code>
       */
      public int getMembersCount() {
        return members_.size();
      }
      /**
       * <code>repeated bytes members = 4;</code>
       */
      public com.google.protobuf.ByteString getMembers(int index) {
        return members_.get(index);
      }

      // repeated bytes admins = 5;
      public static final int ADMINS_FIELD_NUMBER = 5;
      private java.util.List<com.google.protobuf.ByteString> admins_;
      /**
       * <code>repeated bytes admins = 5;</code>
       */
      public java.util.List<com.google.protobuf.ByteString>
          getAdminsList() {
        return admins_;
      }
      /**
       * <code>repeated bytes admins = 5;</code>
       */
      public int getAdminsCount() {
        return admins_.size();
      }
      /**
       * <code>repeated bytes admins = 5;</code>
       */
      public com.google.protobuf.ByteString getAdmins(int index) {
        return admins_.get(index);
      }

      // optional uint32 expirationTimer = 6;
      public static final int EXPIRATIONTIMER_FIELD_NUMBER = 6;
      private int expirationTimer_;
      /**
       * <code>optional uint32 expirationTimer = 6;</code>
       */
      public boolean hasExpirationTimer() {
        return ((bitField0_ & 0x00000008) == 0x00000008);
      }
      /**
       * <code>optional uint32 expirationTimer = 6;</code>
       */
      public int getExpirationTimer() {
        return expirationTimer_;
      }

      private void initFields() {
        publicKey_ = com.google.protobuf.ByteString.EMPTY;
        name_ = "";
        encryptionKeyPair_ = org.session.libsignal.protos.SignalServiceProtos.KeyPair.getDefaultInstance();
        members_ = java.util.Collections.emptyList();
        admins_ = java.util.Collections.emptyList();
        expirationTimer_ = 0;
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;

        if (hasEncryptionKeyPair()) {
          if (!getEncryptionKeyPair().isInitialized()) {
            memoizedIsInitialized = 0;
            return false;
          }
        }
        memoizedIsInitialized = 1;
        return true;
      }

      public void writeTo(com.google.protobuf.CodedOutputStream output)
                          throws java.io.IOException {
        getSerializedSize();
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          output.writeBytes(1, publicKey_);
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(2, getNameBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          output.writeMessage(3, encryptionKeyPair_);
        }
        for (int i = 0; i < members_.size(); i++) {
          output.writeBytes(4, members_.get(i));
        }
        for (int i = 0; i < admins_.size(); i++) {
          output.writeBytes(5, admins_.get(i));
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          output.writeUInt32(6, expirationTimer_);
        }
        getUnknownFields().writeTo(output);
      }

      private int memoizedSerializedSize = -1;
      public int getSerializedSize() {
        int size = memoizedSerializedSize;
        if (size != -1) return size;

        size = 0;
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(1, publicKey_);
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(2, getNameBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(3, encryptionKeyPair_);
        }
        {
          int dataSize = 0;
          for (int i = 0; i < members_.size(); i++) {
            dataSize += com.google.protobuf.CodedOutputStream
              .computeBytesSizeNoTag(members_.get(i));
          }
          size += dataSize;
          size += 1 * getMembersList().size();
        }
        {
          int dataSize = 0;
          for (int i = 0; i < admins_.size(); i++) {
            dataSize += com.google.protobuf.CodedOutputStream
              .computeBytesSizeNoTag(admins_.get(i));
          }
          size += dataSize;
          size += 1 * getAdminsList().size();
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          size += com.google.protobuf.CodedOutputStream
            .computeUInt32Size(6, expirationTimer_);
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }

      private static final long serialVersionUID = 0L;
      @java.lang.Override
      protected java.lang.Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }

      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }

      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }

      @java.lang.Override
      protected Builder newBuilderForType(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      /**
       * Protobuf type {@code signalservice.ConfigurationMessage.ClosedGroup}
       */
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroupOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_ClosedGroup_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_ClosedGroup_fieldAccessorTable
              .ensureFieldAccessorsInitialized(
                  org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.class, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.Builder.class);
        }

        // Construct using org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }

        private Builder(
            com.google.protobuf.GeneratedMessage.BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
            getEncryptionKeyPairFieldBuilder();
          }
        }
        private static Builder create() {
          return new Builder();
        }

        public Builder clear() {
          super.clear();
          publicKey_ = com.google.protobuf.ByteString.EMPTY;
          bitField0_ = (bitField0_ & ~0x00000001);
          name_ = "";
          bitField0_ = (bitField0_ & ~0x00000002);
          if (encryptionKeyPairBuilder_ == null) {
            encryptionKeyPair_ = org.session.libsignal.protos.SignalServiceProtos.KeyPair.getDefaultInstance();
          } else {
            encryptionKeyPairBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000004);
          members_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000008);
          admins_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000010);
          expirationTimer_ = 0;
          bitField0_ = (bitField0_ & ~0x00000020);
          return this;
        }

        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }

        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_ClosedGroup_descriptor;
        }

        public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup getDefaultInstanceForType() {
          return org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.getDefaultInstance();
        }

        public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup build() {
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }

        public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup buildPartial() {
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup result = new org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.publicKey_ = publicKey_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.name_ = name_;
          if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
            to_bitField0_ |= 0x00000004;
          }
          if (encryptionKeyPairBuilder_ == null) {
            result.encryptionKeyPair_ = encryptionKeyPair_;
          } else {
            result.encryptionKeyPair_ = encryptionKeyPairBuilder_.build();
          }
          if (((bitField0_ & 0x00000008) == 0x00000008)) {
            members_ = java.util.Collections.unmodifiableList(members_);
            bitField0_ = (bitField0_ & ~0x00000008);
          }
          result.members_ = members_;
          if (((bitField0_ & 0x00000010) == 0x00000010)) {
            admins_ = java.util.Collections.unmodifiableList(admins_);
            bitField0_ = (bitField0_ & ~0x00000010);
          }
          result.admins_ = admins_;
          if (((from_bitField0_ & 0x00000020) == 0x00000020)) {
            to_bitField0_ |= 0x00000008;
          }
          result.expirationTimer_ = expirationTimer_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }

        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup) {
            return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }

        public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup other) {
          if (other == org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.getDefaultInstance()) return this;
          if (other.hasPublicKey()) {
            setPublicKey(other.getPublicKey());
          }
          if (other.hasName()) {
            bitField0_ |= 0x00000002;
            name_ = other.name_;
            onChanged();
          }
          if (other.hasEncryptionKeyPair()) {
            mergeEncryptionKeyPair(other.getEncryptionKeyPair());
          }
          if (!other.members_.isEmpty()) {
            if (members_.isEmpty()) {
              members_ = other.members_;
              bitField0_ = (bitField0_ & ~0x00000008);
            } else {
              ensureMembersIsMutable();
              members_.addAll(other.members_);
            }
            onChanged();
          }
          if (!other.admins_.isEmpty()) {
            if (admins_.isEmpty()) {
              admins_ = other.admins_;
              bitField0_ = (bitField0_ & ~0x00000010);
            } else {
              ensureAdminsIsMutable();
              admins_.addAll(other.admins_);
            }
            onChanged();
          }
          if (other.hasExpirationTimer()) {
            setExpirationTimer(other.getExpirationTimer());
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }

        public final boolean isInitialized() {
          if (hasEncryptionKeyPair()) {
            if (!getEncryptionKeyPair().isInitialized()) {
              
              return false;
            }
          }
          return true;
        }

        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup parsedMessage = null;
          try {
            parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
            parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup) e.getUnfinishedMessage();
            throw e;
          } finally {
            if (parsedMessage != null) {
              mergeFrom(parsedMessage);
            }
          }
          return this;
        }
        private int bitField0_;

        // optional bytes publicKey = 1;
        private com.google.protobuf.ByteString publicKey_ = com.google.protobuf.ByteString.EMPTY;
        /**
         * <code>optional bytes publicKey = 1;</code>
         */
        public boolean hasPublicKey() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>optional bytes publicKey = 1;</code>
         */
        public com.google.protobuf.ByteString getPublicKey() {
          return publicKey_;
        }
        /**
         * <code>optional bytes publicKey = 1;</code>
         */
        public Builder setPublicKey(com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
          publicKey_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional bytes publicKey = 1;</code>
         */
        public Builder clearPublicKey() {
          bitField0_ = (bitField0_ & ~0x00000001);
          publicKey_ = getDefaultInstance().getPublicKey();
          onChanged();
          return this;
        }

        // optional string name = 2;
        private java.lang.Object name_ = "";
        /**
         * <code>optional string name = 2;</code>
         */
        public boolean hasName() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>optional string name = 2;</code>
         */
        public java.lang.String getName() {
          java.lang.Object ref = name_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            name_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>optional string name = 2;</code>
         */
        public com.google.protobuf.ByteString
            getNameBytes() {
          java.lang.Object ref = name_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            name_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>optional string name = 2;</code>
         */
        public Builder setName(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional string name = 2;</code>
         */
        public Builder clearName() {
          bitField0_ = (bitField0_ & ~0x00000002);
          name_ = getDefaultInstance().getName();
          onChanged();
          return this;
        }
        /**
         * <code>optional string name = 2;</code>
         */
        public Builder setNameBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
          return this;
        }

        // optional .signalservice.KeyPair encryptionKeyPair = 3;
        private org.session.libsignal.protos.SignalServiceProtos.KeyPair encryptionKeyPair_ = org.session.libsignal.protos.SignalServiceProtos.KeyPair.getDefaultInstance();
        private com.google.protobuf.SingleFieldBuilder<
            org.session.libsignal.protos.SignalServiceProtos.KeyPair, org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder, org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder> encryptionKeyPairBuilder_;
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
         */
        public boolean hasEncryptionKeyPair() {
          return ((bitField0_ & 0x00000004) == 0x00000004);
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.KeyPair getEncryptionKeyPair() {
          if (encryptionKeyPairBuilder_ == null) {
            return encryptionKeyPair_;
          } else {
            return encryptionKeyPairBuilder_.getMessage();
          }
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
         */
        public Builder setEncryptionKeyPair(org.session.libsignal.protos.SignalServiceProtos.KeyPair value) {
          if (encryptionKeyPairBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            encryptionKeyPair_ = value;
            onChanged();
          } else {
            encryptionKeyPairBuilder_.setMessage(value);
          }
          bitField0_ |= 0x00000004;
          return this;
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
         */
        public Builder setEncryptionKeyPair(
            org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder builderForValue) {
          if (encryptionKeyPairBuilder_ == null) {
            encryptionKeyPair_ = builderForValue.build();
            onChanged();
          } else {
            encryptionKeyPairBuilder_.setMessage(builderForValue.build());
          }
          bitField0_ |= 0x00000004;
          return this;
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
         */
        public Builder mergeEncryptionKeyPair(org.session.libsignal.protos.SignalServiceProtos.KeyPair value) {
          if (encryptionKeyPairBuilder_ == null) {
            if (((bitField0_ & 0x00000004) == 0x00000004) &&
                encryptionKeyPair_ != org.session.libsignal.protos.SignalServiceProtos.KeyPair.getDefaultInstance()) {
              encryptionKeyPair_ =
                org.session.libsignal.protos.SignalServiceProtos.KeyPair.newBuilder(encryptionKeyPair_).mergeFrom(value).buildPartial();
            } else {
              encryptionKeyPair_ = value;
            }
            onChanged();
          } else {
            encryptionKeyPairBuilder_.mergeFrom(value);
          }
          bitField0_ |= 0x00000004;
          return this;
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
         */
        public Builder clearEncryptionKeyPair() {
          if (encryptionKeyPairBuilder_ == null) {
            encryptionKeyPair_ = org.session.libsignal.protos.SignalServiceProtos.KeyPair.getDefaultInstance();
            onChanged();
          } else {
            encryptionKeyPairBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000004);
          return this;
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder getEncryptionKeyPairBuilder() {
          bitField0_ |= 0x00000004;
          onChanged();
          return getEncryptionKeyPairFieldBuilder().getBuilder();
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
         */
        public org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder getEncryptionKeyPairOrBuilder() {
          if (encryptionKeyPairBuilder_ != null) {
            return encryptionKeyPairBuilder_.getMessageOrBuilder();
          } else {
            return encryptionKeyPair_;
          }
        }
        /**
         * <code>optional .signalservice.KeyPair encryptionKeyPair = 3;</code>
         */
        private com.google.protobuf.SingleFieldBuilder<
            org.session.libsignal.protos.SignalServiceProtos.KeyPair, org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder, org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder> 
            getEncryptionKeyPairFieldBuilder() {
          if (encryptionKeyPairBuilder_ == null) {
            encryptionKeyPairBuilder_ = new com.google.protobuf.SingleFieldBuilder<
                org.session.libsignal.protos.SignalServiceProtos.KeyPair, org.session.libsignal.protos.SignalServiceProtos.KeyPair.Builder, org.session.libsignal.protos.SignalServiceProtos.KeyPairOrBuilder>(
                    encryptionKeyPair_,
                    getParentForChildren(),
                    isClean());
            encryptionKeyPair_ = null;
          }
          return encryptionKeyPairBuilder_;
        }

        // repeated bytes members = 4;
        private java.util.List<com.google.protobuf.ByteString> members_ = java.util.Collections.emptyList();
        private void ensureMembersIsMutable() {
          if (!((bitField0_ & 0x00000008) == 0x00000008)) {
            members_ = new java.util.ArrayList<com.google.protobuf.ByteString>(members_);
            bitField0_ |= 0x00000008;
           }
        }
        /**
         * <code>repeated bytes members = 4;</code>
         */
        public java.util.List<com.google.protobuf.ByteString>
            getMembersList() {
          return java.util.Collections.unmodifiableList(members_);
        }
        /**
         * <code>repeated bytes members = 4;</code>
         */
        public int getMembersCount() {
          return members_.size();
        }
        /**
         * <code>repeated bytes members = 4;</code>
         */
        public com.google.protobuf.ByteString getMembers(int index) {
          return members_.get(index);
        }
        /**
         * <code>repeated bytes members = 4;</code>
         */
        public Builder setMembers(
            int index, com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  ensureMembersIsMutable();
          members_.set(index, value);
          onChanged();
          return this;
        }
        /**
         * <code>repeated bytes members = 4;</code>
         */
        public Builder addMembers(com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  ensureMembersIsMutable();
          members_.add(value);
          onChanged();
          return this;
        }
        /**
         * <code>repeated bytes members = 4;</code>
         */
        public Builder addAllMembers(
            java.lang.Iterable<? extends com.google.protobuf.ByteString> values) {
          ensureMembersIsMutable();
          super.addAll(values, members_);
          onChanged();
          return this;
        }
        /**
         * <code>repeated bytes members = 4;</code>
         */
        public Builder clearMembers() {
          members_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000008);
          onChanged();
          return this;
        }

        // repeated bytes admins = 5;
        private java.util.List<com.google.protobuf.ByteString> admins_ = java.util.Collections.emptyList();
        private void ensureAdminsIsMutable() {
          if (!((bitField0_ & 0x00000010) == 0x00000010)) {
            admins_ = new java.util.ArrayList<com.google.protobuf.ByteString>(admins_);
            bitField0_ |= 0x00000010;
           }
        }
        /**
         * <code>repeated bytes admins = 5;</code>
         */
        public java.util.List<com.google.protobuf.ByteString>
            getAdminsList() {
          return java.util.Collections.unmodifiableList(admins_);
        }
        /**
         * <code>repeated bytes admins = 5;</code>
         */
        public int getAdminsCount() {
          return admins_.size();
        }
        /**
         * <code>repeated bytes admins = 5;</code>
         */
        public com.google.protobuf.ByteString getAdmins(int index) {
          return admins_.get(index);
        }
        /**
         * <code>repeated bytes admins = 5;</code>
         */
        public Builder setAdmins(
            int index, com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  ensureAdminsIsMutable();
          admins_.set(index, value);
          onChanged();
          return this;
        }
        /**
         * <code>repeated bytes admins = 5;</code>
         */
        public Builder addAdmins(com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  ensureAdminsIsMutable();
          admins_.add(value);
          onChanged();
          return this;
        }
        /**
         * <code>repeated bytes admins = 5;</code>
         */
        public Builder addAllAdmins(
            java.lang.Iterable<? extends com.google.protobuf.ByteString> values) {
          ensureAdminsIsMutable();
          super.addAll(values, admins_);
          onChanged();
          return this;
        }
        /**
         * <code>repeated bytes admins = 5;</code>
         */
        public Builder clearAdmins() {
          admins_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000010);
          onChanged();
          return this;
        }

        // optional uint32 expirationTimer = 6;
        private int expirationTimer_ ;
        /**
         * <code>optional uint32 expirationTimer = 6;</code>
         */
        public boolean hasExpirationTimer() {
          return ((bitField0_ & 0x00000020) == 0x00000020);
        }
        /**
         * <code>optional uint32 expirationTimer = 6;</code>
         */
        public int getExpirationTimer() {
          return expirationTimer_;
        }
        /**
         * <code>optional uint32 expirationTimer = 6;</code>
         */
        public Builder setExpirationTimer(int value) {
          bitField0_ |= 0x00000020;
          expirationTimer_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional uint32 expirationTimer = 6;</code>
         */
        public Builder clearExpirationTimer() {
          bitField0_ = (bitField0_ & ~0x00000020);
          expirationTimer_ = 0;
          onChanged();
          return this;
        }

        // @@protoc_insertion_point(builder_scope:signalservice.ConfigurationMessage.ClosedGroup)
      }

      static {
        defaultInstance = new ClosedGroup(true);
        defaultInstance.initFields();
      }

      // @@protoc_insertion_point(class_scope:signalservice.ConfigurationMessage.ClosedGroup)
    }

    public interface ContactOrBuilder
        extends com.google.protobuf.MessageOrBuilder {

      // required bytes publicKey = 1;
      /**
       * <code>required bytes publicKey = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      boolean hasPublicKey();
      /**
       * <code>required bytes publicKey = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      com.google.protobuf.ByteString getPublicKey();

      // required string name = 2;
      /**
       * <code>required string name = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      boolean hasName();
      /**
       * <code>required string name = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      java.lang.String getName();
      /**
       * <code>required string name = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      com.google.protobuf.ByteString
          getNameBytes();

      // optional string profilePicture = 3;
      /**
       * <code>optional string profilePicture = 3;</code>
       */
      boolean hasProfilePicture();
      /**
       * <code>optional string profilePicture = 3;</code>
       */
      java.lang.String getProfilePicture();
      /**
       * <code>optional string profilePicture = 3;</code>
       */
      com.google.protobuf.ByteString
          getProfilePictureBytes();

      // optional bytes profileKey = 4;
      /**
       * <code>optional bytes profileKey = 4;</code>
       */
      boolean hasProfileKey();
      /**
       * <code>optional bytes profileKey = 4;</code>
       */
      com.google.protobuf.ByteString getProfileKey();

      // optional bool isApproved = 5;
      /**
       * <code>optional bool isApproved = 5;</code>
       */
      boolean hasIsApproved();
      /**
       * <code>optional bool isApproved = 5;</code>
       */
      boolean getIsApproved();

      // optional bool isBlocked = 6;
      /**
       * <code>optional bool isBlocked = 6;</code>
       */
      boolean hasIsBlocked();
      /**
       * <code>optional bool isBlocked = 6;</code>
       */
      boolean getIsBlocked();

      // optional bool didApproveMe = 7;
      /**
       * <code>optional bool didApproveMe = 7;</code>
       */
      boolean hasDidApproveMe();
      /**
       * <code>optional bool didApproveMe = 7;</code>
       */
      boolean getDidApproveMe();
    }
    /**
     * Protobuf type {@code signalservice.ConfigurationMessage.Contact}
     */
    public static final class Contact extends
        com.google.protobuf.GeneratedMessage
        implements ContactOrBuilder {
      // Use Contact.newBuilder() to construct.
      private Contact(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
        super(builder);
        this.unknownFields = builder.getUnknownFields();
      }
      private Contact(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

      private static final Contact defaultInstance;
      public static Contact getDefaultInstance() {
        return defaultInstance;
      }

      public Contact getDefaultInstanceForType() {
        return defaultInstance;
      }

      private final com.google.protobuf.UnknownFieldSet unknownFields;
      @java.lang.Override
      public final com.google.protobuf.UnknownFieldSet
          getUnknownFields() {
        return this.unknownFields;
      }
      private Contact(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        initFields();
        int mutable_bitField0_ = 0;
        com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder();
        try {
          boolean done = false;
          while (!done) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                done = true;
                break;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  done = true;
                }
                break;
              }
              case 10: {
                bitField0_ |= 0x00000001;
                publicKey_ = input.readBytes();
                break;
              }
              case 18: {
                bitField0_ |= 0x00000002;
                name_ = input.readBytes();
                break;
              }
              case 26: {
                bitField0_ |= 0x00000004;
                profilePicture_ = input.readBytes();
                break;
              }
              case 34: {
                bitField0_ |= 0x00000008;
                profileKey_ = input.readBytes();
                break;
              }
              case 40: {
                bitField0_ |= 0x00000010;
                isApproved_ = input.readBool();
                break;
              }
              case 48: {
                bitField0_ |= 0x00000020;
                isBlocked_ = input.readBool();
                break;
              }
              case 56: {
                bitField0_ |= 0x00000040;
                didApproveMe_ = input.readBool();
                break;
              }
            }
          }
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          throw e.setUnfinishedMessage(this);
        } catch (java.io.IOException e) {
          throw new com.google.protobuf.InvalidProtocolBufferException(
              e.getMessage()).setUnfinishedMessage(this);
        } finally {
          this.unknownFields = unknownFields.build();
          makeExtensionsImmutable();
        }
      }
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_Contact_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_Contact_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.class, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.Builder.class);
      }

      public static com.google.protobuf.Parser<Contact> PARSER =
          new com.google.protobuf.AbstractParser<Contact>() {
        public Contact parsePartialFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return new Contact(input, extensionRegistry);
        }
      };

      @java.lang.Override
      public com.google.protobuf.Parser<Contact> getParserForType() {
        return PARSER;
      }

      private int bitField0_;
      // required bytes publicKey = 1;
      public static final int PUBLICKEY_FIELD_NUMBER = 1;
      private com.google.protobuf.ByteString publicKey_;
      /**
       * <code>required bytes publicKey = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasPublicKey() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required bytes publicKey = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public com.google.protobuf.ByteString getPublicKey() {
        return publicKey_;
      }

      // required string name = 2;
      public static final int NAME_FIELD_NUMBER = 2;
      private java.lang.Object name_;
      /**
       * <code>required string name = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasName() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>required string name = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public java.lang.String getName() {
        java.lang.Object ref = name_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            name_ = s;
          }
          return s;
        }
      }
      /**
       * <code>required string name = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public com.google.protobuf.ByteString
          getNameBytes() {
        java.lang.Object ref = name_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          name_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // optional string profilePicture = 3;
      public static final int PROFILEPICTURE_FIELD_NUMBER = 3;
      private java.lang.Object profilePicture_;
      /**
       * <code>optional string profilePicture = 3;</code>
       */
      public boolean hasProfilePicture() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional string profilePicture = 3;</code>
       */
      public java.lang.String getProfilePicture() {
        java.lang.Object ref = profilePicture_;
        if (ref instanceof java.lang.String) {
          return (java.lang.String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          if (bs.isValidUtf8()) {
            profilePicture_ = s;
          }
          return s;
        }
      }
      /**
       * <code>optional string profilePicture = 3;</code>
       */
      public com.google.protobuf.ByteString
          getProfilePictureBytes() {
        java.lang.Object ref = profilePicture_;
        if (ref instanceof java.lang.String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          profilePicture_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }

      // optional bytes profileKey = 4;
      public static final int PROFILEKEY_FIELD_NUMBER = 4;
      private com.google.protobuf.ByteString profileKey_;
      /**
       * <code>optional bytes profileKey = 4;</code>
       */
      public boolean hasProfileKey() {
        return ((bitField0_ & 0x00000008) == 0x00000008);
      }
      /**
       * <code>optional bytes profileKey = 4;</code>
       */
      public com.google.protobuf.ByteString getProfileKey() {
        return profileKey_;
      }

      // optional bool isApproved = 5;
      public static final int ISAPPROVED_FIELD_NUMBER = 5;
      private boolean isApproved_;
      /**
       * <code>optional bool isApproved = 5;</code>
       */
      public boolean hasIsApproved() {
        return ((bitField0_ & 0x00000010) == 0x00000010);
      }
      /**
       * <code>optional bool isApproved = 5;</code>
       */
      public boolean getIsApproved() {
        return isApproved_;
      }

      // optional bool isBlocked = 6;
      public static final int ISBLOCKED_FIELD_NUMBER = 6;
      private boolean isBlocked_;
      /**
       * <code>optional bool isBlocked = 6;</code>
       */
      public boolean hasIsBlocked() {
        return ((bitField0_ & 0x00000020) == 0x00000020);
      }
      /**
       * <code>optional bool isBlocked = 6;</code>
       */
      public boolean getIsBlocked() {
        return isBlocked_;
      }

      // optional bool didApproveMe = 7;
      public static final int DIDAPPROVEME_FIELD_NUMBER = 7;
      private boolean didApproveMe_;
      /**
       * <code>optional bool didApproveMe = 7;</code>
       */
      public boolean hasDidApproveMe() {
        return ((bitField0_ & 0x00000040) == 0x00000040);
      }
      /**
       * <code>optional bool didApproveMe = 7;</code>
       */
      public boolean getDidApproveMe() {
        return didApproveMe_;
      }

      private void initFields() {
        publicKey_ = com.google.protobuf.ByteString.EMPTY;
        name_ = "";
        profilePicture_ = "";
        profileKey_ = com.google.protobuf.ByteString.EMPTY;
        isApproved_ = false;
        isBlocked_ = false;
        didApproveMe_ = false;
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;

        if (!hasPublicKey()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasName()) {
          memoizedIsInitialized = 0;
          return false;
        }
        memoizedIsInitialized = 1;
        return true;
      }

      public void writeTo(com.google.protobuf.CodedOutputStream output)
                          throws java.io.IOException {
        getSerializedSize();
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          output.writeBytes(1, publicKey_);
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(2, getNameBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          output.writeBytes(3, getProfilePictureBytes());
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          output.writeBytes(4, profileKey_);
        }
        if (((bitField0_ & 0x00000010) == 0x00000010)) {
          output.writeBool(5, isApproved_);
        }
        if (((bitField0_ & 0x00000020) == 0x00000020)) {
          output.writeBool(6, isBlocked_);
        }
        if (((bitField0_ & 0x00000040) == 0x00000040)) {
          output.writeBool(7, didApproveMe_);
        }
        getUnknownFields().writeTo(output);
      }

      private int memoizedSerializedSize = -1;
      public int getSerializedSize() {
        int size = memoizedSerializedSize;
        if (size != -1) return size;

        size = 0;
        if (((bitField0_ & 0x00000001) == 0x00000001)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(1, publicKey_);
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(2, getNameBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(3, getProfilePictureBytes());
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(4, profileKey_);
        }
        if (((bitField0_ & 0x00000010) == 0x00000010)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBoolSize(5, isApproved_);
        }
        if (((bitField0_ & 0x00000020) == 0x00000020)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBoolSize(6, isBlocked_);
        }
        if (((bitField0_ & 0x00000040) == 0x00000040)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBoolSize(7, didApproveMe_);
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }

      private static final long serialVersionUID = 0L;
      @java.lang.Override
      protected java.lang.Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }

      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return PARSER.parseFrom(data, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseDelimitedFrom(input, extensionRegistry);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return PARSER.parseFrom(input);
      }
      public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return PARSER.parseFrom(input, extensionRegistry);
      }

      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }

      @java.lang.Override
      protected Builder newBuilderForType(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      /**
       * Protobuf type {@code signalservice.ConfigurationMessage.Contact}
       */
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ContactOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_Contact_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_Contact_fieldAccessorTable
              .ensureFieldAccessorsInitialized(
                  org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.class, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.Builder.class);
        }

        // Construct using org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }

        private Builder(
            com.google.protobuf.GeneratedMessage.BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
          }
        }
        private static Builder create() {
          return new Builder();
        }

        public Builder clear() {
          super.clear();
          publicKey_ = com.google.protobuf.ByteString.EMPTY;
          bitField0_ = (bitField0_ & ~0x00000001);
          name_ = "";
          bitField0_ = (bitField0_ & ~0x00000002);
          profilePicture_ = "";
          bitField0_ = (bitField0_ & ~0x00000004);
          profileKey_ = com.google.protobuf.ByteString.EMPTY;
          bitField0_ = (bitField0_ & ~0x00000008);
          isApproved_ = false;
          bitField0_ = (bitField0_ & ~0x00000010);
          isBlocked_ = false;
          bitField0_ = (bitField0_ & ~0x00000020);
          didApproveMe_ = false;
          bitField0_ = (bitField0_ & ~0x00000040);
          return this;
        }

        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }

        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_Contact_descriptor;
        }

        public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact getDefaultInstanceForType() {
          return org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.getDefaultInstance();
        }

        public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact build() {
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }

        public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact buildPartial() {
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact result = new org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.publicKey_ = publicKey_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.name_ = name_;
          if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
            to_bitField0_ |= 0x00000004;
          }
          result.profilePicture_ = profilePicture_;
          if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
            to_bitField0_ |= 0x00000008;
          }
          result.profileKey_ = profileKey_;
          if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
            to_bitField0_ |= 0x00000010;
          }
          result.isApproved_ = isApproved_;
          if (((from_bitField0_ & 0x00000020) == 0x00000020)) {
            to_bitField0_ |= 0x00000020;
          }
          result.isBlocked_ = isBlocked_;
          if (((from_bitField0_ & 0x00000040) == 0x00000040)) {
            to_bitField0_ |= 0x00000040;
          }
          result.didApproveMe_ = didApproveMe_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }

        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact) {
            return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }

        public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact other) {
          if (other == org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.getDefaultInstance()) return this;
          if (other.hasPublicKey()) {
            setPublicKey(other.getPublicKey());
          }
          if (other.hasName()) {
            bitField0_ |= 0x00000002;
            name_ = other.name_;
            onChanged();
          }
          if (other.hasProfilePicture()) {
            bitField0_ |= 0x00000004;
            profilePicture_ = other.profilePicture_;
            onChanged();
          }
          if (other.hasProfileKey()) {
            setProfileKey(other.getProfileKey());
          }
          if (other.hasIsApproved()) {
            setIsApproved(other.getIsApproved());
          }
          if (other.hasIsBlocked()) {
            setIsBlocked(other.getIsBlocked());
          }
          if (other.hasDidApproveMe()) {
            setDidApproveMe(other.getDidApproveMe());
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }

        public final boolean isInitialized() {
          if (!hasPublicKey()) {
            
            return false;
          }
          if (!hasName()) {
            
            return false;
          }
          return true;
        }

        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact parsedMessage = null;
          try {
            parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
          } catch (com.google.protobuf.InvalidProtocolBufferException e) {
            parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact) e.getUnfinishedMessage();
            throw e;
          } finally {
            if (parsedMessage != null) {
              mergeFrom(parsedMessage);
            }
          }
          return this;
        }
        private int bitField0_;

        // required bytes publicKey = 1;
        private com.google.protobuf.ByteString publicKey_ = com.google.protobuf.ByteString.EMPTY;
        /**
         * <code>required bytes publicKey = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasPublicKey() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>required bytes publicKey = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public com.google.protobuf.ByteString getPublicKey() {
          return publicKey_;
        }
        /**
         * <code>required bytes publicKey = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setPublicKey(com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
          publicKey_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required bytes publicKey = 1;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder clearPublicKey() {
          bitField0_ = (bitField0_ & ~0x00000001);
          publicKey_ = getDefaultInstance().getPublicKey();
          onChanged();
          return this;
        }

        // required string name = 2;
        private java.lang.Object name_ = "";
        /**
         * <code>required string name = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public boolean hasName() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>required string name = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public java.lang.String getName() {
          java.lang.Object ref = name_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            name_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>required string name = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public com.google.protobuf.ByteString
            getNameBytes() {
          java.lang.Object ref = name_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            name_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>required string name = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setName(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>required string name = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder clearName() {
          bitField0_ = (bitField0_ & ~0x00000002);
          name_ = getDefaultInstance().getName();
          onChanged();
          return this;
        }
        /**
         * <code>required string name = 2;</code>
         *
         * <pre>
         * @required
         * </pre>
         */
        public Builder setNameBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
          return this;
        }

        // optional string profilePicture = 3;
        private java.lang.Object profilePicture_ = "";
        /**
         * <code>optional string profilePicture = 3;</code>
         */
        public boolean hasProfilePicture() {
          return ((bitField0_ & 0x00000004) == 0x00000004);
        }
        /**
         * <code>optional string profilePicture = 3;</code>
         */
        public java.lang.String getProfilePicture() {
          java.lang.Object ref = profilePicture_;
          if (!(ref instanceof java.lang.String)) {
            java.lang.String s = ((com.google.protobuf.ByteString) ref)
                .toStringUtf8();
            profilePicture_ = s;
            return s;
          } else {
            return (java.lang.String) ref;
          }
        }
        /**
         * <code>optional string profilePicture = 3;</code>
         */
        public com.google.protobuf.ByteString
            getProfilePictureBytes() {
          java.lang.Object ref = profilePicture_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8(
                    (java.lang.String) ref);
            profilePicture_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        /**
         * <code>optional string profilePicture = 3;</code>
         */
        public Builder setProfilePicture(
            java.lang.String value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
          profilePicture_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional string profilePicture = 3;</code>
         */
        public Builder clearProfilePicture() {
          bitField0_ = (bitField0_ & ~0x00000004);
          profilePicture_ = getDefaultInstance().getProfilePicture();
          onChanged();
          return this;
        }
        /**
         * <code>optional string profilePicture = 3;</code>
         */
        public Builder setProfilePictureBytes(
            com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
          profilePicture_ = value;
          onChanged();
          return this;
        }

        // optional bytes profileKey = 4;
        private com.google.protobuf.ByteString profileKey_ = com.google.protobuf.ByteString.EMPTY;
        /**
         * <code>optional bytes profileKey = 4;</code>
         */
        public boolean hasProfileKey() {
          return ((bitField0_ & 0x00000008) == 0x00000008);
        }
        /**
         * <code>optional bytes profileKey = 4;</code>
         */
        public com.google.protobuf.ByteString getProfileKey() {
          return profileKey_;
        }
        /**
         * <code>optional bytes profileKey = 4;</code>
         */
        public Builder setProfileKey(com.google.protobuf.ByteString value) {
          if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000008;
          profileKey_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional bytes profileKey = 4;</code>
         */
        public Builder clearProfileKey() {
          bitField0_ = (bitField0_ & ~0x00000008);
          profileKey_ = getDefaultInstance().getProfileKey();
          onChanged();
          return this;
        }

        // optional bool isApproved = 5;
        private boolean isApproved_ ;
        /**
         * <code>optional bool isApproved = 5;</code>
         */
        public boolean hasIsApproved() {
          return ((bitField0_ & 0x00000010) == 0x00000010);
        }
        /**
         * <code>optional bool isApproved = 5;</code>
         */
        public boolean getIsApproved() {
          return isApproved_;
        }
        /**
         * <code>optional bool isApproved = 5;</code>
         */
        public Builder setIsApproved(boolean value) {
          bitField0_ |= 0x00000010;
          isApproved_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional bool isApproved = 5;</code>
         */
        public Builder clearIsApproved() {
          bitField0_ = (bitField0_ & ~0x00000010);
          isApproved_ = false;
          onChanged();
          return this;
        }

        // optional bool isBlocked = 6;
        private boolean isBlocked_ ;
        /**
         * <code>optional bool isBlocked = 6;</code>
         */
        public boolean hasIsBlocked() {
          return ((bitField0_ & 0x00000020) == 0x00000020);
        }
        /**
         * <code>optional bool isBlocked = 6;</code>
         */
        public boolean getIsBlocked() {
          return isBlocked_;
        }
        /**
         * <code>optional bool isBlocked = 6;</code>
         */
        public Builder setIsBlocked(boolean value) {
          bitField0_ |= 0x00000020;
          isBlocked_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional bool isBlocked = 6;</code>
         */
        public Builder clearIsBlocked() {
          bitField0_ = (bitField0_ & ~0x00000020);
          isBlocked_ = false;
          onChanged();
          return this;
        }

        // optional bool didApproveMe = 7;
        private boolean didApproveMe_ ;
        /**
         * <code>optional bool didApproveMe = 7;</code>
         */
        public boolean hasDidApproveMe() {
          return ((bitField0_ & 0x00000040) == 0x00000040);
        }
        /**
         * <code>optional bool didApproveMe = 7;</code>
         */
        public boolean getDidApproveMe() {
          return didApproveMe_;
        }
        /**
         * <code>optional bool didApproveMe = 7;</code>
         */
        public Builder setDidApproveMe(boolean value) {
          bitField0_ |= 0x00000040;
          didApproveMe_ = value;
          onChanged();
          return this;
        }
        /**
         * <code>optional bool didApproveMe = 7;</code>
         */
        public Builder clearDidApproveMe() {
          bitField0_ = (bitField0_ & ~0x00000040);
          didApproveMe_ = false;
          onChanged();
          return this;
        }

        // @@protoc_insertion_point(builder_scope:signalservice.ConfigurationMessage.Contact)
      }

      static {
        defaultInstance = new Contact(true);
        defaultInstance.initFields();
      }

      // @@protoc_insertion_point(class_scope:signalservice.ConfigurationMessage.Contact)
    }

    private int bitField0_;
    // repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;
    public static final int CLOSEDGROUPS_FIELD_NUMBER = 1;
    private java.util.List<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup> closedGroups_;
    /**
     * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
     */
    public java.util.List<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup> getClosedGroupsList() {
      return closedGroups_;
    }
    /**
     * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
     */
    public java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroupOrBuilder> 
        getClosedGroupsOrBuilderList() {
      return closedGroups_;
    }
    /**
     * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
     */
    public int getClosedGroupsCount() {
      return closedGroups_.size();
    }
    /**
     * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup getClosedGroups(int index) {
      return closedGroups_.get(index);
    }
    /**
     * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroupOrBuilder getClosedGroupsOrBuilder(
        int index) {
      return closedGroups_.get(index);
    }

    // repeated string openGroups = 2;
    public static final int OPENGROUPS_FIELD_NUMBER = 2;
    private com.google.protobuf.LazyStringList openGroups_;
    /**
     * <code>repeated string openGroups = 2;</code>
     */
    public java.util.List<java.lang.String>
        getOpenGroupsList() {
      return openGroups_;
    }
    /**
     * <code>repeated string openGroups = 2;</code>
     */
    public int getOpenGroupsCount() {
      return openGroups_.size();
    }
    /**
     * <code>repeated string openGroups = 2;</code>
     */
    public java.lang.String getOpenGroups(int index) {
      return openGroups_.get(index);
    }
    /**
     * <code>repeated string openGroups = 2;</code>
     */
    public com.google.protobuf.ByteString
        getOpenGroupsBytes(int index) {
      return openGroups_.getByteString(index);
    }

    // optional string displayName = 3;
    public static final int DISPLAYNAME_FIELD_NUMBER = 3;
    private java.lang.Object displayName_;
    /**
     * <code>optional string displayName = 3;</code>
     */
    public boolean hasDisplayName() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>optional string displayName = 3;</code>
     */
    public java.lang.String getDisplayName() {
      java.lang.Object ref = displayName_;
      if (ref instanceof java.lang.String) {
        return (java.lang.String) ref;
      } else {
        com.google.protobuf.ByteString bs = 
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          displayName_ = s;
        }
        return s;
      }
    }
    /**
     * <code>optional string displayName = 3;</code>
     */
    public com.google.protobuf.ByteString
        getDisplayNameBytes() {
      java.lang.Object ref = displayName_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        displayName_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    // optional string profilePicture = 4;
    public static final int PROFILEPICTURE_FIELD_NUMBER = 4;
    private java.lang.Object profilePicture_;
    /**
     * <code>optional string profilePicture = 4;</code>
     */
    public boolean hasProfilePicture() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>optional string profilePicture = 4;</code>
     */
    public java.lang.String getProfilePicture() {
      java.lang.Object ref = profilePicture_;
      if (ref instanceof java.lang.String) {
        return (java.lang.String) ref;
      } else {
        com.google.protobuf.ByteString bs = 
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          profilePicture_ = s;
        }
        return s;
      }
    }
    /**
     * <code>optional string profilePicture = 4;</code>
     */
    public com.google.protobuf.ByteString
        getProfilePictureBytes() {
      java.lang.Object ref = profilePicture_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        profilePicture_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    // optional bytes profileKey = 5;
    public static final int PROFILEKEY_FIELD_NUMBER = 5;
    private com.google.protobuf.ByteString profileKey_;
    /**
     * <code>optional bytes profileKey = 5;</code>
     */
    public boolean hasProfileKey() {
      return ((bitField0_ & 0x00000004) == 0x00000004);
    }
    /**
     * <code>optional bytes profileKey = 5;</code>
     */
    public com.google.protobuf.ByteString getProfileKey() {
      return profileKey_;
    }

    // repeated .signalservice.ConfigurationMessage.Contact contacts = 6;
    public static final int CONTACTS_FIELD_NUMBER = 6;
    private java.util.List<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact> contacts_;
    /**
     * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
     */
    public java.util.List<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact> getContactsList() {
      return contacts_;
    }
    /**
     * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
     */
    public java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ContactOrBuilder> 
        getContactsOrBuilderList() {
      return contacts_;
    }
    /**
     * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
     */
    public int getContactsCount() {
      return contacts_.size();
    }
    /**
     * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact getContacts(int index) {
      return contacts_.get(index);
    }
    /**
     * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ContactOrBuilder getContactsOrBuilder(
        int index) {
      return contacts_.get(index);
    }

    private void initFields() {
      closedGroups_ = java.util.Collections.emptyList();
      openGroups_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      displayName_ = "";
      profilePicture_ = "";
      profileKey_ = com.google.protobuf.ByteString.EMPTY;
      contacts_ = java.util.Collections.emptyList();
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      for (int i = 0; i < getClosedGroupsCount(); i++) {
        if (!getClosedGroups(i).isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      for (int i = 0; i < getContactsCount(); i++) {
        if (!getContacts(i).isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      for (int i = 0; i < closedGroups_.size(); i++) {
        output.writeMessage(1, closedGroups_.get(i));
      }
      for (int i = 0; i < openGroups_.size(); i++) {
        output.writeBytes(2, openGroups_.getByteString(i));
      }
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeBytes(3, getDisplayNameBytes());
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeBytes(4, getProfilePictureBytes());
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        output.writeBytes(5, profileKey_);
      }
      for (int i = 0; i < contacts_.size(); i++) {
        output.writeMessage(6, contacts_.get(i));
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      for (int i = 0; i < closedGroups_.size(); i++) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(1, closedGroups_.get(i));
      }
      {
        int dataSize = 0;
        for (int i = 0; i < openGroups_.size(); i++) {
          dataSize += com.google.protobuf.CodedOutputStream
            .computeBytesSizeNoTag(openGroups_.getByteString(i));
        }
        size += dataSize;
        size += 1 * getOpenGroupsList().size();
      }
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(3, getDisplayNameBytes());
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(4, getProfilePictureBytes());
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(5, profileKey_);
      }
      for (int i = 0; i < contacts_.size(); i++) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(6, contacts_.get(i));
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.ConfigurationMessage}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessageOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.class, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
          getClosedGroupsFieldBuilder();
          getContactsFieldBuilder();
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        if (closedGroupsBuilder_ == null) {
          closedGroups_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000001);
        } else {
          closedGroupsBuilder_.clear();
        }
        openGroups_ = com.google.protobuf.LazyStringArrayList.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000002);
        displayName_ = "";
        bitField0_ = (bitField0_ & ~0x00000004);
        profilePicture_ = "";
        bitField0_ = (bitField0_ & ~0x00000008);
        profileKey_ = com.google.protobuf.ByteString.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000010);
        if (contactsBuilder_ == null) {
          contacts_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000020);
        } else {
          contactsBuilder_.clear();
        }
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ConfigurationMessage_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage build() {
        org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage result = new org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (closedGroupsBuilder_ == null) {
          if (((bitField0_ & 0x00000001) == 0x00000001)) {
            closedGroups_ = java.util.Collections.unmodifiableList(closedGroups_);
            bitField0_ = (bitField0_ & ~0x00000001);
          }
          result.closedGroups_ = closedGroups_;
        } else {
          result.closedGroups_ = closedGroupsBuilder_.build();
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          openGroups_ = new com.google.protobuf.UnmodifiableLazyStringList(
              openGroups_);
          bitField0_ = (bitField0_ & ~0x00000002);
        }
        result.openGroups_ = openGroups_;
        if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
          to_bitField0_ |= 0x00000001;
        }
        result.displayName_ = displayName_;
        if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
          to_bitField0_ |= 0x00000002;
        }
        result.profilePicture_ = profilePicture_;
        if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
          to_bitField0_ |= 0x00000004;
        }
        result.profileKey_ = profileKey_;
        if (contactsBuilder_ == null) {
          if (((bitField0_ & 0x00000020) == 0x00000020)) {
            contacts_ = java.util.Collections.unmodifiableList(contacts_);
            bitField0_ = (bitField0_ & ~0x00000020);
          }
          result.contacts_ = contacts_;
        } else {
          result.contacts_ = contactsBuilder_.build();
        }
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.getDefaultInstance()) return this;
        if (closedGroupsBuilder_ == null) {
          if (!other.closedGroups_.isEmpty()) {
            if (closedGroups_.isEmpty()) {
              closedGroups_ = other.closedGroups_;
              bitField0_ = (bitField0_ & ~0x00000001);
            } else {
              ensureClosedGroupsIsMutable();
              closedGroups_.addAll(other.closedGroups_);
            }
            onChanged();
          }
        } else {
          if (!other.closedGroups_.isEmpty()) {
            if (closedGroupsBuilder_.isEmpty()) {
              closedGroupsBuilder_.dispose();
              closedGroupsBuilder_ = null;
              closedGroups_ = other.closedGroups_;
              bitField0_ = (bitField0_ & ~0x00000001);
              closedGroupsBuilder_ = 
                com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                   getClosedGroupsFieldBuilder() : null;
            } else {
              closedGroupsBuilder_.addAllMessages(other.closedGroups_);
            }
          }
        }
        if (!other.openGroups_.isEmpty()) {
          if (openGroups_.isEmpty()) {
            openGroups_ = other.openGroups_;
            bitField0_ = (bitField0_ & ~0x00000002);
          } else {
            ensureOpenGroupsIsMutable();
            openGroups_.addAll(other.openGroups_);
          }
          onChanged();
        }
        if (other.hasDisplayName()) {
          bitField0_ |= 0x00000004;
          displayName_ = other.displayName_;
          onChanged();
        }
        if (other.hasProfilePicture()) {
          bitField0_ |= 0x00000008;
          profilePicture_ = other.profilePicture_;
          onChanged();
        }
        if (other.hasProfileKey()) {
          setProfileKey(other.getProfileKey());
        }
        if (contactsBuilder_ == null) {
          if (!other.contacts_.isEmpty()) {
            if (contacts_.isEmpty()) {
              contacts_ = other.contacts_;
              bitField0_ = (bitField0_ & ~0x00000020);
            } else {
              ensureContactsIsMutable();
              contacts_.addAll(other.contacts_);
            }
            onChanged();
          }
        } else {
          if (!other.contacts_.isEmpty()) {
            if (contactsBuilder_.isEmpty()) {
              contactsBuilder_.dispose();
              contactsBuilder_ = null;
              contacts_ = other.contacts_;
              bitField0_ = (bitField0_ & ~0x00000020);
              contactsBuilder_ = 
                com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                   getContactsFieldBuilder() : null;
            } else {
              contactsBuilder_.addAllMessages(other.contacts_);
            }
          }
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        for (int i = 0; i < getClosedGroupsCount(); i++) {
          if (!getClosedGroups(i).isInitialized()) {
            
            return false;
          }
        }
        for (int i = 0; i < getContactsCount(); i++) {
          if (!getContacts(i).isInitialized()) {
            
            return false;
          }
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;
      private java.util.List<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup> closedGroups_ =
        java.util.Collections.emptyList();
      private void ensureClosedGroupsIsMutable() {
        if (!((bitField0_ & 0x00000001) == 0x00000001)) {
          closedGroups_ = new java.util.ArrayList<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup>(closedGroups_);
          bitField0_ |= 0x00000001;
         }
      }

      private com.google.protobuf.RepeatedFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.Builder, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroupOrBuilder> closedGroupsBuilder_;

      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public java.util.List<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup> getClosedGroupsList() {
        if (closedGroupsBuilder_ == null) {
          return java.util.Collections.unmodifiableList(closedGroups_);
        } else {
          return closedGroupsBuilder_.getMessageList();
        }
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public int getClosedGroupsCount() {
        if (closedGroupsBuilder_ == null) {
          return closedGroups_.size();
        } else {
          return closedGroupsBuilder_.getCount();
        }
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup getClosedGroups(int index) {
        if (closedGroupsBuilder_ == null) {
          return closedGroups_.get(index);
        } else {
          return closedGroupsBuilder_.getMessage(index);
        }
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public Builder setClosedGroups(
          int index, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup value) {
        if (closedGroupsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureClosedGroupsIsMutable();
          closedGroups_.set(index, value);
          onChanged();
        } else {
          closedGroupsBuilder_.setMessage(index, value);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public Builder setClosedGroups(
          int index, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.Builder builderForValue) {
        if (closedGroupsBuilder_ == null) {
          ensureClosedGroupsIsMutable();
          closedGroups_.set(index, builderForValue.build());
          onChanged();
        } else {
          closedGroupsBuilder_.setMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public Builder addClosedGroups(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup value) {
        if (closedGroupsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureClosedGroupsIsMutable();
          closedGroups_.add(value);
          onChanged();
        } else {
          closedGroupsBuilder_.addMessage(value);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public Builder addClosedGroups(
          int index, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup value) {
        if (closedGroupsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureClosedGroupsIsMutable();
          closedGroups_.add(index, value);
          onChanged();
        } else {
          closedGroupsBuilder_.addMessage(index, value);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public Builder addClosedGroups(
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.Builder builderForValue) {
        if (closedGroupsBuilder_ == null) {
          ensureClosedGroupsIsMutable();
          closedGroups_.add(builderForValue.build());
          onChanged();
        } else {
          closedGroupsBuilder_.addMessage(builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public Builder addClosedGroups(
          int index, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.Builder builderForValue) {
        if (closedGroupsBuilder_ == null) {
          ensureClosedGroupsIsMutable();
          closedGroups_.add(index, builderForValue.build());
          onChanged();
        } else {
          closedGroupsBuilder_.addMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public Builder addAllClosedGroups(
          java.lang.Iterable<? extends org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup> values) {
        if (closedGroupsBuilder_ == null) {
          ensureClosedGroupsIsMutable();
          super.addAll(values, closedGroups_);
          onChanged();
        } else {
          closedGroupsBuilder_.addAllMessages(values);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public Builder clearClosedGroups() {
        if (closedGroupsBuilder_ == null) {
          closedGroups_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000001);
          onChanged();
        } else {
          closedGroupsBuilder_.clear();
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public Builder removeClosedGroups(int index) {
        if (closedGroupsBuilder_ == null) {
          ensureClosedGroupsIsMutable();
          closedGroups_.remove(index);
          onChanged();
        } else {
          closedGroupsBuilder_.remove(index);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.Builder getClosedGroupsBuilder(
          int index) {
        return getClosedGroupsFieldBuilder().getBuilder(index);
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroupOrBuilder getClosedGroupsOrBuilder(
          int index) {
        if (closedGroupsBuilder_ == null) {
          return closedGroups_.get(index);  } else {
          return closedGroupsBuilder_.getMessageOrBuilder(index);
        }
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroupOrBuilder> 
           getClosedGroupsOrBuilderList() {
        if (closedGroupsBuilder_ != null) {
          return closedGroupsBuilder_.getMessageOrBuilderList();
        } else {
          return java.util.Collections.unmodifiableList(closedGroups_);
        }
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.Builder addClosedGroupsBuilder() {
        return getClosedGroupsFieldBuilder().addBuilder(
            org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.getDefaultInstance());
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.Builder addClosedGroupsBuilder(
          int index) {
        return getClosedGroupsFieldBuilder().addBuilder(
            index, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.getDefaultInstance());
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.ClosedGroup closedGroups = 1;</code>
       */
      public java.util.List<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.Builder> 
           getClosedGroupsBuilderList() {
        return getClosedGroupsFieldBuilder().getBuilderList();
      }
      private com.google.protobuf.RepeatedFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.Builder, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroupOrBuilder> 
          getClosedGroupsFieldBuilder() {
        if (closedGroupsBuilder_ == null) {
          closedGroupsBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroup.Builder, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ClosedGroupOrBuilder>(
                  closedGroups_,
                  ((bitField0_ & 0x00000001) == 0x00000001),
                  getParentForChildren(),
                  isClean());
          closedGroups_ = null;
        }
        return closedGroupsBuilder_;
      }

      // repeated string openGroups = 2;
      private com.google.protobuf.LazyStringList openGroups_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      private void ensureOpenGroupsIsMutable() {
        if (!((bitField0_ & 0x00000002) == 0x00000002)) {
          openGroups_ = new com.google.protobuf.LazyStringArrayList(openGroups_);
          bitField0_ |= 0x00000002;
         }
      }
      /**
       * <code>repeated string openGroups = 2;</code>
       */
      public java.util.List<java.lang.String>
          getOpenGroupsList() {
        return java.util.Collections.unmodifiableList(openGroups_);
      }
      /**
       * <code>repeated string openGroups = 2;</code>
       */
      public int getOpenGroupsCount() {
        return openGroups_.size();
      }
      /**
       * <code>repeated string openGroups = 2;</code>
       */
      public java.lang.String getOpenGroups(int index) {
        return openGroups_.get(index);
      }
      /**
       * <code>repeated string openGroups = 2;</code>
       */
      public com.google.protobuf.ByteString
          getOpenGroupsBytes(int index) {
        return openGroups_.getByteString(index);
      }
      /**
       * <code>repeated string openGroups = 2;</code>
       */
      public Builder setOpenGroups(
          int index, java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureOpenGroupsIsMutable();
        openGroups_.set(index, value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string openGroups = 2;</code>
       */
      public Builder addOpenGroups(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureOpenGroupsIsMutable();
        openGroups_.add(value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string openGroups = 2;</code>
       */
      public Builder addAllOpenGroups(
          java.lang.Iterable<java.lang.String> values) {
        ensureOpenGroupsIsMutable();
        super.addAll(values, openGroups_);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string openGroups = 2;</code>
       */
      public Builder clearOpenGroups() {
        openGroups_ = com.google.protobuf.LazyStringArrayList.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000002);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string openGroups = 2;</code>
       */
      public Builder addOpenGroupsBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureOpenGroupsIsMutable();
        openGroups_.add(value);
        onChanged();
        return this;
      }

      // optional string displayName = 3;
      private java.lang.Object displayName_ = "";
      /**
       * <code>optional string displayName = 3;</code>
       */
      public boolean hasDisplayName() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional string displayName = 3;</code>
       */
      public java.lang.String getDisplayName() {
        java.lang.Object ref = displayName_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          displayName_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>optional string displayName = 3;</code>
       */
      public com.google.protobuf.ByteString
          getDisplayNameBytes() {
        java.lang.Object ref = displayName_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          displayName_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>optional string displayName = 3;</code>
       */
      public Builder setDisplayName(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
        displayName_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional string displayName = 3;</code>
       */
      public Builder clearDisplayName() {
        bitField0_ = (bitField0_ & ~0x00000004);
        displayName_ = getDefaultInstance().getDisplayName();
        onChanged();
        return this;
      }
      /**
       * <code>optional string displayName = 3;</code>
       */
      public Builder setDisplayNameBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
        displayName_ = value;
        onChanged();
        return this;
      }

      // optional string profilePicture = 4;
      private java.lang.Object profilePicture_ = "";
      /**
       * <code>optional string profilePicture = 4;</code>
       */
      public boolean hasProfilePicture() {
        return ((bitField0_ & 0x00000008) == 0x00000008);
      }
      /**
       * <code>optional string profilePicture = 4;</code>
       */
      public java.lang.String getProfilePicture() {
        java.lang.Object ref = profilePicture_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          profilePicture_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>optional string profilePicture = 4;</code>
       */
      public com.google.protobuf.ByteString
          getProfilePictureBytes() {
        java.lang.Object ref = profilePicture_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          profilePicture_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>optional string profilePicture = 4;</code>
       */
      public Builder setProfilePicture(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000008;
        profilePicture_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional string profilePicture = 4;</code>
       */
      public Builder clearProfilePicture() {
        bitField0_ = (bitField0_ & ~0x00000008);
        profilePicture_ = getDefaultInstance().getProfilePicture();
        onChanged();
        return this;
      }
      /**
       * <code>optional string profilePicture = 4;</code>
       */
      public Builder setProfilePictureBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000008;
        profilePicture_ = value;
        onChanged();
        return this;
      }

      // optional bytes profileKey = 5;
      private com.google.protobuf.ByteString profileKey_ = com.google.protobuf.ByteString.EMPTY;
      /**
       * <code>optional bytes profileKey = 5;</code>
       */
      public boolean hasProfileKey() {
        return ((bitField0_ & 0x00000010) == 0x00000010);
      }
      /**
       * <code>optional bytes profileKey = 5;</code>
       */
      public com.google.protobuf.ByteString getProfileKey() {
        return profileKey_;
      }
      /**
       * <code>optional bytes profileKey = 5;</code>
       */
      public Builder setProfileKey(com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000010;
        profileKey_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional bytes profileKey = 5;</code>
       */
      public Builder clearProfileKey() {
        bitField0_ = (bitField0_ & ~0x00000010);
        profileKey_ = getDefaultInstance().getProfileKey();
        onChanged();
        return this;
      }

      // repeated .signalservice.ConfigurationMessage.Contact contacts = 6;
      private java.util.List<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact> contacts_ =
        java.util.Collections.emptyList();
      private void ensureContactsIsMutable() {
        if (!((bitField0_ & 0x00000020) == 0x00000020)) {
          contacts_ = new java.util.ArrayList<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact>(contacts_);
          bitField0_ |= 0x00000020;
         }
      }

      private com.google.protobuf.RepeatedFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.Builder, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ContactOrBuilder> contactsBuilder_;

      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public java.util.List<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact> getContactsList() {
        if (contactsBuilder_ == null) {
          return java.util.Collections.unmodifiableList(contacts_);
        } else {
          return contactsBuilder_.getMessageList();
        }
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public int getContactsCount() {
        if (contactsBuilder_ == null) {
          return contacts_.size();
        } else {
          return contactsBuilder_.getCount();
        }
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact getContacts(int index) {
        if (contactsBuilder_ == null) {
          return contacts_.get(index);
        } else {
          return contactsBuilder_.getMessage(index);
        }
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public Builder setContacts(
          int index, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact value) {
        if (contactsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureContactsIsMutable();
          contacts_.set(index, value);
          onChanged();
        } else {
          contactsBuilder_.setMessage(index, value);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public Builder setContacts(
          int index, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.Builder builderForValue) {
        if (contactsBuilder_ == null) {
          ensureContactsIsMutable();
          contacts_.set(index, builderForValue.build());
          onChanged();
        } else {
          contactsBuilder_.setMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public Builder addContacts(org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact value) {
        if (contactsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureContactsIsMutable();
          contacts_.add(value);
          onChanged();
        } else {
          contactsBuilder_.addMessage(value);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public Builder addContacts(
          int index, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact value) {
        if (contactsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureContactsIsMutable();
          contacts_.add(index, value);
          onChanged();
        } else {
          contactsBuilder_.addMessage(index, value);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public Builder addContacts(
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.Builder builderForValue) {
        if (contactsBuilder_ == null) {
          ensureContactsIsMutable();
          contacts_.add(builderForValue.build());
          onChanged();
        } else {
          contactsBuilder_.addMessage(builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public Builder addContacts(
          int index, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.Builder builderForValue) {
        if (contactsBuilder_ == null) {
          ensureContactsIsMutable();
          contacts_.add(index, builderForValue.build());
          onChanged();
        } else {
          contactsBuilder_.addMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public Builder addAllContacts(
          java.lang.Iterable<? extends org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact> values) {
        if (contactsBuilder_ == null) {
          ensureContactsIsMutable();
          super.addAll(values, contacts_);
          onChanged();
        } else {
          contactsBuilder_.addAllMessages(values);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public Builder clearContacts() {
        if (contactsBuilder_ == null) {
          contacts_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000020);
          onChanged();
        } else {
          contactsBuilder_.clear();
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public Builder removeContacts(int index) {
        if (contactsBuilder_ == null) {
          ensureContactsIsMutable();
          contacts_.remove(index);
          onChanged();
        } else {
          contactsBuilder_.remove(index);
        }
        return this;
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.Builder getContactsBuilder(
          int index) {
        return getContactsFieldBuilder().getBuilder(index);
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ContactOrBuilder getContactsOrBuilder(
          int index) {
        if (contactsBuilder_ == null) {
          return contacts_.get(index);  } else {
          return contactsBuilder_.getMessageOrBuilder(index);
        }
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public java.util.List<? extends org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ContactOrBuilder> 
           getContactsOrBuilderList() {
        if (contactsBuilder_ != null) {
          return contactsBuilder_.getMessageOrBuilderList();
        } else {
          return java.util.Collections.unmodifiableList(contacts_);
        }
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.Builder addContactsBuilder() {
        return getContactsFieldBuilder().addBuilder(
            org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.getDefaultInstance());
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.Builder addContactsBuilder(
          int index) {
        return getContactsFieldBuilder().addBuilder(
            index, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.getDefaultInstance());
      }
      /**
       * <code>repeated .signalservice.ConfigurationMessage.Contact contacts = 6;</code>
       */
      public java.util.List<org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.Builder> 
           getContactsBuilderList() {
        return getContactsFieldBuilder().getBuilderList();
      }
      private com.google.protobuf.RepeatedFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.Builder, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ContactOrBuilder> 
          getContactsFieldBuilder() {
        if (contactsBuilder_ == null) {
          contactsBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.Contact.Builder, org.session.libsignal.protos.SignalServiceProtos.ConfigurationMessage.ContactOrBuilder>(
                  contacts_,
                  ((bitField0_ & 0x00000020) == 0x00000020),
                  getParentForChildren(),
                  isClean());
          contacts_ = null;
        }
        return contactsBuilder_;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.ConfigurationMessage)
    }

    static {
      defaultInstance = new ConfigurationMessage(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.ConfigurationMessage)
  }

  public interface MessageRequestResponseOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // required bool isApproved = 1;
    /**
     * <code>required bool isApproved = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasIsApproved();
    /**
     * <code>required bool isApproved = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean getIsApproved();

    // optional bytes profileKey = 2;
    /**
     * <code>optional bytes profileKey = 2;</code>
     */
    boolean hasProfileKey();
    /**
     * <code>optional bytes profileKey = 2;</code>
     */
    com.google.protobuf.ByteString getProfileKey();

    // optional .signalservice.DataMessage.LokiProfile profile = 3;
    /**
     * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
     */
    boolean hasProfile();
    /**
     * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile getProfile();
    /**
     * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder getProfileOrBuilder();
  }
  /**
   * Protobuf type {@code signalservice.MessageRequestResponse}
   */
  public static final class MessageRequestResponse extends
      com.google.protobuf.GeneratedMessage
      implements MessageRequestResponseOrBuilder {
    // Use MessageRequestResponse.newBuilder() to construct.
    private MessageRequestResponse(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private MessageRequestResponse(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final MessageRequestResponse defaultInstance;
    public static MessageRequestResponse getDefaultInstance() {
      return defaultInstance;
    }

    public MessageRequestResponse getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private MessageRequestResponse(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 8: {
              bitField0_ |= 0x00000001;
              isApproved_ = input.readBool();
              break;
            }
            case 18: {
              bitField0_ |= 0x00000002;
              profileKey_ = input.readBytes();
              break;
            }
            case 26: {
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder subBuilder = null;
              if (((bitField0_ & 0x00000004) == 0x00000004)) {
                subBuilder = profile_.toBuilder();
              }
              profile_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(profile_);
                profile_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000004;
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_MessageRequestResponse_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_MessageRequestResponse_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.class, org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.Builder.class);
    }

    public static com.google.protobuf.Parser<MessageRequestResponse> PARSER =
        new com.google.protobuf.AbstractParser<MessageRequestResponse>() {
      public MessageRequestResponse parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new MessageRequestResponse(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<MessageRequestResponse> getParserForType() {
      return PARSER;
    }

    private int bitField0_;
    // required bool isApproved = 1;
    public static final int ISAPPROVED_FIELD_NUMBER = 1;
    private boolean isApproved_;
    /**
     * <code>required bool isApproved = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasIsApproved() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>required bool isApproved = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean getIsApproved() {
      return isApproved_;
    }

    // optional bytes profileKey = 2;
    public static final int PROFILEKEY_FIELD_NUMBER = 2;
    private com.google.protobuf.ByteString profileKey_;
    /**
     * <code>optional bytes profileKey = 2;</code>
     */
    public boolean hasProfileKey() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>optional bytes profileKey = 2;</code>
     */
    public com.google.protobuf.ByteString getProfileKey() {
      return profileKey_;
    }

    // optional .signalservice.DataMessage.LokiProfile profile = 3;
    public static final int PROFILE_FIELD_NUMBER = 3;
    private org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile profile_;
    /**
     * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
     */
    public boolean hasProfile() {
      return ((bitField0_ & 0x00000004) == 0x00000004);
    }
    /**
     * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile getProfile() {
      return profile_;
    }
    /**
     * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder getProfileOrBuilder() {
      return profile_;
    }

    private void initFields() {
      isApproved_ = false;
      profileKey_ = com.google.protobuf.ByteString.EMPTY;
      profile_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.getDefaultInstance();
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      if (!hasIsApproved()) {
        memoizedIsInitialized = 0;
        return false;
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeBool(1, isApproved_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeBytes(2, profileKey_);
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        output.writeMessage(3, profile_);
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBoolSize(1, isApproved_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(2, profileKey_);
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(3, profile_);
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.MessageRequestResponse}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponseOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_MessageRequestResponse_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_MessageRequestResponse_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.class, org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
          getProfileFieldBuilder();
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        isApproved_ = false;
        bitField0_ = (bitField0_ & ~0x00000001);
        profileKey_ = com.google.protobuf.ByteString.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000002);
        if (profileBuilder_ == null) {
          profile_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.getDefaultInstance();
        } else {
          profileBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000004);
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_MessageRequestResponse_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse build() {
        org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse result = new org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.isApproved_ = isApproved_;
        if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
          to_bitField0_ |= 0x00000002;
        }
        result.profileKey_ = profileKey_;
        if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
          to_bitField0_ |= 0x00000004;
        }
        if (profileBuilder_ == null) {
          result.profile_ = profile_;
        } else {
          result.profile_ = profileBuilder_.build();
        }
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse.getDefaultInstance()) return this;
        if (other.hasIsApproved()) {
          setIsApproved(other.getIsApproved());
        }
        if (other.hasProfileKey()) {
          setProfileKey(other.getProfileKey());
        }
        if (other.hasProfile()) {
          mergeProfile(other.getProfile());
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        if (!hasIsApproved()) {
          
          return false;
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.MessageRequestResponse) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // required bool isApproved = 1;
      private boolean isApproved_ ;
      /**
       * <code>required bool isApproved = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasIsApproved() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required bool isApproved = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean getIsApproved() {
        return isApproved_;
      }
      /**
       * <code>required bool isApproved = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setIsApproved(boolean value) {
        bitField0_ |= 0x00000001;
        isApproved_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required bool isApproved = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearIsApproved() {
        bitField0_ = (bitField0_ & ~0x00000001);
        isApproved_ = false;
        onChanged();
        return this;
      }

      // optional bytes profileKey = 2;
      private com.google.protobuf.ByteString profileKey_ = com.google.protobuf.ByteString.EMPTY;
      /**
       * <code>optional bytes profileKey = 2;</code>
       */
      public boolean hasProfileKey() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>optional bytes profileKey = 2;</code>
       */
      public com.google.protobuf.ByteString getProfileKey() {
        return profileKey_;
      }
      /**
       * <code>optional bytes profileKey = 2;</code>
       */
      public Builder setProfileKey(com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
        profileKey_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional bytes profileKey = 2;</code>
       */
      public Builder clearProfileKey() {
        bitField0_ = (bitField0_ & ~0x00000002);
        profileKey_ = getDefaultInstance().getProfileKey();
        onChanged();
        return this;
      }

      // optional .signalservice.DataMessage.LokiProfile profile = 3;
      private org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile profile_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder> profileBuilder_;
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
       */
      public boolean hasProfile() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile getProfile() {
        if (profileBuilder_ == null) {
          return profile_;
        } else {
          return profileBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
       */
      public Builder setProfile(org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile value) {
        if (profileBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          profile_ = value;
          onChanged();
        } else {
          profileBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000004;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
       */
      public Builder setProfile(
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder builderForValue) {
        if (profileBuilder_ == null) {
          profile_ = builderForValue.build();
          onChanged();
        } else {
          profileBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000004;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
       */
      public Builder mergeProfile(org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile value) {
        if (profileBuilder_ == null) {
          if (((bitField0_ & 0x00000004) == 0x00000004) &&
              profile_ != org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.getDefaultInstance()) {
            profile_ =
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.newBuilder(profile_).mergeFrom(value).buildPartial();
          } else {
            profile_ = value;
          }
          onChanged();
        } else {
          profileBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000004;
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
       */
      public Builder clearProfile() {
        if (profileBuilder_ == null) {
          profile_ = org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.getDefaultInstance();
          onChanged();
        } else {
          profileBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000004);
        return this;
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder getProfileBuilder() {
        bitField0_ |= 0x00000004;
        onChanged();
        return getProfileFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder getProfileOrBuilder() {
        if (profileBuilder_ != null) {
          return profileBuilder_.getMessageOrBuilder();
        } else {
          return profile_;
        }
      }
      /**
       * <code>optional .signalservice.DataMessage.LokiProfile profile = 3;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder> 
          getProfileFieldBuilder() {
        if (profileBuilder_ == null) {
          profileBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfile.Builder, org.session.libsignal.protos.SignalServiceProtos.DataMessage.LokiProfileOrBuilder>(
                  profile_,
                  getParentForChildren(),
                  isClean());
          profile_ = null;
        }
        return profileBuilder_;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.MessageRequestResponse)
    }

    static {
      defaultInstance = new MessageRequestResponse(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.MessageRequestResponse)
  }

  public interface ReceiptMessageOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // required .signalservice.ReceiptMessage.Type type = 1;
    /**
     * <code>required .signalservice.ReceiptMessage.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasType();
    /**
     * <code>required .signalservice.ReceiptMessage.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Type getType();

    // repeated uint64 timestamp = 2;
    /**
     * <code>repeated uint64 timestamp = 2;</code>
     */
    java.util.List<java.lang.Long> getTimestampList();
    /**
     * <code>repeated uint64 timestamp = 2;</code>
     */
    int getTimestampCount();
    /**
     * <code>repeated uint64 timestamp = 2;</code>
     */
    long getTimestamp(int index);
  }
  /**
   * Protobuf type {@code signalservice.ReceiptMessage}
   */
  public static final class ReceiptMessage extends
      com.google.protobuf.GeneratedMessage
      implements ReceiptMessageOrBuilder {
    // Use ReceiptMessage.newBuilder() to construct.
    private ReceiptMessage(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private ReceiptMessage(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final ReceiptMessage defaultInstance;
    public static ReceiptMessage getDefaultInstance() {
      return defaultInstance;
    }

    public ReceiptMessage getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private ReceiptMessage(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 8: {
              int rawValue = input.readEnum();
              org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Type value = org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Type.valueOf(rawValue);
              if (value == null) {
                unknownFields.mergeVarintField(1, rawValue);
              } else {
                bitField0_ |= 0x00000001;
                type_ = value;
              }
              break;
            }
            case 16: {
              if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
                timestamp_ = new java.util.ArrayList<java.lang.Long>();
                mutable_bitField0_ |= 0x00000002;
              }
              timestamp_.add(input.readUInt64());
              break;
            }
            case 18: {
              int length = input.readRawVarint32();
              int limit = input.pushLimit(length);
              if (!((mutable_bitField0_ & 0x00000002) == 0x00000002) && input.getBytesUntilLimit() > 0) {
                timestamp_ = new java.util.ArrayList<java.lang.Long>();
                mutable_bitField0_ |= 0x00000002;
              }
              while (input.getBytesUntilLimit() > 0) {
                timestamp_.add(input.readUInt64());
              }
              input.popLimit(limit);
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
          timestamp_ = java.util.Collections.unmodifiableList(timestamp_);
        }
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ReceiptMessage_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ReceiptMessage_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.class, org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Builder.class);
    }

    public static com.google.protobuf.Parser<ReceiptMessage> PARSER =
        new com.google.protobuf.AbstractParser<ReceiptMessage>() {
      public ReceiptMessage parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new ReceiptMessage(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<ReceiptMessage> getParserForType() {
      return PARSER;
    }

    /**
     * Protobuf enum {@code signalservice.ReceiptMessage.Type}
     */
    public enum Type
        implements com.google.protobuf.ProtocolMessageEnum {
      /**
       * <code>DELIVERY = 0;</code>
       */
      DELIVERY(0, 0),
      /**
       * <code>READ = 1;</code>
       */
      READ(1, 1),
      ;

      /**
       * <code>DELIVERY = 0;</code>
       */
      public static final int DELIVERY_VALUE = 0;
      /**
       * <code>READ = 1;</code>
       */
      public static final int READ_VALUE = 1;


      public final int getNumber() { return value; }

      public static Type valueOf(int value) {
        switch (value) {
          case 0: return DELIVERY;
          case 1: return READ;
          default: return null;
        }
      }

      public static com.google.protobuf.Internal.EnumLiteMap<Type>
          internalGetValueMap() {
        return internalValueMap;
      }
      private static com.google.protobuf.Internal.EnumLiteMap<Type>
          internalValueMap =
            new com.google.protobuf.Internal.EnumLiteMap<Type>() {
              public Type findValueByNumber(int number) {
                return Type.valueOf(number);
              }
            };

      public final com.google.protobuf.Descriptors.EnumValueDescriptor
          getValueDescriptor() {
        return getDescriptor().getValues().get(index);
      }
      public final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptorForType() {
        return getDescriptor();
      }
      public static final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.getDescriptor().getEnumTypes().get(0);
      }

      private static final Type[] VALUES = values();

      public static Type valueOf(
          com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
        if (desc.getType() != getDescriptor()) {
          throw new java.lang.IllegalArgumentException(
            "EnumValueDescriptor is not for this type.");
        }
        return VALUES[desc.getIndex()];
      }

      private final int index;
      private final int value;

      private Type(int index, int value) {
        this.index = index;
        this.value = value;
      }

      // @@protoc_insertion_point(enum_scope:signalservice.ReceiptMessage.Type)
    }

    private int bitField0_;
    // required .signalservice.ReceiptMessage.Type type = 1;
    public static final int TYPE_FIELD_NUMBER = 1;
    private org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Type type_;
    /**
     * <code>required .signalservice.ReceiptMessage.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasType() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>required .signalservice.ReceiptMessage.Type type = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Type getType() {
      return type_;
    }

    // repeated uint64 timestamp = 2;
    public static final int TIMESTAMP_FIELD_NUMBER = 2;
    private java.util.List<java.lang.Long> timestamp_;
    /**
     * <code>repeated uint64 timestamp = 2;</code>
     */
    public java.util.List<java.lang.Long>
        getTimestampList() {
      return timestamp_;
    }
    /**
     * <code>repeated uint64 timestamp = 2;</code>
     */
    public int getTimestampCount() {
      return timestamp_.size();
    }
    /**
     * <code>repeated uint64 timestamp = 2;</code>
     */
    public long getTimestamp(int index) {
      return timestamp_.get(index);
    }

    private void initFields() {
      type_ = org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Type.DELIVERY;
      timestamp_ = java.util.Collections.emptyList();
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      if (!hasType()) {
        memoizedIsInitialized = 0;
        return false;
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeEnum(1, type_.getNumber());
      }
      for (int i = 0; i < timestamp_.size(); i++) {
        output.writeUInt64(2, timestamp_.get(i));
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeEnumSize(1, type_.getNumber());
      }
      {
        int dataSize = 0;
        for (int i = 0; i < timestamp_.size(); i++) {
          dataSize += com.google.protobuf.CodedOutputStream
            .computeUInt64SizeNoTag(timestamp_.get(i));
        }
        size += dataSize;
        size += 1 * getTimestampList().size();
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.ReceiptMessage}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.ReceiptMessageOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ReceiptMessage_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ReceiptMessage_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.class, org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        type_ = org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Type.DELIVERY;
        bitField0_ = (bitField0_ & ~0x00000001);
        timestamp_ = java.util.Collections.emptyList();
        bitField0_ = (bitField0_ & ~0x00000002);
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_ReceiptMessage_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage build() {
        org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage result = new org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.type_ = type_;
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          timestamp_ = java.util.Collections.unmodifiableList(timestamp_);
          bitField0_ = (bitField0_ & ~0x00000002);
        }
        result.timestamp_ = timestamp_;
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.getDefaultInstance()) return this;
        if (other.hasType()) {
          setType(other.getType());
        }
        if (!other.timestamp_.isEmpty()) {
          if (timestamp_.isEmpty()) {
            timestamp_ = other.timestamp_;
            bitField0_ = (bitField0_ & ~0x00000002);
          } else {
            ensureTimestampIsMutable();
            timestamp_.addAll(other.timestamp_);
          }
          onChanged();
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        if (!hasType()) {
          
          return false;
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // required .signalservice.ReceiptMessage.Type type = 1;
      private org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Type type_ = org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Type.DELIVERY;
      /**
       * <code>required .signalservice.ReceiptMessage.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasType() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required .signalservice.ReceiptMessage.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Type getType() {
        return type_;
      }
      /**
       * <code>required .signalservice.ReceiptMessage.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setType(org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Type value) {
        if (value == null) {
          throw new NullPointerException();
        }
        bitField0_ |= 0x00000001;
        type_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required .signalservice.ReceiptMessage.Type type = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearType() {
        bitField0_ = (bitField0_ & ~0x00000001);
        type_ = org.session.libsignal.protos.SignalServiceProtos.ReceiptMessage.Type.DELIVERY;
        onChanged();
        return this;
      }

      // repeated uint64 timestamp = 2;
      private java.util.List<java.lang.Long> timestamp_ = java.util.Collections.emptyList();
      private void ensureTimestampIsMutable() {
        if (!((bitField0_ & 0x00000002) == 0x00000002)) {
          timestamp_ = new java.util.ArrayList<java.lang.Long>(timestamp_);
          bitField0_ |= 0x00000002;
         }
      }
      /**
       * <code>repeated uint64 timestamp = 2;</code>
       */
      public java.util.List<java.lang.Long>
          getTimestampList() {
        return java.util.Collections.unmodifiableList(timestamp_);
      }
      /**
       * <code>repeated uint64 timestamp = 2;</code>
       */
      public int getTimestampCount() {
        return timestamp_.size();
      }
      /**
       * <code>repeated uint64 timestamp = 2;</code>
       */
      public long getTimestamp(int index) {
        return timestamp_.get(index);
      }
      /**
       * <code>repeated uint64 timestamp = 2;</code>
       */
      public Builder setTimestamp(
          int index, long value) {
        ensureTimestampIsMutable();
        timestamp_.set(index, value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated uint64 timestamp = 2;</code>
       */
      public Builder addTimestamp(long value) {
        ensureTimestampIsMutable();
        timestamp_.add(value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated uint64 timestamp = 2;</code>
       */
      public Builder addAllTimestamp(
          java.lang.Iterable<? extends java.lang.Long> values) {
        ensureTimestampIsMutable();
        super.addAll(values, timestamp_);
        onChanged();
        return this;
      }
      /**
       * <code>repeated uint64 timestamp = 2;</code>
       */
      public Builder clearTimestamp() {
        timestamp_ = java.util.Collections.emptyList();
        bitField0_ = (bitField0_ & ~0x00000002);
        onChanged();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.ReceiptMessage)
    }

    static {
      defaultInstance = new ReceiptMessage(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.ReceiptMessage)
  }

  public interface AttachmentPointerOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // required fixed64 id = 1;
    /**
     * <code>required fixed64 id = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasId();
    /**
     * <code>required fixed64 id = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    long getId();

    // optional string contentType = 2;
    /**
     * <code>optional string contentType = 2;</code>
     */
    boolean hasContentType();
    /**
     * <code>optional string contentType = 2;</code>
     */
    java.lang.String getContentType();
    /**
     * <code>optional string contentType = 2;</code>
     */
    com.google.protobuf.ByteString
        getContentTypeBytes();

    // optional bytes key = 3;
    /**
     * <code>optional bytes key = 3;</code>
     */
    boolean hasKey();
    /**
     * <code>optional bytes key = 3;</code>
     */
    com.google.protobuf.ByteString getKey();

    // optional uint32 size = 4;
    /**
     * <code>optional uint32 size = 4;</code>
     */
    boolean hasSize();
    /**
     * <code>optional uint32 size = 4;</code>
     */
    int getSize();

    // optional bytes thumbnail = 5;
    /**
     * <code>optional bytes thumbnail = 5;</code>
     */
    boolean hasThumbnail();
    /**
     * <code>optional bytes thumbnail = 5;</code>
     */
    com.google.protobuf.ByteString getThumbnail();

    // optional bytes digest = 6;
    /**
     * <code>optional bytes digest = 6;</code>
     */
    boolean hasDigest();
    /**
     * <code>optional bytes digest = 6;</code>
     */
    com.google.protobuf.ByteString getDigest();

    // optional string fileName = 7;
    /**
     * <code>optional string fileName = 7;</code>
     */
    boolean hasFileName();
    /**
     * <code>optional string fileName = 7;</code>
     */
    java.lang.String getFileName();
    /**
     * <code>optional string fileName = 7;</code>
     */
    com.google.protobuf.ByteString
        getFileNameBytes();

    // optional uint32 flags = 8;
    /**
     * <code>optional uint32 flags = 8;</code>
     */
    boolean hasFlags();
    /**
     * <code>optional uint32 flags = 8;</code>
     */
    int getFlags();

    // optional uint32 width = 9;
    /**
     * <code>optional uint32 width = 9;</code>
     */
    boolean hasWidth();
    /**
     * <code>optional uint32 width = 9;</code>
     */
    int getWidth();

    // optional uint32 height = 10;
    /**
     * <code>optional uint32 height = 10;</code>
     */
    boolean hasHeight();
    /**
     * <code>optional uint32 height = 10;</code>
     */
    int getHeight();

    // optional string caption = 11;
    /**
     * <code>optional string caption = 11;</code>
     */
    boolean hasCaption();
    /**
     * <code>optional string caption = 11;</code>
     */
    java.lang.String getCaption();
    /**
     * <code>optional string caption = 11;</code>
     */
    com.google.protobuf.ByteString
        getCaptionBytes();

    // optional string url = 101;
    /**
     * <code>optional string url = 101;</code>
     */
    boolean hasUrl();
    /**
     * <code>optional string url = 101;</code>
     */
    java.lang.String getUrl();
    /**
     * <code>optional string url = 101;</code>
     */
    com.google.protobuf.ByteString
        getUrlBytes();
  }
  /**
   * Protobuf type {@code signalservice.AttachmentPointer}
   */
  public static final class AttachmentPointer extends
      com.google.protobuf.GeneratedMessage
      implements AttachmentPointerOrBuilder {
    // Use AttachmentPointer.newBuilder() to construct.
    private AttachmentPointer(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private AttachmentPointer(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final AttachmentPointer defaultInstance;
    public static AttachmentPointer getDefaultInstance() {
      return defaultInstance;
    }

    public AttachmentPointer getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private AttachmentPointer(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 9: {
              bitField0_ |= 0x00000001;
              id_ = input.readFixed64();
              break;
            }
            case 18: {
              bitField0_ |= 0x00000002;
              contentType_ = input.readBytes();
              break;
            }
            case 26: {
              bitField0_ |= 0x00000004;
              key_ = input.readBytes();
              break;
            }
            case 32: {
              bitField0_ |= 0x00000008;
              size_ = input.readUInt32();
              break;
            }
            case 42: {
              bitField0_ |= 0x00000010;
              thumbnail_ = input.readBytes();
              break;
            }
            case 50: {
              bitField0_ |= 0x00000020;
              digest_ = input.readBytes();
              break;
            }
            case 58: {
              bitField0_ |= 0x00000040;
              fileName_ = input.readBytes();
              break;
            }
            case 64: {
              bitField0_ |= 0x00000080;
              flags_ = input.readUInt32();
              break;
            }
            case 72: {
              bitField0_ |= 0x00000100;
              width_ = input.readUInt32();
              break;
            }
            case 80: {
              bitField0_ |= 0x00000200;
              height_ = input.readUInt32();
              break;
            }
            case 90: {
              bitField0_ |= 0x00000400;
              caption_ = input.readBytes();
              break;
            }
            case 810: {
              bitField0_ |= 0x00000800;
              url_ = input.readBytes();
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_AttachmentPointer_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_AttachmentPointer_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.class, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder.class);
    }

    public static com.google.protobuf.Parser<AttachmentPointer> PARSER =
        new com.google.protobuf.AbstractParser<AttachmentPointer>() {
      public AttachmentPointer parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new AttachmentPointer(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<AttachmentPointer> getParserForType() {
      return PARSER;
    }

    /**
     * Protobuf enum {@code signalservice.AttachmentPointer.Flags}
     */
    public enum Flags
        implements com.google.protobuf.ProtocolMessageEnum {
      /**
       * <code>VOICE_MESSAGE = 1;</code>
       */
      VOICE_MESSAGE(0, 1),
      ;

      /**
       * <code>VOICE_MESSAGE = 1;</code>
       */
      public static final int VOICE_MESSAGE_VALUE = 1;


      public final int getNumber() { return value; }

      public static Flags valueOf(int value) {
        switch (value) {
          case 1: return VOICE_MESSAGE;
          default: return null;
        }
      }

      public static com.google.protobuf.Internal.EnumLiteMap<Flags>
          internalGetValueMap() {
        return internalValueMap;
      }
      private static com.google.protobuf.Internal.EnumLiteMap<Flags>
          internalValueMap =
            new com.google.protobuf.Internal.EnumLiteMap<Flags>() {
              public Flags findValueByNumber(int number) {
                return Flags.valueOf(number);
              }
            };

      public final com.google.protobuf.Descriptors.EnumValueDescriptor
          getValueDescriptor() {
        return getDescriptor().getValues().get(index);
      }
      public final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptorForType() {
        return getDescriptor();
      }
      public static final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDescriptor().getEnumTypes().get(0);
      }

      private static final Flags[] VALUES = values();

      public static Flags valueOf(
          com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
        if (desc.getType() != getDescriptor()) {
          throw new java.lang.IllegalArgumentException(
            "EnumValueDescriptor is not for this type.");
        }
        return VALUES[desc.getIndex()];
      }

      private final int index;
      private final int value;

      private Flags(int index, int value) {
        this.index = index;
        this.value = value;
      }

      // @@protoc_insertion_point(enum_scope:signalservice.AttachmentPointer.Flags)
    }

    private int bitField0_;
    // required fixed64 id = 1;
    public static final int ID_FIELD_NUMBER = 1;
    private long id_;
    /**
     * <code>required fixed64 id = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasId() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>required fixed64 id = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public long getId() {
      return id_;
    }

    // optional string contentType = 2;
    public static final int CONTENTTYPE_FIELD_NUMBER = 2;
    private java.lang.Object contentType_;
    /**
     * <code>optional string contentType = 2;</code>
     */
    public boolean hasContentType() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>optional string contentType = 2;</code>
     */
    public java.lang.String getContentType() {
      java.lang.Object ref = contentType_;
      if (ref instanceof java.lang.String) {
        return (java.lang.String) ref;
      } else {
        com.google.protobuf.ByteString bs = 
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          contentType_ = s;
        }
        return s;
      }
    }
    /**
     * <code>optional string contentType = 2;</code>
     */
    public com.google.protobuf.ByteString
        getContentTypeBytes() {
      java.lang.Object ref = contentType_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        contentType_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    // optional bytes key = 3;
    public static final int KEY_FIELD_NUMBER = 3;
    private com.google.protobuf.ByteString key_;
    /**
     * <code>optional bytes key = 3;</code>
     */
    public boolean hasKey() {
      return ((bitField0_ & 0x00000004) == 0x00000004);
    }
    /**
     * <code>optional bytes key = 3;</code>
     */
    public com.google.protobuf.ByteString getKey() {
      return key_;
    }

    // optional uint32 size = 4;
    public static final int SIZE_FIELD_NUMBER = 4;
    private int size_;
    /**
     * <code>optional uint32 size = 4;</code>
     */
    public boolean hasSize() {
      return ((bitField0_ & 0x00000008) == 0x00000008);
    }
    /**
     * <code>optional uint32 size = 4;</code>
     */
    public int getSize() {
      return size_;
    }

    // optional bytes thumbnail = 5;
    public static final int THUMBNAIL_FIELD_NUMBER = 5;
    private com.google.protobuf.ByteString thumbnail_;
    /**
     * <code>optional bytes thumbnail = 5;</code>
     */
    public boolean hasThumbnail() {
      return ((bitField0_ & 0x00000010) == 0x00000010);
    }
    /**
     * <code>optional bytes thumbnail = 5;</code>
     */
    public com.google.protobuf.ByteString getThumbnail() {
      return thumbnail_;
    }

    // optional bytes digest = 6;
    public static final int DIGEST_FIELD_NUMBER = 6;
    private com.google.protobuf.ByteString digest_;
    /**
     * <code>optional bytes digest = 6;</code>
     */
    public boolean hasDigest() {
      return ((bitField0_ & 0x00000020) == 0x00000020);
    }
    /**
     * <code>optional bytes digest = 6;</code>
     */
    public com.google.protobuf.ByteString getDigest() {
      return digest_;
    }

    // optional string fileName = 7;
    public static final int FILENAME_FIELD_NUMBER = 7;
    private java.lang.Object fileName_;
    /**
     * <code>optional string fileName = 7;</code>
     */
    public boolean hasFileName() {
      return ((bitField0_ & 0x00000040) == 0x00000040);
    }
    /**
     * <code>optional string fileName = 7;</code>
     */
    public java.lang.String getFileName() {
      java.lang.Object ref = fileName_;
      if (ref instanceof java.lang.String) {
        return (java.lang.String) ref;
      } else {
        com.google.protobuf.ByteString bs = 
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          fileName_ = s;
        }
        return s;
      }
    }
    /**
     * <code>optional string fileName = 7;</code>
     */
    public com.google.protobuf.ByteString
        getFileNameBytes() {
      java.lang.Object ref = fileName_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        fileName_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    // optional uint32 flags = 8;
    public static final int FLAGS_FIELD_NUMBER = 8;
    private int flags_;
    /**
     * <code>optional uint32 flags = 8;</code>
     */
    public boolean hasFlags() {
      return ((bitField0_ & 0x00000080) == 0x00000080);
    }
    /**
     * <code>optional uint32 flags = 8;</code>
     */
    public int getFlags() {
      return flags_;
    }

    // optional uint32 width = 9;
    public static final int WIDTH_FIELD_NUMBER = 9;
    private int width_;
    /**
     * <code>optional uint32 width = 9;</code>
     */
    public boolean hasWidth() {
      return ((bitField0_ & 0x00000100) == 0x00000100);
    }
    /**
     * <code>optional uint32 width = 9;</code>
     */
    public int getWidth() {
      return width_;
    }

    // optional uint32 height = 10;
    public static final int HEIGHT_FIELD_NUMBER = 10;
    private int height_;
    /**
     * <code>optional uint32 height = 10;</code>
     */
    public boolean hasHeight() {
      return ((bitField0_ & 0x00000200) == 0x00000200);
    }
    /**
     * <code>optional uint32 height = 10;</code>
     */
    public int getHeight() {
      return height_;
    }

    // optional string caption = 11;
    public static final int CAPTION_FIELD_NUMBER = 11;
    private java.lang.Object caption_;
    /**
     * <code>optional string caption = 11;</code>
     */
    public boolean hasCaption() {
      return ((bitField0_ & 0x00000400) == 0x00000400);
    }
    /**
     * <code>optional string caption = 11;</code>
     */
    public java.lang.String getCaption() {
      java.lang.Object ref = caption_;
      if (ref instanceof java.lang.String) {
        return (java.lang.String) ref;
      } else {
        com.google.protobuf.ByteString bs = 
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          caption_ = s;
        }
        return s;
      }
    }
    /**
     * <code>optional string caption = 11;</code>
     */
    public com.google.protobuf.ByteString
        getCaptionBytes() {
      java.lang.Object ref = caption_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        caption_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    // optional string url = 101;
    public static final int URL_FIELD_NUMBER = 101;
    private java.lang.Object url_;
    /**
     * <code>optional string url = 101;</code>
     */
    public boolean hasUrl() {
      return ((bitField0_ & 0x00000800) == 0x00000800);
    }
    /**
     * <code>optional string url = 101;</code>
     */
    public java.lang.String getUrl() {
      java.lang.Object ref = url_;
      if (ref instanceof java.lang.String) {
        return (java.lang.String) ref;
      } else {
        com.google.protobuf.ByteString bs = 
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          url_ = s;
        }
        return s;
      }
    }
    /**
     * <code>optional string url = 101;</code>
     */
    public com.google.protobuf.ByteString
        getUrlBytes() {
      java.lang.Object ref = url_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        url_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    private void initFields() {
      id_ = 0L;
      contentType_ = "";
      key_ = com.google.protobuf.ByteString.EMPTY;
      size_ = 0;
      thumbnail_ = com.google.protobuf.ByteString.EMPTY;
      digest_ = com.google.protobuf.ByteString.EMPTY;
      fileName_ = "";
      flags_ = 0;
      width_ = 0;
      height_ = 0;
      caption_ = "";
      url_ = "";
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      if (!hasId()) {
        memoizedIsInitialized = 0;
        return false;
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeFixed64(1, id_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeBytes(2, getContentTypeBytes());
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        output.writeBytes(3, key_);
      }
      if (((bitField0_ & 0x00000008) == 0x00000008)) {
        output.writeUInt32(4, size_);
      }
      if (((bitField0_ & 0x00000010) == 0x00000010)) {
        output.writeBytes(5, thumbnail_);
      }
      if (((bitField0_ & 0x00000020) == 0x00000020)) {
        output.writeBytes(6, digest_);
      }
      if (((bitField0_ & 0x00000040) == 0x00000040)) {
        output.writeBytes(7, getFileNameBytes());
      }
      if (((bitField0_ & 0x00000080) == 0x00000080)) {
        output.writeUInt32(8, flags_);
      }
      if (((bitField0_ & 0x00000100) == 0x00000100)) {
        output.writeUInt32(9, width_);
      }
      if (((bitField0_ & 0x00000200) == 0x00000200)) {
        output.writeUInt32(10, height_);
      }
      if (((bitField0_ & 0x00000400) == 0x00000400)) {
        output.writeBytes(11, getCaptionBytes());
      }
      if (((bitField0_ & 0x00000800) == 0x00000800)) {
        output.writeBytes(101, getUrlBytes());
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeFixed64Size(1, id_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(2, getContentTypeBytes());
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(3, key_);
      }
      if (((bitField0_ & 0x00000008) == 0x00000008)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt32Size(4, size_);
      }
      if (((bitField0_ & 0x00000010) == 0x00000010)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(5, thumbnail_);
      }
      if (((bitField0_ & 0x00000020) == 0x00000020)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(6, digest_);
      }
      if (((bitField0_ & 0x00000040) == 0x00000040)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(7, getFileNameBytes());
      }
      if (((bitField0_ & 0x00000080) == 0x00000080)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt32Size(8, flags_);
      }
      if (((bitField0_ & 0x00000100) == 0x00000100)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt32Size(9, width_);
      }
      if (((bitField0_ & 0x00000200) == 0x00000200)) {
        size += com.google.protobuf.CodedOutputStream
          .computeUInt32Size(10, height_);
      }
      if (((bitField0_ & 0x00000400) == 0x00000400)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(11, getCaptionBytes());
      }
      if (((bitField0_ & 0x00000800) == 0x00000800)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(101, getUrlBytes());
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.AttachmentPointer}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_AttachmentPointer_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_AttachmentPointer_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.class, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        id_ = 0L;
        bitField0_ = (bitField0_ & ~0x00000001);
        contentType_ = "";
        bitField0_ = (bitField0_ & ~0x00000002);
        key_ = com.google.protobuf.ByteString.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000004);
        size_ = 0;
        bitField0_ = (bitField0_ & ~0x00000008);
        thumbnail_ = com.google.protobuf.ByteString.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000010);
        digest_ = com.google.protobuf.ByteString.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000020);
        fileName_ = "";
        bitField0_ = (bitField0_ & ~0x00000040);
        flags_ = 0;
        bitField0_ = (bitField0_ & ~0x00000080);
        width_ = 0;
        bitField0_ = (bitField0_ & ~0x00000100);
        height_ = 0;
        bitField0_ = (bitField0_ & ~0x00000200);
        caption_ = "";
        bitField0_ = (bitField0_ & ~0x00000400);
        url_ = "";
        bitField0_ = (bitField0_ & ~0x00000800);
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_AttachmentPointer_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer build() {
        org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer result = new org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.id_ = id_;
        if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
          to_bitField0_ |= 0x00000002;
        }
        result.contentType_ = contentType_;
        if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
          to_bitField0_ |= 0x00000004;
        }
        result.key_ = key_;
        if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
          to_bitField0_ |= 0x00000008;
        }
        result.size_ = size_;
        if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
          to_bitField0_ |= 0x00000010;
        }
        result.thumbnail_ = thumbnail_;
        if (((from_bitField0_ & 0x00000020) == 0x00000020)) {
          to_bitField0_ |= 0x00000020;
        }
        result.digest_ = digest_;
        if (((from_bitField0_ & 0x00000040) == 0x00000040)) {
          to_bitField0_ |= 0x00000040;
        }
        result.fileName_ = fileName_;
        if (((from_bitField0_ & 0x00000080) == 0x00000080)) {
          to_bitField0_ |= 0x00000080;
        }
        result.flags_ = flags_;
        if (((from_bitField0_ & 0x00000100) == 0x00000100)) {
          to_bitField0_ |= 0x00000100;
        }
        result.width_ = width_;
        if (((from_bitField0_ & 0x00000200) == 0x00000200)) {
          to_bitField0_ |= 0x00000200;
        }
        result.height_ = height_;
        if (((from_bitField0_ & 0x00000400) == 0x00000400)) {
          to_bitField0_ |= 0x00000400;
        }
        result.caption_ = caption_;
        if (((from_bitField0_ & 0x00000800) == 0x00000800)) {
          to_bitField0_ |= 0x00000800;
        }
        result.url_ = url_;
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance()) return this;
        if (other.hasId()) {
          setId(other.getId());
        }
        if (other.hasContentType()) {
          bitField0_ |= 0x00000002;
          contentType_ = other.contentType_;
          onChanged();
        }
        if (other.hasKey()) {
          setKey(other.getKey());
        }
        if (other.hasSize()) {
          setSize(other.getSize());
        }
        if (other.hasThumbnail()) {
          setThumbnail(other.getThumbnail());
        }
        if (other.hasDigest()) {
          setDigest(other.getDigest());
        }
        if (other.hasFileName()) {
          bitField0_ |= 0x00000040;
          fileName_ = other.fileName_;
          onChanged();
        }
        if (other.hasFlags()) {
          setFlags(other.getFlags());
        }
        if (other.hasWidth()) {
          setWidth(other.getWidth());
        }
        if (other.hasHeight()) {
          setHeight(other.getHeight());
        }
        if (other.hasCaption()) {
          bitField0_ |= 0x00000400;
          caption_ = other.caption_;
          onChanged();
        }
        if (other.hasUrl()) {
          bitField0_ |= 0x00000800;
          url_ = other.url_;
          onChanged();
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        if (!hasId()) {
          
          return false;
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // required fixed64 id = 1;
      private long id_ ;
      /**
       * <code>required fixed64 id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasId() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>required fixed64 id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public long getId() {
        return id_;
      }
      /**
       * <code>required fixed64 id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setId(long value) {
        bitField0_ |= 0x00000001;
        id_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>required fixed64 id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearId() {
        bitField0_ = (bitField0_ & ~0x00000001);
        id_ = 0L;
        onChanged();
        return this;
      }

      // optional string contentType = 2;
      private java.lang.Object contentType_ = "";
      /**
       * <code>optional string contentType = 2;</code>
       */
      public boolean hasContentType() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>optional string contentType = 2;</code>
       */
      public java.lang.String getContentType() {
        java.lang.Object ref = contentType_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          contentType_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>optional string contentType = 2;</code>
       */
      public com.google.protobuf.ByteString
          getContentTypeBytes() {
        java.lang.Object ref = contentType_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          contentType_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>optional string contentType = 2;</code>
       */
      public Builder setContentType(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
        contentType_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional string contentType = 2;</code>
       */
      public Builder clearContentType() {
        bitField0_ = (bitField0_ & ~0x00000002);
        contentType_ = getDefaultInstance().getContentType();
        onChanged();
        return this;
      }
      /**
       * <code>optional string contentType = 2;</code>
       */
      public Builder setContentTypeBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000002;
        contentType_ = value;
        onChanged();
        return this;
      }

      // optional bytes key = 3;
      private com.google.protobuf.ByteString key_ = com.google.protobuf.ByteString.EMPTY;
      /**
       * <code>optional bytes key = 3;</code>
       */
      public boolean hasKey() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional bytes key = 3;</code>
       */
      public com.google.protobuf.ByteString getKey() {
        return key_;
      }
      /**
       * <code>optional bytes key = 3;</code>
       */
      public Builder setKey(com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
        key_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional bytes key = 3;</code>
       */
      public Builder clearKey() {
        bitField0_ = (bitField0_ & ~0x00000004);
        key_ = getDefaultInstance().getKey();
        onChanged();
        return this;
      }

      // optional uint32 size = 4;
      private int size_ ;
      /**
       * <code>optional uint32 size = 4;</code>
       */
      public boolean hasSize() {
        return ((bitField0_ & 0x00000008) == 0x00000008);
      }
      /**
       * <code>optional uint32 size = 4;</code>
       */
      public int getSize() {
        return size_;
      }
      /**
       * <code>optional uint32 size = 4;</code>
       */
      public Builder setSize(int value) {
        bitField0_ |= 0x00000008;
        size_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional uint32 size = 4;</code>
       */
      public Builder clearSize() {
        bitField0_ = (bitField0_ & ~0x00000008);
        size_ = 0;
        onChanged();
        return this;
      }

      // optional bytes thumbnail = 5;
      private com.google.protobuf.ByteString thumbnail_ = com.google.protobuf.ByteString.EMPTY;
      /**
       * <code>optional bytes thumbnail = 5;</code>
       */
      public boolean hasThumbnail() {
        return ((bitField0_ & 0x00000010) == 0x00000010);
      }
      /**
       * <code>optional bytes thumbnail = 5;</code>
       */
      public com.google.protobuf.ByteString getThumbnail() {
        return thumbnail_;
      }
      /**
       * <code>optional bytes thumbnail = 5;</code>
       */
      public Builder setThumbnail(com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000010;
        thumbnail_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional bytes thumbnail = 5;</code>
       */
      public Builder clearThumbnail() {
        bitField0_ = (bitField0_ & ~0x00000010);
        thumbnail_ = getDefaultInstance().getThumbnail();
        onChanged();
        return this;
      }

      // optional bytes digest = 6;
      private com.google.protobuf.ByteString digest_ = com.google.protobuf.ByteString.EMPTY;
      /**
       * <code>optional bytes digest = 6;</code>
       */
      public boolean hasDigest() {
        return ((bitField0_ & 0x00000020) == 0x00000020);
      }
      /**
       * <code>optional bytes digest = 6;</code>
       */
      public com.google.protobuf.ByteString getDigest() {
        return digest_;
      }
      /**
       * <code>optional bytes digest = 6;</code>
       */
      public Builder setDigest(com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000020;
        digest_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional bytes digest = 6;</code>
       */
      public Builder clearDigest() {
        bitField0_ = (bitField0_ & ~0x00000020);
        digest_ = getDefaultInstance().getDigest();
        onChanged();
        return this;
      }

      // optional string fileName = 7;
      private java.lang.Object fileName_ = "";
      /**
       * <code>optional string fileName = 7;</code>
       */
      public boolean hasFileName() {
        return ((bitField0_ & 0x00000040) == 0x00000040);
      }
      /**
       * <code>optional string fileName = 7;</code>
       */
      public java.lang.String getFileName() {
        java.lang.Object ref = fileName_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          fileName_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>optional string fileName = 7;</code>
       */
      public com.google.protobuf.ByteString
          getFileNameBytes() {
        java.lang.Object ref = fileName_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          fileName_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>optional string fileName = 7;</code>
       */
      public Builder setFileName(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000040;
        fileName_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional string fileName = 7;</code>
       */
      public Builder clearFileName() {
        bitField0_ = (bitField0_ & ~0x00000040);
        fileName_ = getDefaultInstance().getFileName();
        onChanged();
        return this;
      }
      /**
       * <code>optional string fileName = 7;</code>
       */
      public Builder setFileNameBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000040;
        fileName_ = value;
        onChanged();
        return this;
      }

      // optional uint32 flags = 8;
      private int flags_ ;
      /**
       * <code>optional uint32 flags = 8;</code>
       */
      public boolean hasFlags() {
        return ((bitField0_ & 0x00000080) == 0x00000080);
      }
      /**
       * <code>optional uint32 flags = 8;</code>
       */
      public int getFlags() {
        return flags_;
      }
      /**
       * <code>optional uint32 flags = 8;</code>
       */
      public Builder setFlags(int value) {
        bitField0_ |= 0x00000080;
        flags_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional uint32 flags = 8;</code>
       */
      public Builder clearFlags() {
        bitField0_ = (bitField0_ & ~0x00000080);
        flags_ = 0;
        onChanged();
        return this;
      }

      // optional uint32 width = 9;
      private int width_ ;
      /**
       * <code>optional uint32 width = 9;</code>
       */
      public boolean hasWidth() {
        return ((bitField0_ & 0x00000100) == 0x00000100);
      }
      /**
       * <code>optional uint32 width = 9;</code>
       */
      public int getWidth() {
        return width_;
      }
      /**
       * <code>optional uint32 width = 9;</code>
       */
      public Builder setWidth(int value) {
        bitField0_ |= 0x00000100;
        width_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional uint32 width = 9;</code>
       */
      public Builder clearWidth() {
        bitField0_ = (bitField0_ & ~0x00000100);
        width_ = 0;
        onChanged();
        return this;
      }

      // optional uint32 height = 10;
      private int height_ ;
      /**
       * <code>optional uint32 height = 10;</code>
       */
      public boolean hasHeight() {
        return ((bitField0_ & 0x00000200) == 0x00000200);
      }
      /**
       * <code>optional uint32 height = 10;</code>
       */
      public int getHeight() {
        return height_;
      }
      /**
       * <code>optional uint32 height = 10;</code>
       */
      public Builder setHeight(int value) {
        bitField0_ |= 0x00000200;
        height_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional uint32 height = 10;</code>
       */
      public Builder clearHeight() {
        bitField0_ = (bitField0_ & ~0x00000200);
        height_ = 0;
        onChanged();
        return this;
      }

      // optional string caption = 11;
      private java.lang.Object caption_ = "";
      /**
       * <code>optional string caption = 11;</code>
       */
      public boolean hasCaption() {
        return ((bitField0_ & 0x00000400) == 0x00000400);
      }
      /**
       * <code>optional string caption = 11;</code>
       */
      public java.lang.String getCaption() {
        java.lang.Object ref = caption_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          caption_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>optional string caption = 11;</code>
       */
      public com.google.protobuf.ByteString
          getCaptionBytes() {
        java.lang.Object ref = caption_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          caption_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>optional string caption = 11;</code>
       */
      public Builder setCaption(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000400;
        caption_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional string caption = 11;</code>
       */
      public Builder clearCaption() {
        bitField0_ = (bitField0_ & ~0x00000400);
        caption_ = getDefaultInstance().getCaption();
        onChanged();
        return this;
      }
      /**
       * <code>optional string caption = 11;</code>
       */
      public Builder setCaptionBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000400;
        caption_ = value;
        onChanged();
        return this;
      }

      // optional string url = 101;
      private java.lang.Object url_ = "";
      /**
       * <code>optional string url = 101;</code>
       */
      public boolean hasUrl() {
        return ((bitField0_ & 0x00000800) == 0x00000800);
      }
      /**
       * <code>optional string url = 101;</code>
       */
      public java.lang.String getUrl() {
        java.lang.Object ref = url_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          url_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>optional string url = 101;</code>
       */
      public com.google.protobuf.ByteString
          getUrlBytes() {
        java.lang.Object ref = url_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          url_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>optional string url = 101;</code>
       */
      public Builder setUrl(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000800;
        url_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional string url = 101;</code>
       */
      public Builder clearUrl() {
        bitField0_ = (bitField0_ & ~0x00000800);
        url_ = getDefaultInstance().getUrl();
        onChanged();
        return this;
      }
      /**
       * <code>optional string url = 101;</code>
       */
      public Builder setUrlBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000800;
        url_ = value;
        onChanged();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.AttachmentPointer)
    }

    static {
      defaultInstance = new AttachmentPointer(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.AttachmentPointer)
  }

  public interface GroupContextOrBuilder
      extends com.google.protobuf.MessageOrBuilder {

    // optional bytes id = 1;
    /**
     * <code>optional bytes id = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasId();
    /**
     * <code>optional bytes id = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    com.google.protobuf.ByteString getId();

    // optional .signalservice.GroupContext.Type type = 2;
    /**
     * <code>optional .signalservice.GroupContext.Type type = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    boolean hasType();
    /**
     * <code>optional .signalservice.GroupContext.Type type = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    org.session.libsignal.protos.SignalServiceProtos.GroupContext.Type getType();

    // optional string name = 3;
    /**
     * <code>optional string name = 3;</code>
     */
    boolean hasName();
    /**
     * <code>optional string name = 3;</code>
     */
    java.lang.String getName();
    /**
     * <code>optional string name = 3;</code>
     */
    com.google.protobuf.ByteString
        getNameBytes();

    // repeated string members = 4;
    /**
     * <code>repeated string members = 4;</code>
     */
    java.util.List<java.lang.String>
    getMembersList();
    /**
     * <code>repeated string members = 4;</code>
     */
    int getMembersCount();
    /**
     * <code>repeated string members = 4;</code>
     */
    java.lang.String getMembers(int index);
    /**
     * <code>repeated string members = 4;</code>
     */
    com.google.protobuf.ByteString
        getMembersBytes(int index);

    // optional .signalservice.AttachmentPointer avatar = 5;
    /**
     * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
     */
    boolean hasAvatar();
    /**
     * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getAvatar();
    /**
     * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
     */
    org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder getAvatarOrBuilder();

    // repeated string admins = 6;
    /**
     * <code>repeated string admins = 6;</code>
     */
    java.util.List<java.lang.String>
    getAdminsList();
    /**
     * <code>repeated string admins = 6;</code>
     */
    int getAdminsCount();
    /**
     * <code>repeated string admins = 6;</code>
     */
    java.lang.String getAdmins(int index);
    /**
     * <code>repeated string admins = 6;</code>
     */
    com.google.protobuf.ByteString
        getAdminsBytes(int index);
  }
  /**
   * Protobuf type {@code signalservice.GroupContext}
   */
  public static final class GroupContext extends
      com.google.protobuf.GeneratedMessage
      implements GroupContextOrBuilder {
    // Use GroupContext.newBuilder() to construct.
    private GroupContext(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
      super(builder);
      this.unknownFields = builder.getUnknownFields();
    }
    private GroupContext(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

    private static final GroupContext defaultInstance;
    public static GroupContext getDefaultInstance() {
      return defaultInstance;
    }

    public GroupContext getDefaultInstanceForType() {
      return defaultInstance;
    }

    private final com.google.protobuf.UnknownFieldSet unknownFields;
    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
      return this.unknownFields;
    }
    private GroupContext(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      initFields();
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownField(input, unknownFields,
                                     extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 10: {
              bitField0_ |= 0x00000001;
              id_ = input.readBytes();
              break;
            }
            case 16: {
              int rawValue = input.readEnum();
              org.session.libsignal.protos.SignalServiceProtos.GroupContext.Type value = org.session.libsignal.protos.SignalServiceProtos.GroupContext.Type.valueOf(rawValue);
              if (value == null) {
                unknownFields.mergeVarintField(2, rawValue);
              } else {
                bitField0_ |= 0x00000002;
                type_ = value;
              }
              break;
            }
            case 26: {
              bitField0_ |= 0x00000004;
              name_ = input.readBytes();
              break;
            }
            case 34: {
              if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
                members_ = new com.google.protobuf.LazyStringArrayList();
                mutable_bitField0_ |= 0x00000008;
              }
              members_.add(input.readBytes());
              break;
            }
            case 42: {
              org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder subBuilder = null;
              if (((bitField0_ & 0x00000008) == 0x00000008)) {
                subBuilder = avatar_.toBuilder();
              }
              avatar_ = input.readMessage(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.PARSER, extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(avatar_);
                avatar_ = subBuilder.buildPartial();
              }
              bitField0_ |= 0x00000008;
              break;
            }
            case 50: {
              if (!((mutable_bitField0_ & 0x00000020) == 0x00000020)) {
                admins_ = new com.google.protobuf.LazyStringArrayList();
                mutable_bitField0_ |= 0x00000020;
              }
              admins_.add(input.readBytes());
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e.getMessage()).setUnfinishedMessage(this);
      } finally {
        if (((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
          members_ = new com.google.protobuf.UnmodifiableLazyStringList(members_);
        }
        if (((mutable_bitField0_ & 0x00000020) == 0x00000020)) {
          admins_ = new com.google.protobuf.UnmodifiableLazyStringList(admins_);
        }
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_GroupContext_descriptor;
    }

    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_GroupContext_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              org.session.libsignal.protos.SignalServiceProtos.GroupContext.class, org.session.libsignal.protos.SignalServiceProtos.GroupContext.Builder.class);
    }

    public static com.google.protobuf.Parser<GroupContext> PARSER =
        new com.google.protobuf.AbstractParser<GroupContext>() {
      public GroupContext parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new GroupContext(input, extensionRegistry);
      }
    };

    @java.lang.Override
    public com.google.protobuf.Parser<GroupContext> getParserForType() {
      return PARSER;
    }

    /**
     * Protobuf enum {@code signalservice.GroupContext.Type}
     */
    public enum Type
        implements com.google.protobuf.ProtocolMessageEnum {
      /**
       * <code>UNKNOWN = 0;</code>
       */
      UNKNOWN(0, 0),
      /**
       * <code>UPDATE = 1;</code>
       */
      UPDATE(1, 1),
      /**
       * <code>DELIVER = 2;</code>
       */
      DELIVER(2, 2),
      /**
       * <code>QUIT = 3;</code>
       */
      QUIT(3, 3),
      /**
       * <code>REQUEST_INFO = 4;</code>
       */
      REQUEST_INFO(4, 4),
      ;

      /**
       * <code>UNKNOWN = 0;</code>
       */
      public static final int UNKNOWN_VALUE = 0;
      /**
       * <code>UPDATE = 1;</code>
       */
      public static final int UPDATE_VALUE = 1;
      /**
       * <code>DELIVER = 2;</code>
       */
      public static final int DELIVER_VALUE = 2;
      /**
       * <code>QUIT = 3;</code>
       */
      public static final int QUIT_VALUE = 3;
      /**
       * <code>REQUEST_INFO = 4;</code>
       */
      public static final int REQUEST_INFO_VALUE = 4;


      public final int getNumber() { return value; }

      public static Type valueOf(int value) {
        switch (value) {
          case 0: return UNKNOWN;
          case 1: return UPDATE;
          case 2: return DELIVER;
          case 3: return QUIT;
          case 4: return REQUEST_INFO;
          default: return null;
        }
      }

      public static com.google.protobuf.Internal.EnumLiteMap<Type>
          internalGetValueMap() {
        return internalValueMap;
      }
      private static com.google.protobuf.Internal.EnumLiteMap<Type>
          internalValueMap =
            new com.google.protobuf.Internal.EnumLiteMap<Type>() {
              public Type findValueByNumber(int number) {
                return Type.valueOf(number);
              }
            };

      public final com.google.protobuf.Descriptors.EnumValueDescriptor
          getValueDescriptor() {
        return getDescriptor().getValues().get(index);
      }
      public final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptorForType() {
        return getDescriptor();
      }
      public static final com.google.protobuf.Descriptors.EnumDescriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.GroupContext.getDescriptor().getEnumTypes().get(0);
      }

      private static final Type[] VALUES = values();

      public static Type valueOf(
          com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
        if (desc.getType() != getDescriptor()) {
          throw new java.lang.IllegalArgumentException(
            "EnumValueDescriptor is not for this type.");
        }
        return VALUES[desc.getIndex()];
      }

      private final int index;
      private final int value;

      private Type(int index, int value) {
        this.index = index;
        this.value = value;
      }

      // @@protoc_insertion_point(enum_scope:signalservice.GroupContext.Type)
    }

    private int bitField0_;
    // optional bytes id = 1;
    public static final int ID_FIELD_NUMBER = 1;
    private com.google.protobuf.ByteString id_;
    /**
     * <code>optional bytes id = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasId() {
      return ((bitField0_ & 0x00000001) == 0x00000001);
    }
    /**
     * <code>optional bytes id = 1;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public com.google.protobuf.ByteString getId() {
      return id_;
    }

    // optional .signalservice.GroupContext.Type type = 2;
    public static final int TYPE_FIELD_NUMBER = 2;
    private org.session.libsignal.protos.SignalServiceProtos.GroupContext.Type type_;
    /**
     * <code>optional .signalservice.GroupContext.Type type = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public boolean hasType() {
      return ((bitField0_ & 0x00000002) == 0x00000002);
    }
    /**
     * <code>optional .signalservice.GroupContext.Type type = 2;</code>
     *
     * <pre>
     * @required
     * </pre>
     */
    public org.session.libsignal.protos.SignalServiceProtos.GroupContext.Type getType() {
      return type_;
    }

    // optional string name = 3;
    public static final int NAME_FIELD_NUMBER = 3;
    private java.lang.Object name_;
    /**
     * <code>optional string name = 3;</code>
     */
    public boolean hasName() {
      return ((bitField0_ & 0x00000004) == 0x00000004);
    }
    /**
     * <code>optional string name = 3;</code>
     */
    public java.lang.String getName() {
      java.lang.Object ref = name_;
      if (ref instanceof java.lang.String) {
        return (java.lang.String) ref;
      } else {
        com.google.protobuf.ByteString bs = 
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        if (bs.isValidUtf8()) {
          name_ = s;
        }
        return s;
      }
    }
    /**
     * <code>optional string name = 3;</code>
     */
    public com.google.protobuf.ByteString
        getNameBytes() {
      java.lang.Object ref = name_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        name_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    // repeated string members = 4;
    public static final int MEMBERS_FIELD_NUMBER = 4;
    private com.google.protobuf.LazyStringList members_;
    /**
     * <code>repeated string members = 4;</code>
     */
    public java.util.List<java.lang.String>
        getMembersList() {
      return members_;
    }
    /**
     * <code>repeated string members = 4;</code>
     */
    public int getMembersCount() {
      return members_.size();
    }
    /**
     * <code>repeated string members = 4;</code>
     */
    public java.lang.String getMembers(int index) {
      return members_.get(index);
    }
    /**
     * <code>repeated string members = 4;</code>
     */
    public com.google.protobuf.ByteString
        getMembersBytes(int index) {
      return members_.getByteString(index);
    }

    // optional .signalservice.AttachmentPointer avatar = 5;
    public static final int AVATAR_FIELD_NUMBER = 5;
    private org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer avatar_;
    /**
     * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
     */
    public boolean hasAvatar() {
      return ((bitField0_ & 0x00000008) == 0x00000008);
    }
    /**
     * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getAvatar() {
      return avatar_;
    }
    /**
     * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
     */
    public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder getAvatarOrBuilder() {
      return avatar_;
    }

    // repeated string admins = 6;
    public static final int ADMINS_FIELD_NUMBER = 6;
    private com.google.protobuf.LazyStringList admins_;
    /**
     * <code>repeated string admins = 6;</code>
     */
    public java.util.List<java.lang.String>
        getAdminsList() {
      return admins_;
    }
    /**
     * <code>repeated string admins = 6;</code>
     */
    public int getAdminsCount() {
      return admins_.size();
    }
    /**
     * <code>repeated string admins = 6;</code>
     */
    public java.lang.String getAdmins(int index) {
      return admins_.get(index);
    }
    /**
     * <code>repeated string admins = 6;</code>
     */
    public com.google.protobuf.ByteString
        getAdminsBytes(int index) {
      return admins_.getByteString(index);
    }

    private void initFields() {
      id_ = com.google.protobuf.ByteString.EMPTY;
      type_ = org.session.libsignal.protos.SignalServiceProtos.GroupContext.Type.UNKNOWN;
      name_ = "";
      members_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      avatar_ = org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
      admins_ = com.google.protobuf.LazyStringArrayList.EMPTY;
    }
    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized != -1) return isInitialized == 1;

      if (hasAvatar()) {
        if (!getAvatar().isInitialized()) {
          memoizedIsInitialized = 0;
          return false;
        }
      }
      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      getSerializedSize();
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        output.writeBytes(1, id_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        output.writeEnum(2, type_.getNumber());
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        output.writeBytes(3, getNameBytes());
      }
      for (int i = 0; i < members_.size(); i++) {
        output.writeBytes(4, members_.getByteString(i));
      }
      if (((bitField0_ & 0x00000008) == 0x00000008)) {
        output.writeMessage(5, avatar_);
      }
      for (int i = 0; i < admins_.size(); i++) {
        output.writeBytes(6, admins_.getByteString(i));
      }
      getUnknownFields().writeTo(output);
    }

    private int memoizedSerializedSize = -1;
    public int getSerializedSize() {
      int size = memoizedSerializedSize;
      if (size != -1) return size;

      size = 0;
      if (((bitField0_ & 0x00000001) == 0x00000001)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(1, id_);
      }
      if (((bitField0_ & 0x00000002) == 0x00000002)) {
        size += com.google.protobuf.CodedOutputStream
          .computeEnumSize(2, type_.getNumber());
      }
      if (((bitField0_ & 0x00000004) == 0x00000004)) {
        size += com.google.protobuf.CodedOutputStream
          .computeBytesSize(3, getNameBytes());
      }
      {
        int dataSize = 0;
        for (int i = 0; i < members_.size(); i++) {
          dataSize += com.google.protobuf.CodedOutputStream
            .computeBytesSizeNoTag(members_.getByteString(i));
        }
        size += dataSize;
        size += 1 * getMembersList().size();
      }
      if (((bitField0_ & 0x00000008) == 0x00000008)) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(5, avatar_);
      }
      {
        int dataSize = 0;
        for (int i = 0; i < admins_.size(); i++) {
          dataSize += com.google.protobuf.CodedOutputStream
            .computeBytesSizeNoTag(admins_.getByteString(i));
        }
        size += dataSize;
        size += 1 * getAdminsList().size();
      }
      size += getUnknownFields().getSerializedSize();
      memoizedSerializedSize = size;
      return size;
    }

    private static final long serialVersionUID = 0L;
    @java.lang.Override
    protected java.lang.Object writeReplace()
        throws java.io.ObjectStreamException {
      return super.writeReplace();
    }

    public static org.session.libsignal.protos.SignalServiceProtos.GroupContext parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.GroupContext parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.GroupContext parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.GroupContext parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.GroupContext parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.GroupContext parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.GroupContext parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.GroupContext parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseDelimitedFrom(input, extensionRegistry);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.GroupContext parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return PARSER.parseFrom(input);
    }
    public static org.session.libsignal.protos.SignalServiceProtos.GroupContext parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return PARSER.parseFrom(input, extensionRegistry);
    }

    public static Builder newBuilder() { return Builder.create(); }
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder(org.session.libsignal.protos.SignalServiceProtos.GroupContext prototype) {
      return newBuilder().mergeFrom(prototype);
    }
    public Builder toBuilder() { return newBuilder(this); }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * Protobuf type {@code signalservice.GroupContext}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessage.Builder<Builder>
       implements org.session.libsignal.protos.SignalServiceProtos.GroupContextOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_GroupContext_descriptor;
      }

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_GroupContext_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                org.session.libsignal.protos.SignalServiceProtos.GroupContext.class, org.session.libsignal.protos.SignalServiceProtos.GroupContext.Builder.class);
      }

      // Construct using org.session.libsignal.protos.SignalServiceProtos.GroupContext.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessage.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
          getAvatarFieldBuilder();
        }
      }
      private static Builder create() {
        return new Builder();
      }

      public Builder clear() {
        super.clear();
        id_ = com.google.protobuf.ByteString.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000001);
        type_ = org.session.libsignal.protos.SignalServiceProtos.GroupContext.Type.UNKNOWN;
        bitField0_ = (bitField0_ & ~0x00000002);
        name_ = "";
        bitField0_ = (bitField0_ & ~0x00000004);
        members_ = com.google.protobuf.LazyStringArrayList.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000008);
        if (avatarBuilder_ == null) {
          avatar_ = org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
        } else {
          avatarBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000010);
        admins_ = com.google.protobuf.LazyStringArrayList.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000020);
        return this;
      }

      public Builder clone() {
        return create().mergeFrom(buildPartial());
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return org.session.libsignal.protos.SignalServiceProtos.internal_static_signalservice_GroupContext_descriptor;
      }

      public org.session.libsignal.protos.SignalServiceProtos.GroupContext getDefaultInstanceForType() {
        return org.session.libsignal.protos.SignalServiceProtos.GroupContext.getDefaultInstance();
      }

      public org.session.libsignal.protos.SignalServiceProtos.GroupContext build() {
        org.session.libsignal.protos.SignalServiceProtos.GroupContext result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public org.session.libsignal.protos.SignalServiceProtos.GroupContext buildPartial() {
        org.session.libsignal.protos.SignalServiceProtos.GroupContext result = new org.session.libsignal.protos.SignalServiceProtos.GroupContext(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
          to_bitField0_ |= 0x00000001;
        }
        result.id_ = id_;
        if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
          to_bitField0_ |= 0x00000002;
        }
        result.type_ = type_;
        if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
          to_bitField0_ |= 0x00000004;
        }
        result.name_ = name_;
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          members_ = new com.google.protobuf.UnmodifiableLazyStringList(
              members_);
          bitField0_ = (bitField0_ & ~0x00000008);
        }
        result.members_ = members_;
        if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
          to_bitField0_ |= 0x00000008;
        }
        if (avatarBuilder_ == null) {
          result.avatar_ = avatar_;
        } else {
          result.avatar_ = avatarBuilder_.build();
        }
        if (((bitField0_ & 0x00000020) == 0x00000020)) {
          admins_ = new com.google.protobuf.UnmodifiableLazyStringList(
              admins_);
          bitField0_ = (bitField0_ & ~0x00000020);
        }
        result.admins_ = admins_;
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof org.session.libsignal.protos.SignalServiceProtos.GroupContext) {
          return mergeFrom((org.session.libsignal.protos.SignalServiceProtos.GroupContext)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(org.session.libsignal.protos.SignalServiceProtos.GroupContext other) {
        if (other == org.session.libsignal.protos.SignalServiceProtos.GroupContext.getDefaultInstance()) return this;
        if (other.hasId()) {
          setId(other.getId());
        }
        if (other.hasType()) {
          setType(other.getType());
        }
        if (other.hasName()) {
          bitField0_ |= 0x00000004;
          name_ = other.name_;
          onChanged();
        }
        if (!other.members_.isEmpty()) {
          if (members_.isEmpty()) {
            members_ = other.members_;
            bitField0_ = (bitField0_ & ~0x00000008);
          } else {
            ensureMembersIsMutable();
            members_.addAll(other.members_);
          }
          onChanged();
        }
        if (other.hasAvatar()) {
          mergeAvatar(other.getAvatar());
        }
        if (!other.admins_.isEmpty()) {
          if (admins_.isEmpty()) {
            admins_ = other.admins_;
            bitField0_ = (bitField0_ & ~0x00000020);
          } else {
            ensureAdminsIsMutable();
            admins_.addAll(other.admins_);
          }
          onChanged();
        }
        this.mergeUnknownFields(other.getUnknownFields());
        return this;
      }

      public final boolean isInitialized() {
        if (hasAvatar()) {
          if (!getAvatar().isInitialized()) {
            
            return false;
          }
        }
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        org.session.libsignal.protos.SignalServiceProtos.GroupContext parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (org.session.libsignal.protos.SignalServiceProtos.GroupContext) e.getUnfinishedMessage();
          throw e;
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      // optional bytes id = 1;
      private com.google.protobuf.ByteString id_ = com.google.protobuf.ByteString.EMPTY;
      /**
       * <code>optional bytes id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasId() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      /**
       * <code>optional bytes id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public com.google.protobuf.ByteString getId() {
        return id_;
      }
      /**
       * <code>optional bytes id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setId(com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000001;
        id_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional bytes id = 1;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearId() {
        bitField0_ = (bitField0_ & ~0x00000001);
        id_ = getDefaultInstance().getId();
        onChanged();
        return this;
      }

      // optional .signalservice.GroupContext.Type type = 2;
      private org.session.libsignal.protos.SignalServiceProtos.GroupContext.Type type_ = org.session.libsignal.protos.SignalServiceProtos.GroupContext.Type.UNKNOWN;
      /**
       * <code>optional .signalservice.GroupContext.Type type = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public boolean hasType() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      /**
       * <code>optional .signalservice.GroupContext.Type type = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public org.session.libsignal.protos.SignalServiceProtos.GroupContext.Type getType() {
        return type_;
      }
      /**
       * <code>optional .signalservice.GroupContext.Type type = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder setType(org.session.libsignal.protos.SignalServiceProtos.GroupContext.Type value) {
        if (value == null) {
          throw new NullPointerException();
        }
        bitField0_ |= 0x00000002;
        type_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional .signalservice.GroupContext.Type type = 2;</code>
       *
       * <pre>
       * @required
       * </pre>
       */
      public Builder clearType() {
        bitField0_ = (bitField0_ & ~0x00000002);
        type_ = org.session.libsignal.protos.SignalServiceProtos.GroupContext.Type.UNKNOWN;
        onChanged();
        return this;
      }

      // optional string name = 3;
      private java.lang.Object name_ = "";
      /**
       * <code>optional string name = 3;</code>
       */
      public boolean hasName() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      /**
       * <code>optional string name = 3;</code>
       */
      public java.lang.String getName() {
        java.lang.Object ref = name_;
        if (!(ref instanceof java.lang.String)) {
          java.lang.String s = ((com.google.protobuf.ByteString) ref)
              .toStringUtf8();
          name_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <code>optional string name = 3;</code>
       */
      public com.google.protobuf.ByteString
          getNameBytes() {
        java.lang.Object ref = name_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          name_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <code>optional string name = 3;</code>
       */
      public Builder setName(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
        name_ = value;
        onChanged();
        return this;
      }
      /**
       * <code>optional string name = 3;</code>
       */
      public Builder clearName() {
        bitField0_ = (bitField0_ & ~0x00000004);
        name_ = getDefaultInstance().getName();
        onChanged();
        return this;
      }
      /**
       * <code>optional string name = 3;</code>
       */
      public Builder setNameBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  bitField0_ |= 0x00000004;
        name_ = value;
        onChanged();
        return this;
      }

      // repeated string members = 4;
      private com.google.protobuf.LazyStringList members_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      private void ensureMembersIsMutable() {
        if (!((bitField0_ & 0x00000008) == 0x00000008)) {
          members_ = new com.google.protobuf.LazyStringArrayList(members_);
          bitField0_ |= 0x00000008;
         }
      }
      /**
       * <code>repeated string members = 4;</code>
       */
      public java.util.List<java.lang.String>
          getMembersList() {
        return java.util.Collections.unmodifiableList(members_);
      }
      /**
       * <code>repeated string members = 4;</code>
       */
      public int getMembersCount() {
        return members_.size();
      }
      /**
       * <code>repeated string members = 4;</code>
       */
      public java.lang.String getMembers(int index) {
        return members_.get(index);
      }
      /**
       * <code>repeated string members = 4;</code>
       */
      public com.google.protobuf.ByteString
          getMembersBytes(int index) {
        return members_.getByteString(index);
      }
      /**
       * <code>repeated string members = 4;</code>
       */
      public Builder setMembers(
          int index, java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureMembersIsMutable();
        members_.set(index, value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string members = 4;</code>
       */
      public Builder addMembers(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureMembersIsMutable();
        members_.add(value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string members = 4;</code>
       */
      public Builder addAllMembers(
          java.lang.Iterable<java.lang.String> values) {
        ensureMembersIsMutable();
        super.addAll(values, members_);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string members = 4;</code>
       */
      public Builder clearMembers() {
        members_ = com.google.protobuf.LazyStringArrayList.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000008);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string members = 4;</code>
       */
      public Builder addMembersBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureMembersIsMutable();
        members_.add(value);
        onChanged();
        return this;
      }

      // optional .signalservice.AttachmentPointer avatar = 5;
      private org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer avatar_ = org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder> avatarBuilder_;
      /**
       * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
       */
      public boolean hasAvatar() {
        return ((bitField0_ & 0x00000010) == 0x00000010);
      }
      /**
       * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer getAvatar() {
        if (avatarBuilder_ == null) {
          return avatar_;
        } else {
          return avatarBuilder_.getMessage();
        }
      }
      /**
       * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
       */
      public Builder setAvatar(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer value) {
        if (avatarBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          avatar_ = value;
          onChanged();
        } else {
          avatarBuilder_.setMessage(value);
        }
        bitField0_ |= 0x00000010;
        return this;
      }
      /**
       * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
       */
      public Builder setAvatar(
          org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder builderForValue) {
        if (avatarBuilder_ == null) {
          avatar_ = builderForValue.build();
          onChanged();
        } else {
          avatarBuilder_.setMessage(builderForValue.build());
        }
        bitField0_ |= 0x00000010;
        return this;
      }
      /**
       * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
       */
      public Builder mergeAvatar(org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer value) {
        if (avatarBuilder_ == null) {
          if (((bitField0_ & 0x00000010) == 0x00000010) &&
              avatar_ != org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance()) {
            avatar_ =
              org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.newBuilder(avatar_).mergeFrom(value).buildPartial();
          } else {
            avatar_ = value;
          }
          onChanged();
        } else {
          avatarBuilder_.mergeFrom(value);
        }
        bitField0_ |= 0x00000010;
        return this;
      }
      /**
       * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
       */
      public Builder clearAvatar() {
        if (avatarBuilder_ == null) {
          avatar_ = org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.getDefaultInstance();
          onChanged();
        } else {
          avatarBuilder_.clear();
        }
        bitField0_ = (bitField0_ & ~0x00000010);
        return this;
      }
      /**
       * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder getAvatarBuilder() {
        bitField0_ |= 0x00000010;
        onChanged();
        return getAvatarFieldBuilder().getBuilder();
      }
      /**
       * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
       */
      public org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder getAvatarOrBuilder() {
        if (avatarBuilder_ != null) {
          return avatarBuilder_.getMessageOrBuilder();
        } else {
          return avatar_;
        }
      }
      /**
       * <code>optional .signalservice.AttachmentPointer avatar = 5;</code>
       */
      private com.google.protobuf.SingleFieldBuilder<
          org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder> 
          getAvatarFieldBuilder() {
        if (avatarBuilder_ == null) {
          avatarBuilder_ = new com.google.protobuf.SingleFieldBuilder<
              org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointer.Builder, org.session.libsignal.protos.SignalServiceProtos.AttachmentPointerOrBuilder>(
                  avatar_,
                  getParentForChildren(),
                  isClean());
          avatar_ = null;
        }
        return avatarBuilder_;
      }

      // repeated string admins = 6;
      private com.google.protobuf.LazyStringList admins_ = com.google.protobuf.LazyStringArrayList.EMPTY;
      private void ensureAdminsIsMutable() {
        if (!((bitField0_ & 0x00000020) == 0x00000020)) {
          admins_ = new com.google.protobuf.LazyStringArrayList(admins_);
          bitField0_ |= 0x00000020;
         }
      }
      /**
       * <code>repeated string admins = 6;</code>
       */
      public java.util.List<java.lang.String>
          getAdminsList() {
        return java.util.Collections.unmodifiableList(admins_);
      }
      /**
       * <code>repeated string admins = 6;</code>
       */
      public int getAdminsCount() {
        return admins_.size();
      }
      /**
       * <code>repeated string admins = 6;</code>
       */
      public java.lang.String getAdmins(int index) {
        return admins_.get(index);
      }
      /**
       * <code>repeated string admins = 6;</code>
       */
      public com.google.protobuf.ByteString
          getAdminsBytes(int index) {
        return admins_.getByteString(index);
      }
      /**
       * <code>repeated string admins = 6;</code>
       */
      public Builder setAdmins(
          int index, java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureAdminsIsMutable();
        admins_.set(index, value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string admins = 6;</code>
       */
      public Builder addAdmins(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureAdminsIsMutable();
        admins_.add(value);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string admins = 6;</code>
       */
      public Builder addAllAdmins(
          java.lang.Iterable<java.lang.String> values) {
        ensureAdminsIsMutable();
        super.addAll(values, admins_);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string admins = 6;</code>
       */
      public Builder clearAdmins() {
        admins_ = com.google.protobuf.LazyStringArrayList.EMPTY;
        bitField0_ = (bitField0_ & ~0x00000020);
        onChanged();
        return this;
      }
      /**
       * <code>repeated string admins = 6;</code>
       */
      public Builder addAdminsBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  ensureAdminsIsMutable();
        admins_.add(value);
        onChanged();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:signalservice.GroupContext)
    }

    static {
      defaultInstance = new GroupContext(true);
      defaultInstance.initFields();
    }

    // @@protoc_insertion_point(class_scope:signalservice.GroupContext)
  }

  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_Envelope_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_Envelope_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_TypingMessage_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_TypingMessage_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_UnsendRequest_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_UnsendRequest_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_Content_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_Content_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_KeyPair_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_KeyPair_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_DataExtractionNotification_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_DataExtractionNotification_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_DataMessage_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_DataMessage_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_DataMessage_Quote_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_DataMessage_Quote_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_DataMessage_Quote_QuotedAttachment_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_DataMessage_Quote_QuotedAttachment_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_DataMessage_Preview_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_DataMessage_Preview_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_DataMessage_LokiProfile_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_DataMessage_LokiProfile_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_DataMessage_OpenGroupInvitation_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_DataMessage_OpenGroupInvitation_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_DataMessage_ClosedGroupControlMessage_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_DataMessage_ClosedGroupControlMessage_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_DataMessage_ClosedGroupControlMessage_KeyPairWrapper_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_DataMessage_ClosedGroupControlMessage_KeyPairWrapper_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_DataMessage_Reaction_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_DataMessage_Reaction_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_CallMessage_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_CallMessage_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_ConfigurationMessage_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_ConfigurationMessage_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_ConfigurationMessage_ClosedGroup_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_ConfigurationMessage_ClosedGroup_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_ConfigurationMessage_Contact_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_ConfigurationMessage_Contact_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_MessageRequestResponse_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_MessageRequestResponse_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_ReceiptMessage_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_ReceiptMessage_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_AttachmentPointer_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_AttachmentPointer_fieldAccessorTable;
  private static com.google.protobuf.Descriptors.Descriptor
    internal_static_signalservice_GroupContext_descriptor;
  private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internal_static_signalservice_GroupContext_fieldAccessorTable;

  public static com.google.protobuf.Descriptors.FileDescriptor
      getDescriptor() {
    return descriptor;
  }
  private static com.google.protobuf.Descriptors.FileDescriptor
      descriptor;
  static {
    java.lang.String[] descriptorData = {
      "\n\023SignalService.proto\022\rsignalservice\"\320\001\n" +
      "\010Envelope\022*\n\004type\030\001 \002(\0162\034.signalservice." +
      "Envelope.Type\022\016\n\006source\030\002 \001(\t\022\024\n\014sourceD" +
      "evice\030\007 \001(\r\022\021\n\ttimestamp\030\005 \002(\004\022\017\n\007conten" +
      "t\030\010 \001(\014\022\027\n\017serverTimestamp\030\n \001(\004\"5\n\004Type" +
      "\022\023\n\017SESSION_MESSAGE\020\006\022\030\n\024CLOSED_GROUP_ME" +
      "SSAGE\020\007\"{\n\rTypingMessage\022\021\n\ttimestamp\030\001 " +
      "\002(\004\0223\n\006action\030\002 \002(\0162#.signalservice.Typi" +
      "ngMessage.Action\"\"\n\006Action\022\013\n\007STARTED\020\000\022" +
      "\013\n\007STOPPED\020\001\"2\n\rUnsendRequest\022\021\n\ttimesta",
      "mp\030\001 \002(\004\022\016\n\006author\030\002 \002(\t\"\345\003\n\007Content\022/\n\013" +
      "dataMessage\030\001 \001(\0132\032.signalservice.DataMe" +
      "ssage\022/\n\013callMessage\030\003 \001(\0132\032.signalservi" +
      "ce.CallMessage\0225\n\016receiptMessage\030\005 \001(\0132\035" +
      ".signalservice.ReceiptMessage\0223\n\rtypingM" +
      "essage\030\006 \001(\0132\034.signalservice.TypingMessa" +
      "ge\022A\n\024configurationMessage\030\007 \001(\0132#.signa" +
      "lservice.ConfigurationMessage\022M\n\032dataExt" +
      "ractionNotification\030\010 \001(\0132).signalservic" +
      "e.DataExtractionNotification\0223\n\runsendRe",
      "quest\030\t \001(\0132\034.signalservice.UnsendReques" +
      "t\022E\n\026messageRequestResponse\030\n \001(\0132%.sign" +
      "alservice.MessageRequestResponse\"0\n\007KeyP" +
      "air\022\021\n\tpublicKey\030\001 \002(\014\022\022\n\nprivateKey\030\002 \002" +
      "(\014\"\226\001\n\032DataExtractionNotification\022<\n\004typ" +
      "e\030\001 \002(\0162..signalservice.DataExtractionNo" +
      "tification.Type\022\021\n\ttimestamp\030\002 \001(\004\"\'\n\004Ty" +
      "pe\022\016\n\nSCREENSHOT\020\001\022\017\n\013MEDIA_SAVED\020\002\"\361\r\n\013" +
      "DataMessage\022\014\n\004body\030\001 \001(\t\0225\n\013attachments" +
      "\030\002 \003(\0132 .signalservice.AttachmentPointer",
      "\022*\n\005group\030\003 \001(\0132\033.signalservice.GroupCon" +
      "text\022\r\n\005flags\030\004 \001(\r\022\023\n\013expireTimer\030\005 \001(\r" +
      "\022\022\n\nprofileKey\030\006 \001(\014\022\021\n\ttimestamp\030\007 \001(\004\022" +
      "/\n\005quote\030\010 \001(\0132 .signalservice.DataMessa" +
      "ge.Quote\0223\n\007preview\030\n \003(\0132\".signalservic" +
      "e.DataMessage.Preview\0225\n\010reaction\030\013 \001(\0132" +
      "#.signalservice.DataMessage.Reaction\0227\n\007" +
      "profile\030e \001(\0132&.signalservice.DataMessag" +
      "e.LokiProfile\022K\n\023openGroupInvitation\030f \001" +
      "(\0132..signalservice.DataMessage.OpenGroup",
      "Invitation\022W\n\031closedGroupControlMessage\030" +
      "h \001(\01324.signalservice.DataMessage.Closed" +
      "GroupControlMessage\022\022\n\nsyncTarget\030i \001(\t\032" +
      "\225\002\n\005Quote\022\n\n\002id\030\001 \002(\004\022\016\n\006author\030\002 \002(\t\022\014\n" +
      "\004text\030\003 \001(\t\022F\n\013attachments\030\004 \003(\01321.signa" +
      "lservice.DataMessage.Quote.QuotedAttachm" +
      "ent\032\231\001\n\020QuotedAttachment\022\023\n\013contentType\030" +
      "\001 \001(\t\022\020\n\010fileName\030\002 \001(\t\0223\n\tthumbnail\030\003 \001" +
      "(\0132 .signalservice.AttachmentPointer\022\r\n\005" +
      "flags\030\004 \001(\r\"\032\n\005Flags\022\021\n\rVOICE_MESSAGE\020\001\032",
      "V\n\007Preview\022\013\n\003url\030\001 \002(\t\022\r\n\005title\030\002 \001(\t\022/" +
      "\n\005image\030\003 \001(\0132 .signalservice.Attachment" +
      "Pointer\032:\n\013LokiProfile\022\023\n\013displayName\030\001 " +
      "\001(\t\022\026\n\016profilePicture\030\002 \001(\t\0320\n\023OpenGroup" +
      "Invitation\022\013\n\003url\030\001 \002(\t\022\014\n\004name\030\003 \002(\t\032\374\003" +
      "\n\031ClosedGroupControlMessage\022G\n\004type\030\001 \002(" +
      "\01629.signalservice.DataMessage.ClosedGrou" +
      "pControlMessage.Type\022\021\n\tpublicKey\030\002 \001(\014\022" +
      "\014\n\004name\030\003 \001(\t\0221\n\021encryptionKeyPair\030\004 \001(\013" +
      "2\026.signalservice.KeyPair\022\017\n\007members\030\005 \003(",
      "\014\022\016\n\006admins\030\006 \003(\014\022U\n\010wrappers\030\007 \003(\0132C.si" +
      "gnalservice.DataMessage.ClosedGroupContr" +
      "olMessage.KeyPairWrapper\022\027\n\017expirationTi" +
      "mer\030\010 \001(\r\032=\n\016KeyPairWrapper\022\021\n\tpublicKey" +
      "\030\001 \002(\014\022\030\n\020encryptedKeyPair\030\002 \002(\014\"r\n\004Type" +
      "\022\007\n\003NEW\020\001\022\027\n\023ENCRYPTION_KEY_PAIR\020\003\022\017\n\013NA" +
      "ME_CHANGE\020\004\022\021\n\rMEMBERS_ADDED\020\005\022\023\n\017MEMBER" +
      "S_REMOVED\020\006\022\017\n\013MEMBER_LEFT\020\007\032\222\001\n\010Reactio" +
      "n\022\n\n\002id\030\001 \002(\004\022\016\n\006author\030\002 \002(\t\022\r\n\005emoji\030\003" +
      " \001(\t\022:\n\006action\030\004 \002(\0162*.signalservice.Dat",
      "aMessage.Reaction.Action\"\037\n\006Action\022\t\n\005RE" +
      "ACT\020\000\022\n\n\006REMOVE\020\001\"$\n\005Flags\022\033\n\027EXPIRATION" +
      "_TIMER_UPDATE\020\002\"\352\001\n\013CallMessage\022-\n\004type\030" +
      "\001 \002(\0162\037.signalservice.CallMessage.Type\022\014" +
      "\n\004sdps\030\002 \003(\t\022\027\n\017sdpMLineIndexes\030\003 \003(\r\022\017\n" +
      "\007sdpMids\030\004 \003(\t\022\014\n\004uuid\030\005 \002(\t\"f\n\004Type\022\r\n\t" +
      "PRE_OFFER\020\006\022\t\n\005OFFER\020\001\022\n\n\006ANSWER\020\002\022\026\n\022PR" +
      "OVISIONAL_ANSWER\020\003\022\022\n\016ICE_CANDIDATES\020\004\022\014" +
      "\n\010END_CALL\020\005\"\245\004\n\024ConfigurationMessage\022E\n" +
      "\014closedGroups\030\001 \003(\0132/.signalservice.Conf",
      "igurationMessage.ClosedGroup\022\022\n\nopenGrou" +
      "ps\030\002 \003(\t\022\023\n\013displayName\030\003 \001(\t\022\026\n\016profile" +
      "Picture\030\004 \001(\t\022\022\n\nprofileKey\030\005 \001(\014\022=\n\010con" +
      "tacts\030\006 \003(\0132+.signalservice.Configuratio" +
      "nMessage.Contact\032\233\001\n\013ClosedGroup\022\021\n\tpubl" +
      "icKey\030\001 \001(\014\022\014\n\004name\030\002 \001(\t\0221\n\021encryptionK" +
      "eyPair\030\003 \001(\0132\026.signalservice.KeyPair\022\017\n\007" +
      "members\030\004 \003(\014\022\016\n\006admins\030\005 \003(\014\022\027\n\017expirat" +
      "ionTimer\030\006 \001(\r\032\223\001\n\007Contact\022\021\n\tpublicKey\030" +
      "\001 \002(\014\022\014\n\004name\030\002 \002(\t\022\026\n\016profilePicture\030\003 ",
      "\001(\t\022\022\n\nprofileKey\030\004 \001(\014\022\022\n\nisApproved\030\005 " +
      "\001(\010\022\021\n\tisBlocked\030\006 \001(\010\022\024\n\014didApproveMe\030\007" +
      " \001(\010\"y\n\026MessageRequestResponse\022\022\n\nisAppr" +
      "oved\030\001 \002(\010\022\022\n\nprofileKey\030\002 \001(\014\0227\n\007profil" +
      "e\030\003 \001(\0132&.signalservice.DataMessage.Loki" +
      "Profile\"u\n\016ReceiptMessage\0220\n\004type\030\001 \002(\0162" +
      "\".signalservice.ReceiptMessage.Type\022\021\n\tt" +
      "imestamp\030\002 \003(\004\"\036\n\004Type\022\014\n\010DELIVERY\020\000\022\010\n\004" +
      "READ\020\001\"\354\001\n\021AttachmentPointer\022\n\n\002id\030\001 \002(\006" +
      "\022\023\n\013contentType\030\002 \001(\t\022\013\n\003key\030\003 \001(\014\022\014\n\004si",
      "ze\030\004 \001(\r\022\021\n\tthumbnail\030\005 \001(\014\022\016\n\006digest\030\006 " +
      "\001(\014\022\020\n\010fileName\030\007 \001(\t\022\r\n\005flags\030\010 \001(\r\022\r\n\005" +
      "width\030\t \001(\r\022\016\n\006height\030\n \001(\r\022\017\n\007caption\030\013" +
      " \001(\t\022\013\n\003url\030e \001(\t\"\032\n\005Flags\022\021\n\rVOICE_MESS" +
      "AGE\020\001\"\365\001\n\014GroupContext\022\n\n\002id\030\001 \001(\014\022.\n\004ty" +
      "pe\030\002 \001(\0162 .signalservice.GroupContext.Ty" +
      "pe\022\014\n\004name\030\003 \001(\t\022\017\n\007members\030\004 \003(\t\0220\n\006ava" +
      "tar\030\005 \001(\0132 .signalservice.AttachmentPoin" +
      "ter\022\016\n\006admins\030\006 \003(\t\"H\n\004Type\022\013\n\007UNKNOWN\020\000" +
      "\022\n\n\006UPDATE\020\001\022\013\n\007DELIVER\020\002\022\010\n\004QUIT\020\003\022\020\n\014R",
      "EQUEST_INFO\020\004B3\n\034org.session.libsignal.p" +
      "rotosB\023SignalServiceProtos"
    };
    com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
      new com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner() {
        public com.google.protobuf.ExtensionRegistry assignDescriptors(
            com.google.protobuf.Descriptors.FileDescriptor root) {
          descriptor = root;
          internal_static_signalservice_Envelope_descriptor =
            getDescriptor().getMessageTypes().get(0);
          internal_static_signalservice_Envelope_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_Envelope_descriptor,
              new java.lang.String[] { "Type", "Source", "SourceDevice", "Timestamp", "Content", "ServerTimestamp", });
          internal_static_signalservice_TypingMessage_descriptor =
            getDescriptor().getMessageTypes().get(1);
          internal_static_signalservice_TypingMessage_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_TypingMessage_descriptor,
              new java.lang.String[] { "Timestamp", "Action", });
          internal_static_signalservice_UnsendRequest_descriptor =
            getDescriptor().getMessageTypes().get(2);
          internal_static_signalservice_UnsendRequest_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_UnsendRequest_descriptor,
              new java.lang.String[] { "Timestamp", "Author", });
          internal_static_signalservice_Content_descriptor =
            getDescriptor().getMessageTypes().get(3);
          internal_static_signalservice_Content_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_Content_descriptor,
              new java.lang.String[] { "DataMessage", "CallMessage", "ReceiptMessage", "TypingMessage", "ConfigurationMessage", "DataExtractionNotification", "UnsendRequest", "MessageRequestResponse", });
          internal_static_signalservice_KeyPair_descriptor =
            getDescriptor().getMessageTypes().get(4);
          internal_static_signalservice_KeyPair_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_KeyPair_descriptor,
              new java.lang.String[] { "PublicKey", "PrivateKey", });
          internal_static_signalservice_DataExtractionNotification_descriptor =
            getDescriptor().getMessageTypes().get(5);
          internal_static_signalservice_DataExtractionNotification_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_DataExtractionNotification_descriptor,
              new java.lang.String[] { "Type", "Timestamp", });
          internal_static_signalservice_DataMessage_descriptor =
            getDescriptor().getMessageTypes().get(6);
          internal_static_signalservice_DataMessage_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_DataMessage_descriptor,
              new java.lang.String[] { "Body", "Attachments", "Group", "Flags", "ExpireTimer", "ProfileKey", "Timestamp", "Quote", "Preview", "Reaction", "Profile", "OpenGroupInvitation", "ClosedGroupControlMessage", "SyncTarget", });
          internal_static_signalservice_DataMessage_Quote_descriptor =
            internal_static_signalservice_DataMessage_descriptor.getNestedTypes().get(0);
          internal_static_signalservice_DataMessage_Quote_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_DataMessage_Quote_descriptor,
              new java.lang.String[] { "Id", "Author", "Text", "Attachments", });
          internal_static_signalservice_DataMessage_Quote_QuotedAttachment_descriptor =
            internal_static_signalservice_DataMessage_Quote_descriptor.getNestedTypes().get(0);
          internal_static_signalservice_DataMessage_Quote_QuotedAttachment_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_DataMessage_Quote_QuotedAttachment_descriptor,
              new java.lang.String[] { "ContentType", "FileName", "Thumbnail", "Flags", });
          internal_static_signalservice_DataMessage_Preview_descriptor =
            internal_static_signalservice_DataMessage_descriptor.getNestedTypes().get(1);
          internal_static_signalservice_DataMessage_Preview_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_DataMessage_Preview_descriptor,
              new java.lang.String[] { "Url", "Title", "Image", });
          internal_static_signalservice_DataMessage_LokiProfile_descriptor =
            internal_static_signalservice_DataMessage_descriptor.getNestedTypes().get(2);
          internal_static_signalservice_DataMessage_LokiProfile_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_DataMessage_LokiProfile_descriptor,
              new java.lang.String[] { "DisplayName", "ProfilePicture", });
          internal_static_signalservice_DataMessage_OpenGroupInvitation_descriptor =
            internal_static_signalservice_DataMessage_descriptor.getNestedTypes().get(3);
          internal_static_signalservice_DataMessage_OpenGroupInvitation_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_DataMessage_OpenGroupInvitation_descriptor,
              new java.lang.String[] { "Url", "Name", });
          internal_static_signalservice_DataMessage_ClosedGroupControlMessage_descriptor =
            internal_static_signalservice_DataMessage_descriptor.getNestedTypes().get(4);
          internal_static_signalservice_DataMessage_ClosedGroupControlMessage_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_DataMessage_ClosedGroupControlMessage_descriptor,
              new java.lang.String[] { "Type", "PublicKey", "Name", "EncryptionKeyPair", "Members", "Admins", "Wrappers", "ExpirationTimer", });
          internal_static_signalservice_DataMessage_ClosedGroupControlMessage_KeyPairWrapper_descriptor =
            internal_static_signalservice_DataMessage_ClosedGroupControlMessage_descriptor.getNestedTypes().get(0);
          internal_static_signalservice_DataMessage_ClosedGroupControlMessage_KeyPairWrapper_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_DataMessage_ClosedGroupControlMessage_KeyPairWrapper_descriptor,
              new java.lang.String[] { "PublicKey", "EncryptedKeyPair", });
          internal_static_signalservice_DataMessage_Reaction_descriptor =
            internal_static_signalservice_DataMessage_descriptor.getNestedTypes().get(5);
          internal_static_signalservice_DataMessage_Reaction_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_DataMessage_Reaction_descriptor,
              new java.lang.String[] { "Id", "Author", "Emoji", "Action", });
          internal_static_signalservice_CallMessage_descriptor =
            getDescriptor().getMessageTypes().get(7);
          internal_static_signalservice_CallMessage_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_CallMessage_descriptor,
              new java.lang.String[] { "Type", "Sdps", "SdpMLineIndexes", "SdpMids", "Uuid", });
          internal_static_signalservice_ConfigurationMessage_descriptor =
            getDescriptor().getMessageTypes().get(8);
          internal_static_signalservice_ConfigurationMessage_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_ConfigurationMessage_descriptor,
              new java.lang.String[] { "ClosedGroups", "OpenGroups", "DisplayName", "ProfilePicture", "ProfileKey", "Contacts", });
          internal_static_signalservice_ConfigurationMessage_ClosedGroup_descriptor =
            internal_static_signalservice_ConfigurationMessage_descriptor.getNestedTypes().get(0);
          internal_static_signalservice_ConfigurationMessage_ClosedGroup_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_ConfigurationMessage_ClosedGroup_descriptor,
              new java.lang.String[] { "PublicKey", "Name", "EncryptionKeyPair", "Members", "Admins", "ExpirationTimer", });
          internal_static_signalservice_ConfigurationMessage_Contact_descriptor =
            internal_static_signalservice_ConfigurationMessage_descriptor.getNestedTypes().get(1);
          internal_static_signalservice_ConfigurationMessage_Contact_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_ConfigurationMessage_Contact_descriptor,
              new java.lang.String[] { "PublicKey", "Name", "ProfilePicture", "ProfileKey", "IsApproved", "IsBlocked", "DidApproveMe", });
          internal_static_signalservice_MessageRequestResponse_descriptor =
            getDescriptor().getMessageTypes().get(9);
          internal_static_signalservice_MessageRequestResponse_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_MessageRequestResponse_descriptor,
              new java.lang.String[] { "IsApproved", "ProfileKey", "Profile", });
          internal_static_signalservice_ReceiptMessage_descriptor =
            getDescriptor().getMessageTypes().get(10);
          internal_static_signalservice_ReceiptMessage_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_ReceiptMessage_descriptor,
              new java.lang.String[] { "Type", "Timestamp", });
          internal_static_signalservice_AttachmentPointer_descriptor =
            getDescriptor().getMessageTypes().get(11);
          internal_static_signalservice_AttachmentPointer_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_AttachmentPointer_descriptor,
              new java.lang.String[] { "Id", "ContentType", "Key", "Size", "Thumbnail", "Digest", "FileName", "Flags", "Width", "Height", "Caption", "Url", });
          internal_static_signalservice_GroupContext_descriptor =
            getDescriptor().getMessageTypes().get(12);
          internal_static_signalservice_GroupContext_fieldAccessorTable = new
            com.google.protobuf.GeneratedMessage.FieldAccessorTable(
              internal_static_signalservice_GroupContext_descriptor,
              new java.lang.String[] { "Id", "Type", "Name", "Members", "Avatar", "Admins", });
          return null;
        }
      };
    com.google.protobuf.Descriptors.FileDescriptor
      .internalBuildGeneratedFileFrom(descriptorData,
        new com.google.protobuf.Descriptors.FileDescriptor[] {
        }, assigner);
  }

  // @@protoc_insertion_point(outer_class_scope)
}
