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

package com.ywt.gapi.third.taihe;

/**
 * <pre>
 *病历
 * </pre>
 *
 * Protobuf type {@code com.ywt.gapi.third.taihe.MedicalRecord}
 */
public final class MedicalRecord extends
    com.google.protobuf.GeneratedMessageV3 implements
    // @@protoc_insertion_point(message_implements:com.ywt.gapi.third.taihe.MedicalRecord)
    MedicalRecordOrBuilder {
private static final long serialVersionUID = 0L;
  // Use MedicalRecord.newBuilder() to construct.
  private MedicalRecord(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
    super(builder);
  }
  private MedicalRecord() {
    doctorName_ = "";
    registrationDate_ = "";
    medicalCardNo_ = "";
    doctorAdvice_ = "";
    deptName_ = "";
    checkInTime_ = "";
    chiefComplaint_ = "";
    physicalExam_ = "";
    diagnose_ = "";
    suggestion_ = "";
  }

  @java.lang.Override
  @SuppressWarnings({"unused"})
  protected java.lang.Object newInstance(
      UnusedPrivateParameter unused) {
    return new MedicalRecord();
  }

  @java.lang.Override
  public final com.google.protobuf.UnknownFieldSet
  getUnknownFields() {
    return this.unknownFields;
  }
  private MedicalRecord(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    this();
    if (extensionRegistry == null) {
      throw new java.lang.NullPointerException();
    }
    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;
          case 10: {
            com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.Builder subBuilder = null;
            if (patInfo_ != null) {
              subBuilder = patInfo_.toBuilder();
            }
            patInfo_ = input.readMessage(com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.parser(), extensionRegistry);
            if (subBuilder != null) {
              subBuilder.mergeFrom(patInfo_);
              patInfo_ = subBuilder.buildPartial();
            }

            break;
          }
          case 18: {
            java.lang.String s = input.readStringRequireUtf8();

            doctorName_ = s;
            break;
          }
          case 26: {
            java.lang.String s = input.readStringRequireUtf8();

            registrationDate_ = s;
            break;
          }
          case 34: {
            java.lang.String s = input.readStringRequireUtf8();

            medicalCardNo_ = s;
            break;
          }
          case 42: {
            java.lang.String s = input.readStringRequireUtf8();

            doctorAdvice_ = s;
            break;
          }
          case 50: {
            java.lang.String s = input.readStringRequireUtf8();

            deptName_ = s;
            break;
          }
          case 58: {
            java.lang.String s = input.readStringRequireUtf8();

            checkInTime_ = s;
            break;
          }
          case 66: {
            java.lang.String s = input.readStringRequireUtf8();

            chiefComplaint_ = s;
            break;
          }
          case 74: {
            java.lang.String s = input.readStringRequireUtf8();

            physicalExam_ = s;
            break;
          }
          case 82: {
            java.lang.String s = input.readStringRequireUtf8();

            diagnose_ = s;
            break;
          }
          case 90: {
            java.lang.String s = input.readStringRequireUtf8();

            suggestion_ = s;
            break;
          }
          default: {
            if (!parseUnknownField(
                input, unknownFields, extensionRegistry, tag)) {
              done = true;
            }
            break;
          }
        }
      }
    } catch (com.google.protobuf.InvalidProtocolBufferException e) {
      throw e.setUnfinishedMessage(this);
    } catch (java.io.IOException e) {
      throw new com.google.protobuf.InvalidProtocolBufferException(
          e).setUnfinishedMessage(this);
    } finally {
      this.unknownFields = unknownFields.build();
      makeExtensionsImmutable();
    }
  }
  public static final com.google.protobuf.Descriptors.Descriptor
      getDescriptor() {
    return com.ywt.gapi.third.taihe.TaiheProto.internal_static_com_ywt_gapi_third_taihe_MedicalRecord_descriptor;
  }

  @java.lang.Override
  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return com.ywt.gapi.third.taihe.TaiheProto.internal_static_com_ywt_gapi_third_taihe_MedicalRecord_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            com.ywt.gapi.third.taihe.MedicalRecord.class, com.ywt.gapi.third.taihe.MedicalRecord.Builder.class);
  }

  public interface PatInfoOrBuilder extends
      // @@protoc_insertion_point(interface_extends:com.ywt.gapi.third.taihe.MedicalRecord.PatInfo)
      com.google.protobuf.MessageOrBuilder {

    /**
     * <pre>
     *患者姓名
     * </pre>
     *
     * <code>string patName = 1;</code>
     * @return The patName.
     */
    java.lang.String getPatName();
    /**
     * <pre>
     *患者姓名
     * </pre>
     *
     * <code>string patName = 1;</code>
     * @return The bytes for patName.
     */
    com.google.protobuf.ByteString
        getPatNameBytes();

    /**
     * <pre>
     *年龄
     * </pre>
     *
     * <code>int32 age = 2;</code>
     * @return The age.
     */
    int getAge();

    /**
     * <pre>
     *性别
     * </pre>
     *
     * <code>int32 sex = 3;</code>
     * @return The sex.
     */
    int getSex();

    /**
     * <pre>
     *民族
     * </pre>
     *
     * <code>string nation = 4;</code>
     * @return The nation.
     */
    java.lang.String getNation();
    /**
     * <pre>
     *民族
     * </pre>
     *
     * <code>string nation = 4;</code>
     * @return The bytes for nation.
     */
    com.google.protobuf.ByteString
        getNationBytes();

    /**
     * <pre>
     *住址
     * </pre>
     *
     * <code>string address = 5;</code>
     * @return The address.
     */
    java.lang.String getAddress();
    /**
     * <pre>
     *住址
     * </pre>
     *
     * <code>string address = 5;</code>
     * @return The bytes for address.
     */
    com.google.protobuf.ByteString
        getAddressBytes();

    /**
     * <pre>
     *电话号码
     * </pre>
     *
     * <code>string phoneNumber = 6;</code>
     * @return The phoneNumber.
     */
    java.lang.String getPhoneNumber();
    /**
     * <pre>
     *电话号码
     * </pre>
     *
     * <code>string phoneNumber = 6;</code>
     * @return The bytes for phoneNumber.
     */
    com.google.protobuf.ByteString
        getPhoneNumberBytes();
  }
  /**
   * <pre>
   *患者信息
   * </pre>
   *
   * Protobuf type {@code com.ywt.gapi.third.taihe.MedicalRecord.PatInfo}
   */
  public static final class PatInfo extends
      com.google.protobuf.GeneratedMessageV3 implements
      // @@protoc_insertion_point(message_implements:com.ywt.gapi.third.taihe.MedicalRecord.PatInfo)
      PatInfoOrBuilder {
  private static final long serialVersionUID = 0L;
    // Use PatInfo.newBuilder() to construct.
    private PatInfo(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
      super(builder);
    }
    private PatInfo() {
      patName_ = "";
      nation_ = "";
      address_ = "";
      phoneNumber_ = "";
    }

    @java.lang.Override
    @SuppressWarnings({"unused"})
    protected java.lang.Object newInstance(
        UnusedPrivateParameter unused) {
      return new PatInfo();
    }

    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
    getUnknownFields() {
      return this.unknownFields;
    }
    private PatInfo(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      this();
      if (extensionRegistry == null) {
        throw new java.lang.NullPointerException();
      }
      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;
            case 10: {
              java.lang.String s = input.readStringRequireUtf8();

              patName_ = s;
              break;
            }
            case 16: {

              age_ = input.readInt32();
              break;
            }
            case 24: {

              sex_ = input.readInt32();
              break;
            }
            case 34: {
              java.lang.String s = input.readStringRequireUtf8();

              nation_ = s;
              break;
            }
            case 42: {
              java.lang.String s = input.readStringRequireUtf8();

              address_ = s;
              break;
            }
            case 50: {
              java.lang.String s = input.readStringRequireUtf8();

              phoneNumber_ = s;
              break;
            }
            default: {
              if (!parseUnknownField(
                  input, unknownFields, extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e).setUnfinishedMessage(this);
      } finally {
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return com.ywt.gapi.third.taihe.TaiheProto.internal_static_com_ywt_gapi_third_taihe_MedicalRecord_PatInfo_descriptor;
    }

    @java.lang.Override
    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.ywt.gapi.third.taihe.TaiheProto.internal_static_com_ywt_gapi_third_taihe_MedicalRecord_PatInfo_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.class, com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.Builder.class);
    }

    public static final int PATNAME_FIELD_NUMBER = 1;
    private volatile java.lang.Object patName_;
    /**
     * <pre>
     *患者姓名
     * </pre>
     *
     * <code>string patName = 1;</code>
     * @return The patName.
     */
    @java.lang.Override
    public java.lang.String getPatName() {
      java.lang.Object ref = patName_;
      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();
        patName_ = s;
        return s;
      }
    }
    /**
     * <pre>
     *患者姓名
     * </pre>
     *
     * <code>string patName = 1;</code>
     * @return The bytes for patName.
     */
    @java.lang.Override
    public com.google.protobuf.ByteString
        getPatNameBytes() {
      java.lang.Object ref = patName_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        patName_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    public static final int AGE_FIELD_NUMBER = 2;
    private int age_;
    /**
     * <pre>
     *年龄
     * </pre>
     *
     * <code>int32 age = 2;</code>
     * @return The age.
     */
    @java.lang.Override
    public int getAge() {
      return age_;
    }

    public static final int SEX_FIELD_NUMBER = 3;
    private int sex_;
    /**
     * <pre>
     *性别
     * </pre>
     *
     * <code>int32 sex = 3;</code>
     * @return The sex.
     */
    @java.lang.Override
    public int getSex() {
      return sex_;
    }

    public static final int NATION_FIELD_NUMBER = 4;
    private volatile java.lang.Object nation_;
    /**
     * <pre>
     *民族
     * </pre>
     *
     * <code>string nation = 4;</code>
     * @return The nation.
     */
    @java.lang.Override
    public java.lang.String getNation() {
      java.lang.Object ref = nation_;
      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();
        nation_ = s;
        return s;
      }
    }
    /**
     * <pre>
     *民族
     * </pre>
     *
     * <code>string nation = 4;</code>
     * @return The bytes for nation.
     */
    @java.lang.Override
    public com.google.protobuf.ByteString
        getNationBytes() {
      java.lang.Object ref = nation_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        nation_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    public static final int ADDRESS_FIELD_NUMBER = 5;
    private volatile java.lang.Object address_;
    /**
     * <pre>
     *住址
     * </pre>
     *
     * <code>string address = 5;</code>
     * @return The address.
     */
    @java.lang.Override
    public java.lang.String getAddress() {
      java.lang.Object ref = address_;
      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();
        address_ = s;
        return s;
      }
    }
    /**
     * <pre>
     *住址
     * </pre>
     *
     * <code>string address = 5;</code>
     * @return The bytes for address.
     */
    @java.lang.Override
    public com.google.protobuf.ByteString
        getAddressBytes() {
      java.lang.Object ref = address_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        address_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    public static final int PHONENUMBER_FIELD_NUMBER = 6;
    private volatile java.lang.Object phoneNumber_;
    /**
     * <pre>
     *电话号码
     * </pre>
     *
     * <code>string phoneNumber = 6;</code>
     * @return The phoneNumber.
     */
    @java.lang.Override
    public java.lang.String getPhoneNumber() {
      java.lang.Object ref = phoneNumber_;
      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();
        phoneNumber_ = s;
        return s;
      }
    }
    /**
     * <pre>
     *电话号码
     * </pre>
     *
     * <code>string phoneNumber = 6;</code>
     * @return The bytes for phoneNumber.
     */
    @java.lang.Override
    public com.google.protobuf.ByteString
        getPhoneNumberBytes() {
      java.lang.Object ref = phoneNumber_;
      if (ref instanceof java.lang.String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        phoneNumber_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }

    private byte memoizedIsInitialized = -1;
    @java.lang.Override
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized == 1) return true;
      if (isInitialized == 0) return false;

      memoizedIsInitialized = 1;
      return true;
    }

    @java.lang.Override
    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(patName_)) {
        com.google.protobuf.GeneratedMessageV3.writeString(output, 1, patName_);
      }
      if (age_ != 0) {
        output.writeInt32(2, age_);
      }
      if (sex_ != 0) {
        output.writeInt32(3, sex_);
      }
      if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nation_)) {
        com.google.protobuf.GeneratedMessageV3.writeString(output, 4, nation_);
      }
      if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(address_)) {
        com.google.protobuf.GeneratedMessageV3.writeString(output, 5, address_);
      }
      if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(phoneNumber_)) {
        com.google.protobuf.GeneratedMessageV3.writeString(output, 6, phoneNumber_);
      }
      unknownFields.writeTo(output);
    }

    @java.lang.Override
    public int getSerializedSize() {
      int size = memoizedSize;
      if (size != -1) return size;

      size = 0;
      if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(patName_)) {
        size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, patName_);
      }
      if (age_ != 0) {
        size += com.google.protobuf.CodedOutputStream
          .computeInt32Size(2, age_);
      }
      if (sex_ != 0) {
        size += com.google.protobuf.CodedOutputStream
          .computeInt32Size(3, sex_);
      }
      if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nation_)) {
        size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, nation_);
      }
      if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(address_)) {
        size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, address_);
      }
      if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(phoneNumber_)) {
        size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, phoneNumber_);
      }
      size += unknownFields.getSerializedSize();
      memoizedSize = size;
      return size;
    }

    @java.lang.Override
    public boolean equals(final java.lang.Object obj) {
      if (obj == this) {
       return true;
      }
      if (!(obj instanceof com.ywt.gapi.third.taihe.MedicalRecord.PatInfo)) {
        return super.equals(obj);
      }
      com.ywt.gapi.third.taihe.MedicalRecord.PatInfo other = (com.ywt.gapi.third.taihe.MedicalRecord.PatInfo) obj;

      if (!getPatName()
          .equals(other.getPatName())) return false;
      if (getAge()
          != other.getAge()) return false;
      if (getSex()
          != other.getSex()) return false;
      if (!getNation()
          .equals(other.getNation())) return false;
      if (!getAddress()
          .equals(other.getAddress())) return false;
      if (!getPhoneNumber()
          .equals(other.getPhoneNumber())) return false;
      if (!unknownFields.equals(other.unknownFields)) return false;
      return true;
    }

    @java.lang.Override
    public int hashCode() {
      if (memoizedHashCode != 0) {
        return memoizedHashCode;
      }
      int hash = 41;
      hash = (19 * hash) + getDescriptor().hashCode();
      hash = (37 * hash) + PATNAME_FIELD_NUMBER;
      hash = (53 * hash) + getPatName().hashCode();
      hash = (37 * hash) + AGE_FIELD_NUMBER;
      hash = (53 * hash) + getAge();
      hash = (37 * hash) + SEX_FIELD_NUMBER;
      hash = (53 * hash) + getSex();
      hash = (37 * hash) + NATION_FIELD_NUMBER;
      hash = (53 * hash) + getNation().hashCode();
      hash = (37 * hash) + ADDRESS_FIELD_NUMBER;
      hash = (53 * hash) + getAddress().hashCode();
      hash = (37 * hash) + PHONENUMBER_FIELD_NUMBER;
      hash = (53 * hash) + getPhoneNumber().hashCode();
      hash = (29 * hash) + unknownFields.hashCode();
      memoizedHashCode = hash;
      return hash;
    }

    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parseFrom(
        java.nio.ByteBuffer data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parseFrom(
        java.nio.ByteBuffer data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input);
    }
    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input, extensionRegistry);
    }
    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseDelimitedWithIOException(PARSER, input);
    }
    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
    }
    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input);
    }
    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input, extensionRegistry);
    }

    @java.lang.Override
    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder() {
      return DEFAULT_INSTANCE.toBuilder();
    }
    public static Builder newBuilder(com.ywt.gapi.third.taihe.MedicalRecord.PatInfo prototype) {
      return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
    }
    @java.lang.Override
    public Builder toBuilder() {
      return this == DEFAULT_INSTANCE
          ? new Builder() : new Builder().mergeFrom(this);
    }

    @java.lang.Override
    protected Builder newBuilderForType(
        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
      Builder builder = new Builder(parent);
      return builder;
    }
    /**
     * <pre>
     *患者信息
     * </pre>
     *
     * Protobuf type {@code com.ywt.gapi.third.taihe.MedicalRecord.PatInfo}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
        // @@protoc_insertion_point(builder_implements:com.ywt.gapi.third.taihe.MedicalRecord.PatInfo)
        com.ywt.gapi.third.taihe.MedicalRecord.PatInfoOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return com.ywt.gapi.third.taihe.TaiheProto.internal_static_com_ywt_gapi_third_taihe_MedicalRecord_PatInfo_descriptor;
      }

      @java.lang.Override
      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return com.ywt.gapi.third.taihe.TaiheProto.internal_static_com_ywt_gapi_third_taihe_MedicalRecord_PatInfo_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.class, com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.Builder.class);
      }

      // Construct using com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessageV3
                .alwaysUseFieldBuilders) {
        }
      }
      @java.lang.Override
      public Builder clear() {
        super.clear();
        patName_ = "";

        age_ = 0;

        sex_ = 0;

        nation_ = "";

        address_ = "";

        phoneNumber_ = "";

        return this;
      }

      @java.lang.Override
      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return com.ywt.gapi.third.taihe.TaiheProto.internal_static_com_ywt_gapi_third_taihe_MedicalRecord_PatInfo_descriptor;
      }

      @java.lang.Override
      public com.ywt.gapi.third.taihe.MedicalRecord.PatInfo getDefaultInstanceForType() {
        return com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.getDefaultInstance();
      }

      @java.lang.Override
      public com.ywt.gapi.third.taihe.MedicalRecord.PatInfo build() {
        com.ywt.gapi.third.taihe.MedicalRecord.PatInfo result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      @java.lang.Override
      public com.ywt.gapi.third.taihe.MedicalRecord.PatInfo buildPartial() {
        com.ywt.gapi.third.taihe.MedicalRecord.PatInfo result = new com.ywt.gapi.third.taihe.MedicalRecord.PatInfo(this);
        result.patName_ = patName_;
        result.age_ = age_;
        result.sex_ = sex_;
        result.nation_ = nation_;
        result.address_ = address_;
        result.phoneNumber_ = phoneNumber_;
        onBuilt();
        return result;
      }

      @java.lang.Override
      public Builder clone() {
        return super.clone();
      }
      @java.lang.Override
      public Builder setField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          java.lang.Object value) {
        return super.setField(field, value);
      }
      @java.lang.Override
      public Builder clearField(
          com.google.protobuf.Descriptors.FieldDescriptor field) {
        return super.clearField(field);
      }
      @java.lang.Override
      public Builder clearOneof(
          com.google.protobuf.Descriptors.OneofDescriptor oneof) {
        return super.clearOneof(oneof);
      }
      @java.lang.Override
      public Builder setRepeatedField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          int index, java.lang.Object value) {
        return super.setRepeatedField(field, index, value);
      }
      @java.lang.Override
      public Builder addRepeatedField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          java.lang.Object value) {
        return super.addRepeatedField(field, value);
      }
      @java.lang.Override
      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof com.ywt.gapi.third.taihe.MedicalRecord.PatInfo) {
          return mergeFrom((com.ywt.gapi.third.taihe.MedicalRecord.PatInfo)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(com.ywt.gapi.third.taihe.MedicalRecord.PatInfo other) {
        if (other == com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.getDefaultInstance()) return this;
        if (!other.getPatName().isEmpty()) {
          patName_ = other.patName_;
          onChanged();
        }
        if (other.getAge() != 0) {
          setAge(other.getAge());
        }
        if (other.getSex() != 0) {
          setSex(other.getSex());
        }
        if (!other.getNation().isEmpty()) {
          nation_ = other.nation_;
          onChanged();
        }
        if (!other.getAddress().isEmpty()) {
          address_ = other.address_;
          onChanged();
        }
        if (!other.getPhoneNumber().isEmpty()) {
          phoneNumber_ = other.phoneNumber_;
          onChanged();
        }
        this.mergeUnknownFields(other.unknownFields);
        onChanged();
        return this;
      }

      @java.lang.Override
      public final boolean isInitialized() {
        return true;
      }

      @java.lang.Override
      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        com.ywt.gapi.third.taihe.MedicalRecord.PatInfo parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (com.ywt.gapi.third.taihe.MedicalRecord.PatInfo) e.getUnfinishedMessage();
          throw e.unwrapIOException();
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }

      private java.lang.Object patName_ = "";
      /**
       * <pre>
       *患者姓名
       * </pre>
       *
       * <code>string patName = 1;</code>
       * @return The patName.
       */
      public java.lang.String getPatName() {
        java.lang.Object ref = patName_;
        if (!(ref instanceof java.lang.String)) {
          com.google.protobuf.ByteString bs =
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          patName_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <pre>
       *患者姓名
       * </pre>
       *
       * <code>string patName = 1;</code>
       * @return The bytes for patName.
       */
      public com.google.protobuf.ByteString
          getPatNameBytes() {
        java.lang.Object ref = patName_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          patName_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <pre>
       *患者姓名
       * </pre>
       *
       * <code>string patName = 1;</code>
       * @param value The patName to set.
       * @return This builder for chaining.
       */
      public Builder setPatName(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  
        patName_ = value;
        onChanged();
        return this;
      }
      /**
       * <pre>
       *患者姓名
       * </pre>
       *
       * <code>string patName = 1;</code>
       * @return This builder for chaining.
       */
      public Builder clearPatName() {
        
        patName_ = getDefaultInstance().getPatName();
        onChanged();
        return this;
      }
      /**
       * <pre>
       *患者姓名
       * </pre>
       *
       * <code>string patName = 1;</code>
       * @param value The bytes for patName to set.
       * @return This builder for chaining.
       */
      public Builder setPatNameBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
        
        patName_ = value;
        onChanged();
        return this;
      }

      private int age_ ;
      /**
       * <pre>
       *年龄
       * </pre>
       *
       * <code>int32 age = 2;</code>
       * @return The age.
       */
      @java.lang.Override
      public int getAge() {
        return age_;
      }
      /**
       * <pre>
       *年龄
       * </pre>
       *
       * <code>int32 age = 2;</code>
       * @param value The age to set.
       * @return This builder for chaining.
       */
      public Builder setAge(int value) {
        
        age_ = value;
        onChanged();
        return this;
      }
      /**
       * <pre>
       *年龄
       * </pre>
       *
       * <code>int32 age = 2;</code>
       * @return This builder for chaining.
       */
      public Builder clearAge() {
        
        age_ = 0;
        onChanged();
        return this;
      }

      private int sex_ ;
      /**
       * <pre>
       *性别
       * </pre>
       *
       * <code>int32 sex = 3;</code>
       * @return The sex.
       */
      @java.lang.Override
      public int getSex() {
        return sex_;
      }
      /**
       * <pre>
       *性别
       * </pre>
       *
       * <code>int32 sex = 3;</code>
       * @param value The sex to set.
       * @return This builder for chaining.
       */
      public Builder setSex(int value) {
        
        sex_ = value;
        onChanged();
        return this;
      }
      /**
       * <pre>
       *性别
       * </pre>
       *
       * <code>int32 sex = 3;</code>
       * @return This builder for chaining.
       */
      public Builder clearSex() {
        
        sex_ = 0;
        onChanged();
        return this;
      }

      private java.lang.Object nation_ = "";
      /**
       * <pre>
       *民族
       * </pre>
       *
       * <code>string nation = 4;</code>
       * @return The nation.
       */
      public java.lang.String getNation() {
        java.lang.Object ref = nation_;
        if (!(ref instanceof java.lang.String)) {
          com.google.protobuf.ByteString bs =
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          nation_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <pre>
       *民族
       * </pre>
       *
       * <code>string nation = 4;</code>
       * @return The bytes for nation.
       */
      public com.google.protobuf.ByteString
          getNationBytes() {
        java.lang.Object ref = nation_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          nation_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <pre>
       *民族
       * </pre>
       *
       * <code>string nation = 4;</code>
       * @param value The nation to set.
       * @return This builder for chaining.
       */
      public Builder setNation(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  
        nation_ = value;
        onChanged();
        return this;
      }
      /**
       * <pre>
       *民族
       * </pre>
       *
       * <code>string nation = 4;</code>
       * @return This builder for chaining.
       */
      public Builder clearNation() {
        
        nation_ = getDefaultInstance().getNation();
        onChanged();
        return this;
      }
      /**
       * <pre>
       *民族
       * </pre>
       *
       * <code>string nation = 4;</code>
       * @param value The bytes for nation to set.
       * @return This builder for chaining.
       */
      public Builder setNationBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
        
        nation_ = value;
        onChanged();
        return this;
      }

      private java.lang.Object address_ = "";
      /**
       * <pre>
       *住址
       * </pre>
       *
       * <code>string address = 5;</code>
       * @return The address.
       */
      public java.lang.String getAddress() {
        java.lang.Object ref = address_;
        if (!(ref instanceof java.lang.String)) {
          com.google.protobuf.ByteString bs =
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          address_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <pre>
       *住址
       * </pre>
       *
       * <code>string address = 5;</code>
       * @return The bytes for address.
       */
      public com.google.protobuf.ByteString
          getAddressBytes() {
        java.lang.Object ref = address_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          address_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <pre>
       *住址
       * </pre>
       *
       * <code>string address = 5;</code>
       * @param value The address to set.
       * @return This builder for chaining.
       */
      public Builder setAddress(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  
        address_ = value;
        onChanged();
        return this;
      }
      /**
       * <pre>
       *住址
       * </pre>
       *
       * <code>string address = 5;</code>
       * @return This builder for chaining.
       */
      public Builder clearAddress() {
        
        address_ = getDefaultInstance().getAddress();
        onChanged();
        return this;
      }
      /**
       * <pre>
       *住址
       * </pre>
       *
       * <code>string address = 5;</code>
       * @param value The bytes for address to set.
       * @return This builder for chaining.
       */
      public Builder setAddressBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
        
        address_ = value;
        onChanged();
        return this;
      }

      private java.lang.Object phoneNumber_ = "";
      /**
       * <pre>
       *电话号码
       * </pre>
       *
       * <code>string phoneNumber = 6;</code>
       * @return The phoneNumber.
       */
      public java.lang.String getPhoneNumber() {
        java.lang.Object ref = phoneNumber_;
        if (!(ref instanceof java.lang.String)) {
          com.google.protobuf.ByteString bs =
              (com.google.protobuf.ByteString) ref;
          java.lang.String s = bs.toStringUtf8();
          phoneNumber_ = s;
          return s;
        } else {
          return (java.lang.String) ref;
        }
      }
      /**
       * <pre>
       *电话号码
       * </pre>
       *
       * <code>string phoneNumber = 6;</code>
       * @return The bytes for phoneNumber.
       */
      public com.google.protobuf.ByteString
          getPhoneNumberBytes() {
        java.lang.Object ref = phoneNumber_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8(
                  (java.lang.String) ref);
          phoneNumber_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      /**
       * <pre>
       *电话号码
       * </pre>
       *
       * <code>string phoneNumber = 6;</code>
       * @param value The phoneNumber to set.
       * @return This builder for chaining.
       */
      public Builder setPhoneNumber(
          java.lang.String value) {
        if (value == null) {
    throw new NullPointerException();
  }
  
        phoneNumber_ = value;
        onChanged();
        return this;
      }
      /**
       * <pre>
       *电话号码
       * </pre>
       *
       * <code>string phoneNumber = 6;</code>
       * @return This builder for chaining.
       */
      public Builder clearPhoneNumber() {
        
        phoneNumber_ = getDefaultInstance().getPhoneNumber();
        onChanged();
        return this;
      }
      /**
       * <pre>
       *电话号码
       * </pre>
       *
       * <code>string phoneNumber = 6;</code>
       * @param value The bytes for phoneNumber to set.
       * @return This builder for chaining.
       */
      public Builder setPhoneNumberBytes(
          com.google.protobuf.ByteString value) {
        if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
        
        phoneNumber_ = value;
        onChanged();
        return this;
      }
      @java.lang.Override
      public final Builder setUnknownFields(
          final com.google.protobuf.UnknownFieldSet unknownFields) {
        return super.setUnknownFields(unknownFields);
      }

      @java.lang.Override
      public final Builder mergeUnknownFields(
          final com.google.protobuf.UnknownFieldSet unknownFields) {
        return super.mergeUnknownFields(unknownFields);
      }


      // @@protoc_insertion_point(builder_scope:com.ywt.gapi.third.taihe.MedicalRecord.PatInfo)
    }

    // @@protoc_insertion_point(class_scope:com.ywt.gapi.third.taihe.MedicalRecord.PatInfo)
    private static final com.ywt.gapi.third.taihe.MedicalRecord.PatInfo DEFAULT_INSTANCE;
    static {
      DEFAULT_INSTANCE = new com.ywt.gapi.third.taihe.MedicalRecord.PatInfo();
    }

    public static com.ywt.gapi.third.taihe.MedicalRecord.PatInfo getDefaultInstance() {
      return DEFAULT_INSTANCE;
    }

    private static final com.google.protobuf.Parser<PatInfo>
        PARSER = new com.google.protobuf.AbstractParser<PatInfo>() {
      @java.lang.Override
      public PatInfo parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new PatInfo(input, extensionRegistry);
      }
    };

    public static com.google.protobuf.Parser<PatInfo> parser() {
      return PARSER;
    }

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

    @java.lang.Override
    public com.ywt.gapi.third.taihe.MedicalRecord.PatInfo getDefaultInstanceForType() {
      return DEFAULT_INSTANCE;
    }

  }

  public static final int PATINFO_FIELD_NUMBER = 1;
  private com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo_;
  /**
   * <pre>
   *患者信息
   * </pre>
   *
   * <code>.com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo = 1;</code>
   * @return Whether the patInfo field is set.
   */
  @java.lang.Override
  public boolean hasPatInfo() {
    return patInfo_ != null;
  }
  /**
   * <pre>
   *患者信息
   * </pre>
   *
   * <code>.com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo = 1;</code>
   * @return The patInfo.
   */
  @java.lang.Override
  public com.ywt.gapi.third.taihe.MedicalRecord.PatInfo getPatInfo() {
    return patInfo_ == null ? com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.getDefaultInstance() : patInfo_;
  }
  /**
   * <pre>
   *患者信息
   * </pre>
   *
   * <code>.com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo = 1;</code>
   */
  @java.lang.Override
  public com.ywt.gapi.third.taihe.MedicalRecord.PatInfoOrBuilder getPatInfoOrBuilder() {
    return getPatInfo();
  }

  public static final int DOCTORNAME_FIELD_NUMBER = 2;
  private volatile java.lang.Object doctorName_;
  /**
   * <pre>
   *医生姓名
   * </pre>
   *
   * <code>string doctorName = 2;</code>
   * @return The doctorName.
   */
  @java.lang.Override
  public java.lang.String getDoctorName() {
    java.lang.Object ref = doctorName_;
    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();
      doctorName_ = s;
      return s;
    }
  }
  /**
   * <pre>
   *医生姓名
   * </pre>
   *
   * <code>string doctorName = 2;</code>
   * @return The bytes for doctorName.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getDoctorNameBytes() {
    java.lang.Object ref = doctorName_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      doctorName_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int REGISTRATIONDATE_FIELD_NUMBER = 3;
  private volatile java.lang.Object registrationDate_;
  /**
   * <pre>
   *门诊时间
   * </pre>
   *
   * <code>string registrationDate = 3;</code>
   * @return The registrationDate.
   */
  @java.lang.Override
  public java.lang.String getRegistrationDate() {
    java.lang.Object ref = registrationDate_;
    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();
      registrationDate_ = s;
      return s;
    }
  }
  /**
   * <pre>
   *门诊时间
   * </pre>
   *
   * <code>string registrationDate = 3;</code>
   * @return The bytes for registrationDate.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getRegistrationDateBytes() {
    java.lang.Object ref = registrationDate_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      registrationDate_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int MEDICALCARDNO_FIELD_NUMBER = 4;
  private volatile java.lang.Object medicalCardNo_;
  /**
   * <pre>
   *诊疗卡号
   * </pre>
   *
   * <code>string medicalCardNo = 4;</code>
   * @return The medicalCardNo.
   */
  @java.lang.Override
  public java.lang.String getMedicalCardNo() {
    java.lang.Object ref = medicalCardNo_;
    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();
      medicalCardNo_ = s;
      return s;
    }
  }
  /**
   * <pre>
   *诊疗卡号
   * </pre>
   *
   * <code>string medicalCardNo = 4;</code>
   * @return The bytes for medicalCardNo.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getMedicalCardNoBytes() {
    java.lang.Object ref = medicalCardNo_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      medicalCardNo_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int DOCTORADVICE_FIELD_NUMBER = 5;
  private volatile java.lang.Object doctorAdvice_;
  /**
   * <pre>
   *门/急诊医嘱
   * </pre>
   *
   * <code>string doctorAdvice = 5;</code>
   * @return The doctorAdvice.
   */
  @java.lang.Override
  public java.lang.String getDoctorAdvice() {
    java.lang.Object ref = doctorAdvice_;
    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();
      doctorAdvice_ = s;
      return s;
    }
  }
  /**
   * <pre>
   *门/急诊医嘱
   * </pre>
   *
   * <code>string doctorAdvice = 5;</code>
   * @return The bytes for doctorAdvice.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getDoctorAdviceBytes() {
    java.lang.Object ref = doctorAdvice_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      doctorAdvice_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int DEPTNAME_FIELD_NUMBER = 6;
  private volatile java.lang.Object deptName_;
  /**
   * <pre>
   *科室名称
   * </pre>
   *
   * <code>string deptName = 6;</code>
   * @return The deptName.
   */
  @java.lang.Override
  public java.lang.String getDeptName() {
    java.lang.Object ref = deptName_;
    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();
      deptName_ = s;
      return s;
    }
  }
  /**
   * <pre>
   *科室名称
   * </pre>
   *
   * <code>string deptName = 6;</code>
   * @return The bytes for deptName.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getDeptNameBytes() {
    java.lang.Object ref = deptName_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      deptName_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int CHECKINTIME_FIELD_NUMBER = 7;
  private volatile java.lang.Object checkInTime_;
  /**
   * <pre>
   *患者入院日期
   * </pre>
   *
   * <code>string checkInTime = 7;</code>
   * @return The checkInTime.
   */
  @java.lang.Override
  public java.lang.String getCheckInTime() {
    java.lang.Object ref = checkInTime_;
    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();
      checkInTime_ = s;
      return s;
    }
  }
  /**
   * <pre>
   *患者入院日期
   * </pre>
   *
   * <code>string checkInTime = 7;</code>
   * @return The bytes for checkInTime.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getCheckInTimeBytes() {
    java.lang.Object ref = checkInTime_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      checkInTime_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int CHIEFCOMPLAINT_FIELD_NUMBER = 8;
  private volatile java.lang.Object chiefComplaint_;
  /**
   * <pre>
   *主诉
   * </pre>
   *
   * <code>string chiefComplaint = 8;</code>
   * @return The chiefComplaint.
   */
  @java.lang.Override
  public java.lang.String getChiefComplaint() {
    java.lang.Object ref = chiefComplaint_;
    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();
      chiefComplaint_ = s;
      return s;
    }
  }
  /**
   * <pre>
   *主诉
   * </pre>
   *
   * <code>string chiefComplaint = 8;</code>
   * @return The bytes for chiefComplaint.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getChiefComplaintBytes() {
    java.lang.Object ref = chiefComplaint_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      chiefComplaint_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int PHYSICALEXAM_FIELD_NUMBER = 9;
  private volatile java.lang.Object physicalExam_;
  /**
   * <pre>
   *体格检查
   * </pre>
   *
   * <code>string physicalExam = 9;</code>
   * @return The physicalExam.
   */
  @java.lang.Override
  public java.lang.String getPhysicalExam() {
    java.lang.Object ref = physicalExam_;
    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();
      physicalExam_ = s;
      return s;
    }
  }
  /**
   * <pre>
   *体格检查
   * </pre>
   *
   * <code>string physicalExam = 9;</code>
   * @return The bytes for physicalExam.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getPhysicalExamBytes() {
    java.lang.Object ref = physicalExam_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      physicalExam_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int DIAGNOSE_FIELD_NUMBER = 10;
  private volatile java.lang.Object diagnose_;
  /**
   * <pre>
   *门诊诊断
   * </pre>
   *
   * <code>string diagnose = 10;</code>
   * @return The diagnose.
   */
  @java.lang.Override
  public java.lang.String getDiagnose() {
    java.lang.Object ref = diagnose_;
    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();
      diagnose_ = s;
      return s;
    }
  }
  /**
   * <pre>
   *门诊诊断
   * </pre>
   *
   * <code>string diagnose = 10;</code>
   * @return The bytes for diagnose.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getDiagnoseBytes() {
    java.lang.Object ref = diagnose_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      diagnose_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int SUGGESTION_FIELD_NUMBER = 11;
  private volatile java.lang.Object suggestion_;
  /**
   * <pre>
   *意见
   * </pre>
   *
   * <code>string suggestion = 11;</code>
   * @return The suggestion.
   */
  @java.lang.Override
  public java.lang.String getSuggestion() {
    java.lang.Object ref = suggestion_;
    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();
      suggestion_ = s;
      return s;
    }
  }
  /**
   * <pre>
   *意见
   * </pre>
   *
   * <code>string suggestion = 11;</code>
   * @return The bytes for suggestion.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getSuggestionBytes() {
    java.lang.Object ref = suggestion_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      suggestion_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  private byte memoizedIsInitialized = -1;
  @java.lang.Override
  public final boolean isInitialized() {
    byte isInitialized = memoizedIsInitialized;
    if (isInitialized == 1) return true;
    if (isInitialized == 0) return false;

    memoizedIsInitialized = 1;
    return true;
  }

  @java.lang.Override
  public void writeTo(com.google.protobuf.CodedOutputStream output)
                      throws java.io.IOException {
    if (patInfo_ != null) {
      output.writeMessage(1, getPatInfo());
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(doctorName_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 2, doctorName_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(registrationDate_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 3, registrationDate_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(medicalCardNo_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 4, medicalCardNo_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(doctorAdvice_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 5, doctorAdvice_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(deptName_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 6, deptName_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(checkInTime_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 7, checkInTime_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(chiefComplaint_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 8, chiefComplaint_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(physicalExam_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 9, physicalExam_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(diagnose_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 10, diagnose_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(suggestion_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 11, suggestion_);
    }
    unknownFields.writeTo(output);
  }

  @java.lang.Override
  public int getSerializedSize() {
    int size = memoizedSize;
    if (size != -1) return size;

    size = 0;
    if (patInfo_ != null) {
      size += com.google.protobuf.CodedOutputStream
        .computeMessageSize(1, getPatInfo());
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(doctorName_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, doctorName_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(registrationDate_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, registrationDate_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(medicalCardNo_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, medicalCardNo_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(doctorAdvice_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, doctorAdvice_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(deptName_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, deptName_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(checkInTime_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, checkInTime_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(chiefComplaint_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, chiefComplaint_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(physicalExam_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(9, physicalExam_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(diagnose_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(10, diagnose_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(suggestion_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(11, suggestion_);
    }
    size += unknownFields.getSerializedSize();
    memoizedSize = size;
    return size;
  }

  @java.lang.Override
  public boolean equals(final java.lang.Object obj) {
    if (obj == this) {
     return true;
    }
    if (!(obj instanceof com.ywt.gapi.third.taihe.MedicalRecord)) {
      return super.equals(obj);
    }
    com.ywt.gapi.third.taihe.MedicalRecord other = (com.ywt.gapi.third.taihe.MedicalRecord) obj;

    if (hasPatInfo() != other.hasPatInfo()) return false;
    if (hasPatInfo()) {
      if (!getPatInfo()
          .equals(other.getPatInfo())) return false;
    }
    if (!getDoctorName()
        .equals(other.getDoctorName())) return false;
    if (!getRegistrationDate()
        .equals(other.getRegistrationDate())) return false;
    if (!getMedicalCardNo()
        .equals(other.getMedicalCardNo())) return false;
    if (!getDoctorAdvice()
        .equals(other.getDoctorAdvice())) return false;
    if (!getDeptName()
        .equals(other.getDeptName())) return false;
    if (!getCheckInTime()
        .equals(other.getCheckInTime())) return false;
    if (!getChiefComplaint()
        .equals(other.getChiefComplaint())) return false;
    if (!getPhysicalExam()
        .equals(other.getPhysicalExam())) return false;
    if (!getDiagnose()
        .equals(other.getDiagnose())) return false;
    if (!getSuggestion()
        .equals(other.getSuggestion())) return false;
    if (!unknownFields.equals(other.unknownFields)) return false;
    return true;
  }

  @java.lang.Override
  public int hashCode() {
    if (memoizedHashCode != 0) {
      return memoizedHashCode;
    }
    int hash = 41;
    hash = (19 * hash) + getDescriptor().hashCode();
    if (hasPatInfo()) {
      hash = (37 * hash) + PATINFO_FIELD_NUMBER;
      hash = (53 * hash) + getPatInfo().hashCode();
    }
    hash = (37 * hash) + DOCTORNAME_FIELD_NUMBER;
    hash = (53 * hash) + getDoctorName().hashCode();
    hash = (37 * hash) + REGISTRATIONDATE_FIELD_NUMBER;
    hash = (53 * hash) + getRegistrationDate().hashCode();
    hash = (37 * hash) + MEDICALCARDNO_FIELD_NUMBER;
    hash = (53 * hash) + getMedicalCardNo().hashCode();
    hash = (37 * hash) + DOCTORADVICE_FIELD_NUMBER;
    hash = (53 * hash) + getDoctorAdvice().hashCode();
    hash = (37 * hash) + DEPTNAME_FIELD_NUMBER;
    hash = (53 * hash) + getDeptName().hashCode();
    hash = (37 * hash) + CHECKINTIME_FIELD_NUMBER;
    hash = (53 * hash) + getCheckInTime().hashCode();
    hash = (37 * hash) + CHIEFCOMPLAINT_FIELD_NUMBER;
    hash = (53 * hash) + getChiefComplaint().hashCode();
    hash = (37 * hash) + PHYSICALEXAM_FIELD_NUMBER;
    hash = (53 * hash) + getPhysicalExam().hashCode();
    hash = (37 * hash) + DIAGNOSE_FIELD_NUMBER;
    hash = (53 * hash) + getDiagnose().hashCode();
    hash = (37 * hash) + SUGGESTION_FIELD_NUMBER;
    hash = (53 * hash) + getSuggestion().hashCode();
    hash = (29 * hash) + unknownFields.hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static com.ywt.gapi.third.taihe.MedicalRecord parseFrom(
      java.nio.ByteBuffer data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.ywt.gapi.third.taihe.MedicalRecord parseFrom(
      java.nio.ByteBuffer data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.ywt.gapi.third.taihe.MedicalRecord parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.ywt.gapi.third.taihe.MedicalRecord parseFrom(
      com.google.protobuf.ByteString data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.ywt.gapi.third.taihe.MedicalRecord parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.ywt.gapi.third.taihe.MedicalRecord parseFrom(
      byte[] data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.ywt.gapi.third.taihe.MedicalRecord parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static com.ywt.gapi.third.taihe.MedicalRecord parseFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }
  public static com.ywt.gapi.third.taihe.MedicalRecord parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input);
  }
  public static com.ywt.gapi.third.taihe.MedicalRecord parseDelimitedFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
  }
  public static com.ywt.gapi.third.taihe.MedicalRecord parseFrom(
      com.google.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static com.ywt.gapi.third.taihe.MedicalRecord parseFrom(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }

  @java.lang.Override
  public Builder newBuilderForType() { return newBuilder(); }
  public static Builder newBuilder() {
    return DEFAULT_INSTANCE.toBuilder();
  }
  public static Builder newBuilder(com.ywt.gapi.third.taihe.MedicalRecord prototype) {
    return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
  }
  @java.lang.Override
  public Builder toBuilder() {
    return this == DEFAULT_INSTANCE
        ? new Builder() : new Builder().mergeFrom(this);
  }

  @java.lang.Override
  protected Builder newBuilderForType(
      com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
    Builder builder = new Builder(parent);
    return builder;
  }
  /**
   * <pre>
   *病历
   * </pre>
   *
   * Protobuf type {@code com.ywt.gapi.third.taihe.MedicalRecord}
   */
  public static final class Builder extends
      com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
      // @@protoc_insertion_point(builder_implements:com.ywt.gapi.third.taihe.MedicalRecord)
      com.ywt.gapi.third.taihe.MedicalRecordOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return com.ywt.gapi.third.taihe.TaiheProto.internal_static_com_ywt_gapi_third_taihe_MedicalRecord_descriptor;
    }

    @java.lang.Override
    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.ywt.gapi.third.taihe.TaiheProto.internal_static_com_ywt_gapi_third_taihe_MedicalRecord_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.ywt.gapi.third.taihe.MedicalRecord.class, com.ywt.gapi.third.taihe.MedicalRecord.Builder.class);
    }

    // Construct using com.ywt.gapi.third.taihe.MedicalRecord.newBuilder()
    private Builder() {
      maybeForceBuilderInitialization();
    }

    private Builder(
        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
      super(parent);
      maybeForceBuilderInitialization();
    }
    private void maybeForceBuilderInitialization() {
      if (com.google.protobuf.GeneratedMessageV3
              .alwaysUseFieldBuilders) {
      }
    }
    @java.lang.Override
    public Builder clear() {
      super.clear();
      if (patInfoBuilder_ == null) {
        patInfo_ = null;
      } else {
        patInfo_ = null;
        patInfoBuilder_ = null;
      }
      doctorName_ = "";

      registrationDate_ = "";

      medicalCardNo_ = "";

      doctorAdvice_ = "";

      deptName_ = "";

      checkInTime_ = "";

      chiefComplaint_ = "";

      physicalExam_ = "";

      diagnose_ = "";

      suggestion_ = "";

      return this;
    }

    @java.lang.Override
    public com.google.protobuf.Descriptors.Descriptor
        getDescriptorForType() {
      return com.ywt.gapi.third.taihe.TaiheProto.internal_static_com_ywt_gapi_third_taihe_MedicalRecord_descriptor;
    }

    @java.lang.Override
    public com.ywt.gapi.third.taihe.MedicalRecord getDefaultInstanceForType() {
      return com.ywt.gapi.third.taihe.MedicalRecord.getDefaultInstance();
    }

    @java.lang.Override
    public com.ywt.gapi.third.taihe.MedicalRecord build() {
      com.ywt.gapi.third.taihe.MedicalRecord result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    @java.lang.Override
    public com.ywt.gapi.third.taihe.MedicalRecord buildPartial() {
      com.ywt.gapi.third.taihe.MedicalRecord result = new com.ywt.gapi.third.taihe.MedicalRecord(this);
      if (patInfoBuilder_ == null) {
        result.patInfo_ = patInfo_;
      } else {
        result.patInfo_ = patInfoBuilder_.build();
      }
      result.doctorName_ = doctorName_;
      result.registrationDate_ = registrationDate_;
      result.medicalCardNo_ = medicalCardNo_;
      result.doctorAdvice_ = doctorAdvice_;
      result.deptName_ = deptName_;
      result.checkInTime_ = checkInTime_;
      result.chiefComplaint_ = chiefComplaint_;
      result.physicalExam_ = physicalExam_;
      result.diagnose_ = diagnose_;
      result.suggestion_ = suggestion_;
      onBuilt();
      return result;
    }

    @java.lang.Override
    public Builder clone() {
      return super.clone();
    }
    @java.lang.Override
    public Builder setField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return super.setField(field, value);
    }
    @java.lang.Override
    public Builder clearField(
        com.google.protobuf.Descriptors.FieldDescriptor field) {
      return super.clearField(field);
    }
    @java.lang.Override
    public Builder clearOneof(
        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
      return super.clearOneof(oneof);
    }
    @java.lang.Override
    public Builder setRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        int index, java.lang.Object value) {
      return super.setRepeatedField(field, index, value);
    }
    @java.lang.Override
    public Builder addRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return super.addRepeatedField(field, value);
    }
    @java.lang.Override
    public Builder mergeFrom(com.google.protobuf.Message other) {
      if (other instanceof com.ywt.gapi.third.taihe.MedicalRecord) {
        return mergeFrom((com.ywt.gapi.third.taihe.MedicalRecord)other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(com.ywt.gapi.third.taihe.MedicalRecord other) {
      if (other == com.ywt.gapi.third.taihe.MedicalRecord.getDefaultInstance()) return this;
      if (other.hasPatInfo()) {
        mergePatInfo(other.getPatInfo());
      }
      if (!other.getDoctorName().isEmpty()) {
        doctorName_ = other.doctorName_;
        onChanged();
      }
      if (!other.getRegistrationDate().isEmpty()) {
        registrationDate_ = other.registrationDate_;
        onChanged();
      }
      if (!other.getMedicalCardNo().isEmpty()) {
        medicalCardNo_ = other.medicalCardNo_;
        onChanged();
      }
      if (!other.getDoctorAdvice().isEmpty()) {
        doctorAdvice_ = other.doctorAdvice_;
        onChanged();
      }
      if (!other.getDeptName().isEmpty()) {
        deptName_ = other.deptName_;
        onChanged();
      }
      if (!other.getCheckInTime().isEmpty()) {
        checkInTime_ = other.checkInTime_;
        onChanged();
      }
      if (!other.getChiefComplaint().isEmpty()) {
        chiefComplaint_ = other.chiefComplaint_;
        onChanged();
      }
      if (!other.getPhysicalExam().isEmpty()) {
        physicalExam_ = other.physicalExam_;
        onChanged();
      }
      if (!other.getDiagnose().isEmpty()) {
        diagnose_ = other.diagnose_;
        onChanged();
      }
      if (!other.getSuggestion().isEmpty()) {
        suggestion_ = other.suggestion_;
        onChanged();
      }
      this.mergeUnknownFields(other.unknownFields);
      onChanged();
      return this;
    }

    @java.lang.Override
    public final boolean isInitialized() {
      return true;
    }

    @java.lang.Override
    public Builder mergeFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      com.ywt.gapi.third.taihe.MedicalRecord parsedMessage = null;
      try {
        parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        parsedMessage = (com.ywt.gapi.third.taihe.MedicalRecord) e.getUnfinishedMessage();
        throw e.unwrapIOException();
      } finally {
        if (parsedMessage != null) {
          mergeFrom(parsedMessage);
        }
      }
      return this;
    }

    private com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo_;
    private com.google.protobuf.SingleFieldBuilderV3<
        com.ywt.gapi.third.taihe.MedicalRecord.PatInfo, com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.Builder, com.ywt.gapi.third.taihe.MedicalRecord.PatInfoOrBuilder> patInfoBuilder_;
    /**
     * <pre>
     *患者信息
     * </pre>
     *
     * <code>.com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo = 1;</code>
     * @return Whether the patInfo field is set.
     */
    public boolean hasPatInfo() {
      return patInfoBuilder_ != null || patInfo_ != null;
    }
    /**
     * <pre>
     *患者信息
     * </pre>
     *
     * <code>.com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo = 1;</code>
     * @return The patInfo.
     */
    public com.ywt.gapi.third.taihe.MedicalRecord.PatInfo getPatInfo() {
      if (patInfoBuilder_ == null) {
        return patInfo_ == null ? com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.getDefaultInstance() : patInfo_;
      } else {
        return patInfoBuilder_.getMessage();
      }
    }
    /**
     * <pre>
     *患者信息
     * </pre>
     *
     * <code>.com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo = 1;</code>
     */
    public Builder setPatInfo(com.ywt.gapi.third.taihe.MedicalRecord.PatInfo value) {
      if (patInfoBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        patInfo_ = value;
        onChanged();
      } else {
        patInfoBuilder_.setMessage(value);
      }

      return this;
    }
    /**
     * <pre>
     *患者信息
     * </pre>
     *
     * <code>.com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo = 1;</code>
     */
    public Builder setPatInfo(
        com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.Builder builderForValue) {
      if (patInfoBuilder_ == null) {
        patInfo_ = builderForValue.build();
        onChanged();
      } else {
        patInfoBuilder_.setMessage(builderForValue.build());
      }

      return this;
    }
    /**
     * <pre>
     *患者信息
     * </pre>
     *
     * <code>.com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo = 1;</code>
     */
    public Builder mergePatInfo(com.ywt.gapi.third.taihe.MedicalRecord.PatInfo value) {
      if (patInfoBuilder_ == null) {
        if (patInfo_ != null) {
          patInfo_ =
            com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.newBuilder(patInfo_).mergeFrom(value).buildPartial();
        } else {
          patInfo_ = value;
        }
        onChanged();
      } else {
        patInfoBuilder_.mergeFrom(value);
      }

      return this;
    }
    /**
     * <pre>
     *患者信息
     * </pre>
     *
     * <code>.com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo = 1;</code>
     */
    public Builder clearPatInfo() {
      if (patInfoBuilder_ == null) {
        patInfo_ = null;
        onChanged();
      } else {
        patInfo_ = null;
        patInfoBuilder_ = null;
      }

      return this;
    }
    /**
     * <pre>
     *患者信息
     * </pre>
     *
     * <code>.com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo = 1;</code>
     */
    public com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.Builder getPatInfoBuilder() {
      
      onChanged();
      return getPatInfoFieldBuilder().getBuilder();
    }
    /**
     * <pre>
     *患者信息
     * </pre>
     *
     * <code>.com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo = 1;</code>
     */
    public com.ywt.gapi.third.taihe.MedicalRecord.PatInfoOrBuilder getPatInfoOrBuilder() {
      if (patInfoBuilder_ != null) {
        return patInfoBuilder_.getMessageOrBuilder();
      } else {
        return patInfo_ == null ?
            com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.getDefaultInstance() : patInfo_;
      }
    }
    /**
     * <pre>
     *患者信息
     * </pre>
     *
     * <code>.com.ywt.gapi.third.taihe.MedicalRecord.PatInfo patInfo = 1;</code>
     */
    private com.google.protobuf.SingleFieldBuilderV3<
        com.ywt.gapi.third.taihe.MedicalRecord.PatInfo, com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.Builder, com.ywt.gapi.third.taihe.MedicalRecord.PatInfoOrBuilder> 
        getPatInfoFieldBuilder() {
      if (patInfoBuilder_ == null) {
        patInfoBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
            com.ywt.gapi.third.taihe.MedicalRecord.PatInfo, com.ywt.gapi.third.taihe.MedicalRecord.PatInfo.Builder, com.ywt.gapi.third.taihe.MedicalRecord.PatInfoOrBuilder>(
                getPatInfo(),
                getParentForChildren(),
                isClean());
        patInfo_ = null;
      }
      return patInfoBuilder_;
    }

    private java.lang.Object doctorName_ = "";
    /**
     * <pre>
     *医生姓名
     * </pre>
     *
     * <code>string doctorName = 2;</code>
     * @return The doctorName.
     */
    public java.lang.String getDoctorName() {
      java.lang.Object ref = doctorName_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        doctorName_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     *医生姓名
     * </pre>
     *
     * <code>string doctorName = 2;</code>
     * @return The bytes for doctorName.
     */
    public com.google.protobuf.ByteString
        getDoctorNameBytes() {
      java.lang.Object ref = doctorName_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        doctorName_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     *医生姓名
     * </pre>
     *
     * <code>string doctorName = 2;</code>
     * @param value The doctorName to set.
     * @return This builder for chaining.
     */
    public Builder setDoctorName(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      doctorName_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *医生姓名
     * </pre>
     *
     * <code>string doctorName = 2;</code>
     * @return This builder for chaining.
     */
    public Builder clearDoctorName() {
      
      doctorName_ = getDefaultInstance().getDoctorName();
      onChanged();
      return this;
    }
    /**
     * <pre>
     *医生姓名
     * </pre>
     *
     * <code>string doctorName = 2;</code>
     * @param value The bytes for doctorName to set.
     * @return This builder for chaining.
     */
    public Builder setDoctorNameBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      doctorName_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object registrationDate_ = "";
    /**
     * <pre>
     *门诊时间
     * </pre>
     *
     * <code>string registrationDate = 3;</code>
     * @return The registrationDate.
     */
    public java.lang.String getRegistrationDate() {
      java.lang.Object ref = registrationDate_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        registrationDate_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     *门诊时间
     * </pre>
     *
     * <code>string registrationDate = 3;</code>
     * @return The bytes for registrationDate.
     */
    public com.google.protobuf.ByteString
        getRegistrationDateBytes() {
      java.lang.Object ref = registrationDate_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        registrationDate_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     *门诊时间
     * </pre>
     *
     * <code>string registrationDate = 3;</code>
     * @param value The registrationDate to set.
     * @return This builder for chaining.
     */
    public Builder setRegistrationDate(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      registrationDate_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *门诊时间
     * </pre>
     *
     * <code>string registrationDate = 3;</code>
     * @return This builder for chaining.
     */
    public Builder clearRegistrationDate() {
      
      registrationDate_ = getDefaultInstance().getRegistrationDate();
      onChanged();
      return this;
    }
    /**
     * <pre>
     *门诊时间
     * </pre>
     *
     * <code>string registrationDate = 3;</code>
     * @param value The bytes for registrationDate to set.
     * @return This builder for chaining.
     */
    public Builder setRegistrationDateBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      registrationDate_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object medicalCardNo_ = "";
    /**
     * <pre>
     *诊疗卡号
     * </pre>
     *
     * <code>string medicalCardNo = 4;</code>
     * @return The medicalCardNo.
     */
    public java.lang.String getMedicalCardNo() {
      java.lang.Object ref = medicalCardNo_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        medicalCardNo_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     *诊疗卡号
     * </pre>
     *
     * <code>string medicalCardNo = 4;</code>
     * @return The bytes for medicalCardNo.
     */
    public com.google.protobuf.ByteString
        getMedicalCardNoBytes() {
      java.lang.Object ref = medicalCardNo_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        medicalCardNo_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     *诊疗卡号
     * </pre>
     *
     * <code>string medicalCardNo = 4;</code>
     * @param value The medicalCardNo to set.
     * @return This builder for chaining.
     */
    public Builder setMedicalCardNo(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      medicalCardNo_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *诊疗卡号
     * </pre>
     *
     * <code>string medicalCardNo = 4;</code>
     * @return This builder for chaining.
     */
    public Builder clearMedicalCardNo() {
      
      medicalCardNo_ = getDefaultInstance().getMedicalCardNo();
      onChanged();
      return this;
    }
    /**
     * <pre>
     *诊疗卡号
     * </pre>
     *
     * <code>string medicalCardNo = 4;</code>
     * @param value The bytes for medicalCardNo to set.
     * @return This builder for chaining.
     */
    public Builder setMedicalCardNoBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      medicalCardNo_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object doctorAdvice_ = "";
    /**
     * <pre>
     *门/急诊医嘱
     * </pre>
     *
     * <code>string doctorAdvice = 5;</code>
     * @return The doctorAdvice.
     */
    public java.lang.String getDoctorAdvice() {
      java.lang.Object ref = doctorAdvice_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        doctorAdvice_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     *门/急诊医嘱
     * </pre>
     *
     * <code>string doctorAdvice = 5;</code>
     * @return The bytes for doctorAdvice.
     */
    public com.google.protobuf.ByteString
        getDoctorAdviceBytes() {
      java.lang.Object ref = doctorAdvice_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        doctorAdvice_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     *门/急诊医嘱
     * </pre>
     *
     * <code>string doctorAdvice = 5;</code>
     * @param value The doctorAdvice to set.
     * @return This builder for chaining.
     */
    public Builder setDoctorAdvice(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      doctorAdvice_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *门/急诊医嘱
     * </pre>
     *
     * <code>string doctorAdvice = 5;</code>
     * @return This builder for chaining.
     */
    public Builder clearDoctorAdvice() {
      
      doctorAdvice_ = getDefaultInstance().getDoctorAdvice();
      onChanged();
      return this;
    }
    /**
     * <pre>
     *门/急诊医嘱
     * </pre>
     *
     * <code>string doctorAdvice = 5;</code>
     * @param value The bytes for doctorAdvice to set.
     * @return This builder for chaining.
     */
    public Builder setDoctorAdviceBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      doctorAdvice_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object deptName_ = "";
    /**
     * <pre>
     *科室名称
     * </pre>
     *
     * <code>string deptName = 6;</code>
     * @return The deptName.
     */
    public java.lang.String getDeptName() {
      java.lang.Object ref = deptName_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        deptName_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     *科室名称
     * </pre>
     *
     * <code>string deptName = 6;</code>
     * @return The bytes for deptName.
     */
    public com.google.protobuf.ByteString
        getDeptNameBytes() {
      java.lang.Object ref = deptName_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        deptName_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     *科室名称
     * </pre>
     *
     * <code>string deptName = 6;</code>
     * @param value The deptName to set.
     * @return This builder for chaining.
     */
    public Builder setDeptName(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      deptName_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *科室名称
     * </pre>
     *
     * <code>string deptName = 6;</code>
     * @return This builder for chaining.
     */
    public Builder clearDeptName() {
      
      deptName_ = getDefaultInstance().getDeptName();
      onChanged();
      return this;
    }
    /**
     * <pre>
     *科室名称
     * </pre>
     *
     * <code>string deptName = 6;</code>
     * @param value The bytes for deptName to set.
     * @return This builder for chaining.
     */
    public Builder setDeptNameBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      deptName_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object checkInTime_ = "";
    /**
     * <pre>
     *患者入院日期
     * </pre>
     *
     * <code>string checkInTime = 7;</code>
     * @return The checkInTime.
     */
    public java.lang.String getCheckInTime() {
      java.lang.Object ref = checkInTime_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        checkInTime_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     *患者入院日期
     * </pre>
     *
     * <code>string checkInTime = 7;</code>
     * @return The bytes for checkInTime.
     */
    public com.google.protobuf.ByteString
        getCheckInTimeBytes() {
      java.lang.Object ref = checkInTime_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        checkInTime_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     *患者入院日期
     * </pre>
     *
     * <code>string checkInTime = 7;</code>
     * @param value The checkInTime to set.
     * @return This builder for chaining.
     */
    public Builder setCheckInTime(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      checkInTime_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *患者入院日期
     * </pre>
     *
     * <code>string checkInTime = 7;</code>
     * @return This builder for chaining.
     */
    public Builder clearCheckInTime() {
      
      checkInTime_ = getDefaultInstance().getCheckInTime();
      onChanged();
      return this;
    }
    /**
     * <pre>
     *患者入院日期
     * </pre>
     *
     * <code>string checkInTime = 7;</code>
     * @param value The bytes for checkInTime to set.
     * @return This builder for chaining.
     */
    public Builder setCheckInTimeBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      checkInTime_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object chiefComplaint_ = "";
    /**
     * <pre>
     *主诉
     * </pre>
     *
     * <code>string chiefComplaint = 8;</code>
     * @return The chiefComplaint.
     */
    public java.lang.String getChiefComplaint() {
      java.lang.Object ref = chiefComplaint_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        chiefComplaint_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     *主诉
     * </pre>
     *
     * <code>string chiefComplaint = 8;</code>
     * @return The bytes for chiefComplaint.
     */
    public com.google.protobuf.ByteString
        getChiefComplaintBytes() {
      java.lang.Object ref = chiefComplaint_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        chiefComplaint_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     *主诉
     * </pre>
     *
     * <code>string chiefComplaint = 8;</code>
     * @param value The chiefComplaint to set.
     * @return This builder for chaining.
     */
    public Builder setChiefComplaint(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      chiefComplaint_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *主诉
     * </pre>
     *
     * <code>string chiefComplaint = 8;</code>
     * @return This builder for chaining.
     */
    public Builder clearChiefComplaint() {
      
      chiefComplaint_ = getDefaultInstance().getChiefComplaint();
      onChanged();
      return this;
    }
    /**
     * <pre>
     *主诉
     * </pre>
     *
     * <code>string chiefComplaint = 8;</code>
     * @param value The bytes for chiefComplaint to set.
     * @return This builder for chaining.
     */
    public Builder setChiefComplaintBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      chiefComplaint_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object physicalExam_ = "";
    /**
     * <pre>
     *体格检查
     * </pre>
     *
     * <code>string physicalExam = 9;</code>
     * @return The physicalExam.
     */
    public java.lang.String getPhysicalExam() {
      java.lang.Object ref = physicalExam_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        physicalExam_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     *体格检查
     * </pre>
     *
     * <code>string physicalExam = 9;</code>
     * @return The bytes for physicalExam.
     */
    public com.google.protobuf.ByteString
        getPhysicalExamBytes() {
      java.lang.Object ref = physicalExam_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        physicalExam_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     *体格检查
     * </pre>
     *
     * <code>string physicalExam = 9;</code>
     * @param value The physicalExam to set.
     * @return This builder for chaining.
     */
    public Builder setPhysicalExam(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      physicalExam_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *体格检查
     * </pre>
     *
     * <code>string physicalExam = 9;</code>
     * @return This builder for chaining.
     */
    public Builder clearPhysicalExam() {
      
      physicalExam_ = getDefaultInstance().getPhysicalExam();
      onChanged();
      return this;
    }
    /**
     * <pre>
     *体格检查
     * </pre>
     *
     * <code>string physicalExam = 9;</code>
     * @param value The bytes for physicalExam to set.
     * @return This builder for chaining.
     */
    public Builder setPhysicalExamBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      physicalExam_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object diagnose_ = "";
    /**
     * <pre>
     *门诊诊断
     * </pre>
     *
     * <code>string diagnose = 10;</code>
     * @return The diagnose.
     */
    public java.lang.String getDiagnose() {
      java.lang.Object ref = diagnose_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        diagnose_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     *门诊诊断
     * </pre>
     *
     * <code>string diagnose = 10;</code>
     * @return The bytes for diagnose.
     */
    public com.google.protobuf.ByteString
        getDiagnoseBytes() {
      java.lang.Object ref = diagnose_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        diagnose_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     *门诊诊断
     * </pre>
     *
     * <code>string diagnose = 10;</code>
     * @param value The diagnose to set.
     * @return This builder for chaining.
     */
    public Builder setDiagnose(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      diagnose_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *门诊诊断
     * </pre>
     *
     * <code>string diagnose = 10;</code>
     * @return This builder for chaining.
     */
    public Builder clearDiagnose() {
      
      diagnose_ = getDefaultInstance().getDiagnose();
      onChanged();
      return this;
    }
    /**
     * <pre>
     *门诊诊断
     * </pre>
     *
     * <code>string diagnose = 10;</code>
     * @param value The bytes for diagnose to set.
     * @return This builder for chaining.
     */
    public Builder setDiagnoseBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      diagnose_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object suggestion_ = "";
    /**
     * <pre>
     *意见
     * </pre>
     *
     * <code>string suggestion = 11;</code>
     * @return The suggestion.
     */
    public java.lang.String getSuggestion() {
      java.lang.Object ref = suggestion_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        suggestion_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     *意见
     * </pre>
     *
     * <code>string suggestion = 11;</code>
     * @return The bytes for suggestion.
     */
    public com.google.protobuf.ByteString
        getSuggestionBytes() {
      java.lang.Object ref = suggestion_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        suggestion_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     *意见
     * </pre>
     *
     * <code>string suggestion = 11;</code>
     * @param value The suggestion to set.
     * @return This builder for chaining.
     */
    public Builder setSuggestion(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      suggestion_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *意见
     * </pre>
     *
     * <code>string suggestion = 11;</code>
     * @return This builder for chaining.
     */
    public Builder clearSuggestion() {
      
      suggestion_ = getDefaultInstance().getSuggestion();
      onChanged();
      return this;
    }
    /**
     * <pre>
     *意见
     * </pre>
     *
     * <code>string suggestion = 11;</code>
     * @param value The bytes for suggestion to set.
     * @return This builder for chaining.
     */
    public Builder setSuggestionBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      suggestion_ = value;
      onChanged();
      return this;
    }
    @java.lang.Override
    public final Builder setUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.setUnknownFields(unknownFields);
    }

    @java.lang.Override
    public final Builder mergeUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.mergeUnknownFields(unknownFields);
    }


    // @@protoc_insertion_point(builder_scope:com.ywt.gapi.third.taihe.MedicalRecord)
  }

  // @@protoc_insertion_point(class_scope:com.ywt.gapi.third.taihe.MedicalRecord)
  private static final com.ywt.gapi.third.taihe.MedicalRecord DEFAULT_INSTANCE;
  static {
    DEFAULT_INSTANCE = new com.ywt.gapi.third.taihe.MedicalRecord();
  }

  public static com.ywt.gapi.third.taihe.MedicalRecord getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

  private static final com.google.protobuf.Parser<MedicalRecord>
      PARSER = new com.google.protobuf.AbstractParser<MedicalRecord>() {
    @java.lang.Override
    public MedicalRecord parsePartialFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return new MedicalRecord(input, extensionRegistry);
    }
  };

  public static com.google.protobuf.Parser<MedicalRecord> parser() {
    return PARSER;
  }

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

  @java.lang.Override
  public com.ywt.gapi.third.taihe.MedicalRecord getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }

}

