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

package com.ywt.gapi.system;

/**
 * Protobuf type {@code com.ywt.gapi.system.CacheKey}
 */
public final class CacheKey extends
    com.google.protobuf.GeneratedMessageV3 implements
    // @@protoc_insertion_point(message_implements:com.ywt.gapi.system.CacheKey)
    CacheKeyOrBuilder {
private static final long serialVersionUID = 0L;
  // Use CacheKey.newBuilder() to construct.
  private CacheKey(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
    super(builder);
  }
  private CacheKey() {
    keyName_ = "";
    methodName_ = "";
    alias_ = "";
    remark_ = "";
  }

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

  @java.lang.Override
  public final com.google.protobuf.UnknownFieldSet
  getUnknownFields() {
    return this.unknownFields;
  }
  private CacheKey(
      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 8: {

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

            keyName_ = s;
            break;
          }
          case 24: {

            cacheType_ = input.readInt32();
            break;
          }
          case 32: {

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

            methodName_ = s;
            break;
          }
          case 48: {

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

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

            remark_ = 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.system.SystemProto.internal_static_com_ywt_gapi_system_CacheKey_descriptor;
  }

  @java.lang.Override
  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return com.ywt.gapi.system.SystemProto.internal_static_com_ywt_gapi_system_CacheKey_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            com.ywt.gapi.system.CacheKey.class, com.ywt.gapi.system.CacheKey.Builder.class);
  }

  public static final int ID_FIELD_NUMBER = 1;
  private int id_;
  /**
   * <code>int32 id = 1;</code>
   * @return The id.
   */
  @java.lang.Override
  public int getId() {
    return id_;
  }

  public static final int KEYNAME_FIELD_NUMBER = 2;
  private volatile java.lang.Object keyName_;
  /**
   * <pre>
   * 缓存键名称
   * </pre>
   *
   * <code>string keyName = 2;</code>
   * @return The keyName.
   */
  @java.lang.Override
  public java.lang.String getKeyName() {
    java.lang.Object ref = keyName_;
    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();
      keyName_ = s;
      return s;
    }
  }
  /**
   * <pre>
   * 缓存键名称
   * </pre>
   *
   * <code>string keyName = 2;</code>
   * @return The bytes for keyName.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getKeyNameBytes() {
    java.lang.Object ref = keyName_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      keyName_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int CACHETYPE_FIELD_NUMBER = 3;
  private int cacheType_;
  /**
   * <pre>
   * 缓存类型：0-GuavaCache, 1-Redis
   * </pre>
   *
   * <code>int32 cacheType = 3;</code>
   * @return The cacheType.
   */
  @java.lang.Override
  public int getCacheType() {
    return cacheType_;
  }

  public static final int CALLTYPE_FIELD_NUMBER = 4;
  private int callType_;
  /**
   * <pre>
   * 调用方式：0-local, 1-grpc, 2-rest
   * </pre>
   *
   * <code>int32 callType = 4;</code>
   * @return The callType.
   */
  @java.lang.Override
  public int getCallType() {
    return callType_;
  }

  public static final int METHODNAME_FIELD_NUMBER = 5;
  private volatile java.lang.Object methodName_;
  /**
   * <pre>
   * grpc/rest 调用需要指定服务方法名称
   * </pre>
   *
   * <code>string methodName = 5;</code>
   * @return The methodName.
   */
  @java.lang.Override
  public java.lang.String getMethodName() {
    java.lang.Object ref = methodName_;
    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();
      methodName_ = s;
      return s;
    }
  }
  /**
   * <pre>
   * grpc/rest 调用需要指定服务方法名称
   * </pre>
   *
   * <code>string methodName = 5;</code>
   * @return The bytes for methodName.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getMethodNameBytes() {
    java.lang.Object ref = methodName_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      methodName_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int KEYTYPE_FIELD_NUMBER = 6;
  private int keyType_;
  /**
   * <pre>
   * 键匹配模式：0-match, 1-pattern
   * </pre>
   *
   * <code>int32 keyType = 6;</code>
   * @return The keyType.
   */
  @java.lang.Override
  public int getKeyType() {
    return keyType_;
  }

  public static final int ALIAS_FIELD_NUMBER = 7;
  private volatile java.lang.Object alias_;
  /**
   * <pre>
   * 别名
   * </pre>
   *
   * <code>string alias = 7;</code>
   * @return The alias.
   */
  @java.lang.Override
  public java.lang.String getAlias() {
    java.lang.Object ref = alias_;
    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();
      alias_ = s;
      return s;
    }
  }
  /**
   * <pre>
   * 别名
   * </pre>
   *
   * <code>string alias = 7;</code>
   * @return The bytes for alias.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getAliasBytes() {
    java.lang.Object ref = alias_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      alias_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int REMARK_FIELD_NUMBER = 8;
  private volatile java.lang.Object remark_;
  /**
   * <pre>
   * 备注
   * </pre>
   *
   * <code>string remark = 8;</code>
   * @return The remark.
   */
  @java.lang.Override
  public java.lang.String getRemark() {
    java.lang.Object ref = remark_;
    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();
      remark_ = s;
      return s;
    }
  }
  /**
   * <pre>
   * 备注
   * </pre>
   *
   * <code>string remark = 8;</code>
   * @return The bytes for remark.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getRemarkBytes() {
    java.lang.Object ref = remark_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      remark_ = 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 (id_ != 0) {
      output.writeInt32(1, id_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(keyName_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 2, keyName_);
    }
    if (cacheType_ != 0) {
      output.writeInt32(3, cacheType_);
    }
    if (callType_ != 0) {
      output.writeInt32(4, callType_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(methodName_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 5, methodName_);
    }
    if (keyType_ != 0) {
      output.writeInt32(6, keyType_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(alias_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 7, alias_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(remark_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 8, remark_);
    }
    unknownFields.writeTo(output);
  }

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

    size = 0;
    if (id_ != 0) {
      size += com.google.protobuf.CodedOutputStream
        .computeInt32Size(1, id_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(keyName_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, keyName_);
    }
    if (cacheType_ != 0) {
      size += com.google.protobuf.CodedOutputStream
        .computeInt32Size(3, cacheType_);
    }
    if (callType_ != 0) {
      size += com.google.protobuf.CodedOutputStream
        .computeInt32Size(4, callType_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(methodName_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, methodName_);
    }
    if (keyType_ != 0) {
      size += com.google.protobuf.CodedOutputStream
        .computeInt32Size(6, keyType_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(alias_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, alias_);
    }
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(remark_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, remark_);
    }
    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.system.CacheKey)) {
      return super.equals(obj);
    }
    com.ywt.gapi.system.CacheKey other = (com.ywt.gapi.system.CacheKey) obj;

    if (getId()
        != other.getId()) return false;
    if (!getKeyName()
        .equals(other.getKeyName())) return false;
    if (getCacheType()
        != other.getCacheType()) return false;
    if (getCallType()
        != other.getCallType()) return false;
    if (!getMethodName()
        .equals(other.getMethodName())) return false;
    if (getKeyType()
        != other.getKeyType()) return false;
    if (!getAlias()
        .equals(other.getAlias())) return false;
    if (!getRemark()
        .equals(other.getRemark())) 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) + ID_FIELD_NUMBER;
    hash = (53 * hash) + getId();
    hash = (37 * hash) + KEYNAME_FIELD_NUMBER;
    hash = (53 * hash) + getKeyName().hashCode();
    hash = (37 * hash) + CACHETYPE_FIELD_NUMBER;
    hash = (53 * hash) + getCacheType();
    hash = (37 * hash) + CALLTYPE_FIELD_NUMBER;
    hash = (53 * hash) + getCallType();
    hash = (37 * hash) + METHODNAME_FIELD_NUMBER;
    hash = (53 * hash) + getMethodName().hashCode();
    hash = (37 * hash) + KEYTYPE_FIELD_NUMBER;
    hash = (53 * hash) + getKeyType();
    hash = (37 * hash) + ALIAS_FIELD_NUMBER;
    hash = (53 * hash) + getAlias().hashCode();
    hash = (37 * hash) + REMARK_FIELD_NUMBER;
    hash = (53 * hash) + getRemark().hashCode();
    hash = (29 * hash) + unknownFields.hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static com.ywt.gapi.system.CacheKey parseFrom(
      java.nio.ByteBuffer data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.ywt.gapi.system.CacheKey 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.system.CacheKey parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.ywt.gapi.system.CacheKey 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.system.CacheKey parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.ywt.gapi.system.CacheKey parseFrom(
      byte[] data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.ywt.gapi.system.CacheKey parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static com.ywt.gapi.system.CacheKey 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.system.CacheKey parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input);
  }
  public static com.ywt.gapi.system.CacheKey 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.system.CacheKey parseFrom(
      com.google.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static com.ywt.gapi.system.CacheKey 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.system.CacheKey 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;
  }
  /**
   * Protobuf type {@code com.ywt.gapi.system.CacheKey}
   */
  public static final class Builder extends
      com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
      // @@protoc_insertion_point(builder_implements:com.ywt.gapi.system.CacheKey)
      com.ywt.gapi.system.CacheKeyOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return com.ywt.gapi.system.SystemProto.internal_static_com_ywt_gapi_system_CacheKey_descriptor;
    }

    @java.lang.Override
    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.ywt.gapi.system.SystemProto.internal_static_com_ywt_gapi_system_CacheKey_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.ywt.gapi.system.CacheKey.class, com.ywt.gapi.system.CacheKey.Builder.class);
    }

    // Construct using com.ywt.gapi.system.CacheKey.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();
      id_ = 0;

      keyName_ = "";

      cacheType_ = 0;

      callType_ = 0;

      methodName_ = "";

      keyType_ = 0;

      alias_ = "";

      remark_ = "";

      return this;
    }

    @java.lang.Override
    public com.google.protobuf.Descriptors.Descriptor
        getDescriptorForType() {
      return com.ywt.gapi.system.SystemProto.internal_static_com_ywt_gapi_system_CacheKey_descriptor;
    }

    @java.lang.Override
    public com.ywt.gapi.system.CacheKey getDefaultInstanceForType() {
      return com.ywt.gapi.system.CacheKey.getDefaultInstance();
    }

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

    @java.lang.Override
    public com.ywt.gapi.system.CacheKey buildPartial() {
      com.ywt.gapi.system.CacheKey result = new com.ywt.gapi.system.CacheKey(this);
      result.id_ = id_;
      result.keyName_ = keyName_;
      result.cacheType_ = cacheType_;
      result.callType_ = callType_;
      result.methodName_ = methodName_;
      result.keyType_ = keyType_;
      result.alias_ = alias_;
      result.remark_ = remark_;
      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.system.CacheKey) {
        return mergeFrom((com.ywt.gapi.system.CacheKey)other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(com.ywt.gapi.system.CacheKey other) {
      if (other == com.ywt.gapi.system.CacheKey.getDefaultInstance()) return this;
      if (other.getId() != 0) {
        setId(other.getId());
      }
      if (!other.getKeyName().isEmpty()) {
        keyName_ = other.keyName_;
        onChanged();
      }
      if (other.getCacheType() != 0) {
        setCacheType(other.getCacheType());
      }
      if (other.getCallType() != 0) {
        setCallType(other.getCallType());
      }
      if (!other.getMethodName().isEmpty()) {
        methodName_ = other.methodName_;
        onChanged();
      }
      if (other.getKeyType() != 0) {
        setKeyType(other.getKeyType());
      }
      if (!other.getAlias().isEmpty()) {
        alias_ = other.alias_;
        onChanged();
      }
      if (!other.getRemark().isEmpty()) {
        remark_ = other.remark_;
        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.system.CacheKey parsedMessage = null;
      try {
        parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        parsedMessage = (com.ywt.gapi.system.CacheKey) e.getUnfinishedMessage();
        throw e.unwrapIOException();
      } finally {
        if (parsedMessage != null) {
          mergeFrom(parsedMessage);
        }
      }
      return this;
    }

    private int id_ ;
    /**
     * <code>int32 id = 1;</code>
     * @return The id.
     */
    @java.lang.Override
    public int getId() {
      return id_;
    }
    /**
     * <code>int32 id = 1;</code>
     * @param value The id to set.
     * @return This builder for chaining.
     */
    public Builder setId(int value) {
      
      id_ = value;
      onChanged();
      return this;
    }
    /**
     * <code>int32 id = 1;</code>
     * @return This builder for chaining.
     */
    public Builder clearId() {
      
      id_ = 0;
      onChanged();
      return this;
    }

    private java.lang.Object keyName_ = "";
    /**
     * <pre>
     * 缓存键名称
     * </pre>
     *
     * <code>string keyName = 2;</code>
     * @return The keyName.
     */
    public java.lang.String getKeyName() {
      java.lang.Object ref = keyName_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        keyName_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     * 缓存键名称
     * </pre>
     *
     * <code>string keyName = 2;</code>
     * @return The bytes for keyName.
     */
    public com.google.protobuf.ByteString
        getKeyNameBytes() {
      java.lang.Object ref = keyName_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        keyName_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     * 缓存键名称
     * </pre>
     *
     * <code>string keyName = 2;</code>
     * @param value The keyName to set.
     * @return This builder for chaining.
     */
    public Builder setKeyName(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      keyName_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     * 缓存键名称
     * </pre>
     *
     * <code>string keyName = 2;</code>
     * @return This builder for chaining.
     */
    public Builder clearKeyName() {
      
      keyName_ = getDefaultInstance().getKeyName();
      onChanged();
      return this;
    }
    /**
     * <pre>
     * 缓存键名称
     * </pre>
     *
     * <code>string keyName = 2;</code>
     * @param value The bytes for keyName to set.
     * @return This builder for chaining.
     */
    public Builder setKeyNameBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      keyName_ = value;
      onChanged();
      return this;
    }

    private int cacheType_ ;
    /**
     * <pre>
     * 缓存类型：0-GuavaCache, 1-Redis
     * </pre>
     *
     * <code>int32 cacheType = 3;</code>
     * @return The cacheType.
     */
    @java.lang.Override
    public int getCacheType() {
      return cacheType_;
    }
    /**
     * <pre>
     * 缓存类型：0-GuavaCache, 1-Redis
     * </pre>
     *
     * <code>int32 cacheType = 3;</code>
     * @param value The cacheType to set.
     * @return This builder for chaining.
     */
    public Builder setCacheType(int value) {
      
      cacheType_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     * 缓存类型：0-GuavaCache, 1-Redis
     * </pre>
     *
     * <code>int32 cacheType = 3;</code>
     * @return This builder for chaining.
     */
    public Builder clearCacheType() {
      
      cacheType_ = 0;
      onChanged();
      return this;
    }

    private int callType_ ;
    /**
     * <pre>
     * 调用方式：0-local, 1-grpc, 2-rest
     * </pre>
     *
     * <code>int32 callType = 4;</code>
     * @return The callType.
     */
    @java.lang.Override
    public int getCallType() {
      return callType_;
    }
    /**
     * <pre>
     * 调用方式：0-local, 1-grpc, 2-rest
     * </pre>
     *
     * <code>int32 callType = 4;</code>
     * @param value The callType to set.
     * @return This builder for chaining.
     */
    public Builder setCallType(int value) {
      
      callType_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     * 调用方式：0-local, 1-grpc, 2-rest
     * </pre>
     *
     * <code>int32 callType = 4;</code>
     * @return This builder for chaining.
     */
    public Builder clearCallType() {
      
      callType_ = 0;
      onChanged();
      return this;
    }

    private java.lang.Object methodName_ = "";
    /**
     * <pre>
     * grpc/rest 调用需要指定服务方法名称
     * </pre>
     *
     * <code>string methodName = 5;</code>
     * @return The methodName.
     */
    public java.lang.String getMethodName() {
      java.lang.Object ref = methodName_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        methodName_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     * grpc/rest 调用需要指定服务方法名称
     * </pre>
     *
     * <code>string methodName = 5;</code>
     * @return The bytes for methodName.
     */
    public com.google.protobuf.ByteString
        getMethodNameBytes() {
      java.lang.Object ref = methodName_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        methodName_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     * grpc/rest 调用需要指定服务方法名称
     * </pre>
     *
     * <code>string methodName = 5;</code>
     * @param value The methodName to set.
     * @return This builder for chaining.
     */
    public Builder setMethodName(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      methodName_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     * grpc/rest 调用需要指定服务方法名称
     * </pre>
     *
     * <code>string methodName = 5;</code>
     * @return This builder for chaining.
     */
    public Builder clearMethodName() {
      
      methodName_ = getDefaultInstance().getMethodName();
      onChanged();
      return this;
    }
    /**
     * <pre>
     * grpc/rest 调用需要指定服务方法名称
     * </pre>
     *
     * <code>string methodName = 5;</code>
     * @param value The bytes for methodName to set.
     * @return This builder for chaining.
     */
    public Builder setMethodNameBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      methodName_ = value;
      onChanged();
      return this;
    }

    private int keyType_ ;
    /**
     * <pre>
     * 键匹配模式：0-match, 1-pattern
     * </pre>
     *
     * <code>int32 keyType = 6;</code>
     * @return The keyType.
     */
    @java.lang.Override
    public int getKeyType() {
      return keyType_;
    }
    /**
     * <pre>
     * 键匹配模式：0-match, 1-pattern
     * </pre>
     *
     * <code>int32 keyType = 6;</code>
     * @param value The keyType to set.
     * @return This builder for chaining.
     */
    public Builder setKeyType(int value) {
      
      keyType_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     * 键匹配模式：0-match, 1-pattern
     * </pre>
     *
     * <code>int32 keyType = 6;</code>
     * @return This builder for chaining.
     */
    public Builder clearKeyType() {
      
      keyType_ = 0;
      onChanged();
      return this;
    }

    private java.lang.Object alias_ = "";
    /**
     * <pre>
     * 别名
     * </pre>
     *
     * <code>string alias = 7;</code>
     * @return The alias.
     */
    public java.lang.String getAlias() {
      java.lang.Object ref = alias_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        alias_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     * 别名
     * </pre>
     *
     * <code>string alias = 7;</code>
     * @return The bytes for alias.
     */
    public com.google.protobuf.ByteString
        getAliasBytes() {
      java.lang.Object ref = alias_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        alias_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     * 别名
     * </pre>
     *
     * <code>string alias = 7;</code>
     * @param value The alias to set.
     * @return This builder for chaining.
     */
    public Builder setAlias(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      alias_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     * 别名
     * </pre>
     *
     * <code>string alias = 7;</code>
     * @return This builder for chaining.
     */
    public Builder clearAlias() {
      
      alias_ = getDefaultInstance().getAlias();
      onChanged();
      return this;
    }
    /**
     * <pre>
     * 别名
     * </pre>
     *
     * <code>string alias = 7;</code>
     * @param value The bytes for alias to set.
     * @return This builder for chaining.
     */
    public Builder setAliasBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      alias_ = value;
      onChanged();
      return this;
    }

    private java.lang.Object remark_ = "";
    /**
     * <pre>
     * 备注
     * </pre>
     *
     * <code>string remark = 8;</code>
     * @return The remark.
     */
    public java.lang.String getRemark() {
      java.lang.Object ref = remark_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        remark_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     * 备注
     * </pre>
     *
     * <code>string remark = 8;</code>
     * @return The bytes for remark.
     */
    public com.google.protobuf.ByteString
        getRemarkBytes() {
      java.lang.Object ref = remark_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        remark_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     * 备注
     * </pre>
     *
     * <code>string remark = 8;</code>
     * @param value The remark to set.
     * @return This builder for chaining.
     */
    public Builder setRemark(
        java.lang.String value) {
      if (value == null) {
    throw new NullPointerException();
  }
  
      remark_ = value;
      onChanged();
      return this;
    }
    /**
     * <pre>
     * 备注
     * </pre>
     *
     * <code>string remark = 8;</code>
     * @return This builder for chaining.
     */
    public Builder clearRemark() {
      
      remark_ = getDefaultInstance().getRemark();
      onChanged();
      return this;
    }
    /**
     * <pre>
     * 备注
     * </pre>
     *
     * <code>string remark = 8;</code>
     * @param value The bytes for remark to set.
     * @return This builder for chaining.
     */
    public Builder setRemarkBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) {
    throw new NullPointerException();
  }
  checkByteStringIsUtf8(value);
      
      remark_ = 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.system.CacheKey)
  }

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

  public static com.ywt.gapi.system.CacheKey getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

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

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

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

  @java.lang.Override
  public com.ywt.gapi.system.CacheKey getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }

}

