// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: app/src/main/data/messageV2.proto
package com.example.administrator.mycc.proto;
public final class CcPacket {
private CcPacket() {}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistryLite registry) {
}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistry registry) {
registerAllExtensions(
(com.google.protobuf.ExtensionRegistryLite) registry);
}
public interface AuthPacketOrBuilder extends
// @@protoc_insertion_point(interface_extends:com.example.administrator.mycc.proto.AuthPacket)
com.google.protobuf.MessageOrBuilder {
/**
* <pre>
* 报文id
* </pre>
*
* <code>optional string messageId = 1;</code>
*/
boolean hasMessageId();
/**
* <pre>
* 报文id
* </pre>
*
* <code>optional string messageId = 1;</code>
*/
java.lang.String getMessageId();
/**
* <pre>
* 报文id
* </pre>
*
* <code>optional string messageId = 1;</code>
*/
com.google.protobuf.ByteString
getMessageIdBytes();
/**
* <pre>
* 协议版本
* </pre>
*
* <code>optional int32 version = 2 [default = 1];</code>
*/
boolean hasVersion();
/**
* <pre>
* 协议版本
* </pre>
*
* <code>optional int32 version = 2 [default = 1];</code>
*/
int getVersion();
/**
* <pre>
* 用户id
* </pre>
*
* <code>optional string userId = 3;</code>
*/
boolean hasUserId();
/**
* <pre>
* 用户id
* </pre>
*
* <code>optional string userId = 3;</code>
*/
java.lang.String getUserId();
/**
* <pre>
* 用户id
* </pre>
*
* <code>optional string userId = 3;</code>
*/
com.google.protobuf.ByteString
getUserIdBytes();
/**
* <pre>
* 验证令牌
* </pre>
*
* <code>optional string token = 4;</code>
*/
boolean hasToken();
/**
* <pre>
* 验证令牌
* </pre>
*
* <code>optional string token = 4;</code>
*/
java.lang.String getToken();
/**
* <pre>
* 验证令牌
* </pre>
*
* <code>optional string token = 4;</code>
*/
com.google.protobuf.ByteString
getTokenBytes();
}
/**
* <pre>
* 客户端新建连接时发送的第一个报文,用于验证客户端身份
* </pre>
*
* Protobuf type {@code com.example.administrator.mycc.proto.AuthPacket}
*/
public static final class AuthPacket extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:com.example.administrator.mycc.proto.AuthPacket)
AuthPacketOrBuilder {
private static final long serialVersionUID = 0L;
// Use AuthPacket.newBuilder() to construct.
private AuthPacket(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
super(builder);
}
private AuthPacket() {
messageId_ = "";
version_ = 1;
userId_ = "";
token_ = "";
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private AuthPacket(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
com.google.protobuf.ByteString bs = input.readBytes();
bitField0_ |= 0x00000001;
messageId_ = bs;
break;
}
case 16: {
bitField0_ |= 0x00000002;
version_ = input.readInt32();
break;
}
case 26: {
com.google.protobuf.ByteString bs = input.readBytes();
bitField0_ |= 0x00000004;
userId_ = bs;
break;
}
case 34: {
com.google.protobuf.ByteString bs = input.readBytes();
bitField0_ |= 0x00000008;
token_ = bs;
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.example.administrator.mycc.proto.CcPacket.internal_static_com_example_administrator_mycc_proto_AuthPacket_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.example.administrator.mycc.proto.CcPacket.internal_static_com_example_administrator_mycc_proto_AuthPacket_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.example.administrator.mycc.proto.CcPacket.AuthPacket.class, com.example.administrator.mycc.proto.CcPacket.AuthPacket.Builder.class);
}
private int bitField0_;
public static final int MESSAGEID_FIELD_NUMBER = 1;
private volatile java.lang.Object messageId_;
/**
* <pre>
* 报文id
* </pre>
*
* <code>optional string messageId = 1;</code>
*/
public boolean hasMessageId() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
* <pre>
* 报文id
* </pre>
*
* <code>optional string messageId = 1;</code>
*/
public java.lang.String getMessageId() {
java.lang.Object ref = messageId_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
if (bs.isValidUtf8()) {
messageId_ = s;
}
return s;
}
}
/**
* <pre>
* 报文id
* </pre>
*
* <code>optional string messageId = 1;</code>
*/
public com.google.protobuf.ByteString
getMessageIdBytes() {
java.lang.Object ref = messageId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
messageId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int VERSION_FIELD_NUMBER = 2;
private int version_;
/**
* <pre>
* 协议版本
* </pre>
*
* <code>optional int32 version = 2 [default = 1];</code>
*/
public boolean hasVersion() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
* <pre>
* 协议版本
* </pre>
*
* <code>optional int32 version = 2 [default = 1];</code>
*/
public int getVersion() {
return version_;
}