572 lines
19 KiB
Java
572 lines
19 KiB
Java
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
// source: msg.proto
|
|
|
|
package com.test.lalala;
|
|
|
|
public final class Msg {
|
|
private Msg() {}
|
|
public static void registerAllExtensions(
|
|
com.google.protobuf.ExtensionRegistry registry) {
|
|
}
|
|
public interface SearchRequestOrBuilder
|
|
extends com.google.protobuf.MessageOrBuilder {
|
|
|
|
// required string query = 1;
|
|
boolean hasQuery();
|
|
String getQuery();
|
|
|
|
// required int32 page_number = 2;
|
|
boolean hasPageNumber();
|
|
int getPageNumber();
|
|
|
|
// required int32 result_per_page = 3;
|
|
boolean hasResultPerPage();
|
|
int getResultPerPage();
|
|
}
|
|
public static final class SearchRequest extends
|
|
com.google.protobuf.GeneratedMessage
|
|
implements SearchRequestOrBuilder {
|
|
// Use SearchRequest.newBuilder() to construct.
|
|
private SearchRequest(Builder builder) {
|
|
super(builder);
|
|
}
|
|
private SearchRequest(boolean noInit) {}
|
|
|
|
private static final SearchRequest defaultInstance;
|
|
public static SearchRequest getDefaultInstance() {
|
|
return defaultInstance;
|
|
}
|
|
|
|
public SearchRequest getDefaultInstanceForType() {
|
|
return defaultInstance;
|
|
}
|
|
|
|
public static final com.google.protobuf.Descriptors.Descriptor
|
|
getDescriptor() {
|
|
return com.test.lalala.Msg.internal_static_com_test_lalala_SearchRequest_descriptor;
|
|
}
|
|
|
|
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
|
internalGetFieldAccessorTable() {
|
|
return com.test.lalala.Msg.internal_static_com_test_lalala_SearchRequest_fieldAccessorTable;
|
|
}
|
|
|
|
private int bitField0_;
|
|
// required string query = 1;
|
|
public static final int QUERY_FIELD_NUMBER = 1;
|
|
private java.lang.Object query_;
|
|
public boolean hasQuery() {
|
|
return ((bitField0_ & 0x00000001) == 0x00000001);
|
|
}
|
|
public String getQuery() {
|
|
java.lang.Object ref = query_;
|
|
if (ref instanceof String) {
|
|
return (String) ref;
|
|
} else {
|
|
com.google.protobuf.ByteString bs =
|
|
(com.google.protobuf.ByteString) ref;
|
|
String s = bs.toStringUtf8();
|
|
if (com.google.protobuf.Internal.isValidUtf8(bs)) {
|
|
query_ = s;
|
|
}
|
|
return s;
|
|
}
|
|
}
|
|
private com.google.protobuf.ByteString getQueryBytes() {
|
|
java.lang.Object ref = query_;
|
|
if (ref instanceof String) {
|
|
com.google.protobuf.ByteString b =
|
|
com.google.protobuf.ByteString.copyFromUtf8((String) ref);
|
|
query_ = b;
|
|
return b;
|
|
} else {
|
|
return (com.google.protobuf.ByteString) ref;
|
|
}
|
|
}
|
|
|
|
// required int32 page_number = 2;
|
|
public static final int PAGE_NUMBER_FIELD_NUMBER = 2;
|
|
private int pageNumber_;
|
|
public boolean hasPageNumber() {
|
|
return ((bitField0_ & 0x00000002) == 0x00000002);
|
|
}
|
|
public int getPageNumber() {
|
|
return pageNumber_;
|
|
}
|
|
|
|
// required int32 result_per_page = 3;
|
|
public static final int RESULT_PER_PAGE_FIELD_NUMBER = 3;
|
|
private int resultPerPage_;
|
|
public boolean hasResultPerPage() {
|
|
return ((bitField0_ & 0x00000004) == 0x00000004);
|
|
}
|
|
public int getResultPerPage() {
|
|
return resultPerPage_;
|
|
}
|
|
|
|
private void initFields() {
|
|
query_ = "";
|
|
pageNumber_ = 0;
|
|
resultPerPage_ = 0;
|
|
}
|
|
private byte memoizedIsInitialized = -1;
|
|
public final boolean isInitialized() {
|
|
byte isInitialized = memoizedIsInitialized;
|
|
if (isInitialized != -1) return isInitialized == 1;
|
|
|
|
if (!hasQuery()) {
|
|
memoizedIsInitialized = 0;
|
|
return false;
|
|
}
|
|
if (!hasPageNumber()) {
|
|
memoizedIsInitialized = 0;
|
|
return false;
|
|
}
|
|
if (!hasResultPerPage()) {
|
|
memoizedIsInitialized = 0;
|
|
return false;
|
|
}
|
|
memoizedIsInitialized = 1;
|
|
return true;
|
|
}
|
|
|
|
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
throws java.io.IOException {
|
|
getSerializedSize();
|
|
if (((bitField0_ & 0x00000001) == 0x00000001)) {
|
|
output.writeBytes(1, getQueryBytes());
|
|
}
|
|
if (((bitField0_ & 0x00000002) == 0x00000002)) {
|
|
output.writeInt32(2, pageNumber_);
|
|
}
|
|
if (((bitField0_ & 0x00000004) == 0x00000004)) {
|
|
output.writeInt32(3, resultPerPage_);
|
|
}
|
|
getUnknownFields().writeTo(output);
|
|
}
|
|
|
|
private int memoizedSerializedSize = -1;
|
|
public int getSerializedSize() {
|
|
int size = memoizedSerializedSize;
|
|
if (size != -1) return size;
|
|
|
|
size = 0;
|
|
if (((bitField0_ & 0x00000001) == 0x00000001)) {
|
|
size += com.google.protobuf.CodedOutputStream
|
|
.computeBytesSize(1, getQueryBytes());
|
|
}
|
|
if (((bitField0_ & 0x00000002) == 0x00000002)) {
|
|
size += com.google.protobuf.CodedOutputStream
|
|
.computeInt32Size(2, pageNumber_);
|
|
}
|
|
if (((bitField0_ & 0x00000004) == 0x00000004)) {
|
|
size += com.google.protobuf.CodedOutputStream
|
|
.computeInt32Size(3, resultPerPage_);
|
|
}
|
|
size += getUnknownFields().getSerializedSize();
|
|
memoizedSerializedSize = size;
|
|
return size;
|
|
}
|
|
|
|
private static final long serialVersionUID = 0L;
|
|
@java.lang.Override
|
|
protected java.lang.Object writeReplace()
|
|
throws java.io.ObjectStreamException {
|
|
return super.writeReplace();
|
|
}
|
|
|
|
public static com.test.lalala.Msg.SearchRequest parseFrom(
|
|
com.google.protobuf.ByteString data)
|
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
return newBuilder().mergeFrom(data).buildParsed();
|
|
}
|
|
public static com.test.lalala.Msg.SearchRequest parseFrom(
|
|
com.google.protobuf.ByteString data,
|
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
return newBuilder().mergeFrom(data, extensionRegistry)
|
|
.buildParsed();
|
|
}
|
|
public static com.test.lalala.Msg.SearchRequest parseFrom(byte[] data)
|
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
return newBuilder().mergeFrom(data).buildParsed();
|
|
}
|
|
public static com.test.lalala.Msg.SearchRequest parseFrom(
|
|
byte[] data,
|
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
return newBuilder().mergeFrom(data, extensionRegistry)
|
|
.buildParsed();
|
|
}
|
|
public static com.test.lalala.Msg.SearchRequest parseFrom(java.io.InputStream input)
|
|
throws java.io.IOException {
|
|
return newBuilder().mergeFrom(input).buildParsed();
|
|
}
|
|
public static com.test.lalala.Msg.SearchRequest parseFrom(
|
|
java.io.InputStream input,
|
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
throws java.io.IOException {
|
|
return newBuilder().mergeFrom(input, extensionRegistry)
|
|
.buildParsed();
|
|
}
|
|
public static com.test.lalala.Msg.SearchRequest parseDelimitedFrom(java.io.InputStream input)
|
|
throws java.io.IOException {
|
|
Builder builder = newBuilder();
|
|
if (builder.mergeDelimitedFrom(input)) {
|
|
return builder.buildParsed();
|
|
} else {
|
|
return null;
|
|
}
|
|
}
|
|
public static com.test.lalala.Msg.SearchRequest parseDelimitedFrom(
|
|
java.io.InputStream input,
|
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
throws java.io.IOException {
|
|
Builder builder = newBuilder();
|
|
if (builder.mergeDelimitedFrom(input, extensionRegistry)) {
|
|
return builder.buildParsed();
|
|
} else {
|
|
return null;
|
|
}
|
|
}
|
|
public static com.test.lalala.Msg.SearchRequest parseFrom(
|
|
com.google.protobuf.CodedInputStream input)
|
|
throws java.io.IOException {
|
|
return newBuilder().mergeFrom(input).buildParsed();
|
|
}
|
|
public static com.test.lalala.Msg.SearchRequest parseFrom(
|
|
com.google.protobuf.CodedInputStream input,
|
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
throws java.io.IOException {
|
|
return newBuilder().mergeFrom(input, extensionRegistry)
|
|
.buildParsed();
|
|
}
|
|
|
|
public static Builder newBuilder() { return Builder.create(); }
|
|
public Builder newBuilderForType() { return newBuilder(); }
|
|
public static Builder newBuilder(com.test.lalala.Msg.SearchRequest prototype) {
|
|
return newBuilder().mergeFrom(prototype);
|
|
}
|
|
public Builder toBuilder() { return newBuilder(this); }
|
|
|
|
@java.lang.Override
|
|
protected Builder newBuilderForType(
|
|
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
|
Builder builder = new Builder(parent);
|
|
return builder;
|
|
}
|
|
public static final class Builder extends
|
|
com.google.protobuf.GeneratedMessage.Builder<Builder>
|
|
implements com.test.lalala.Msg.SearchRequestOrBuilder {
|
|
public static final com.google.protobuf.Descriptors.Descriptor
|
|
getDescriptor() {
|
|
return com.test.lalala.Msg.internal_static_com_test_lalala_SearchRequest_descriptor;
|
|
}
|
|
|
|
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
|
internalGetFieldAccessorTable() {
|
|
return com.test.lalala.Msg.internal_static_com_test_lalala_SearchRequest_fieldAccessorTable;
|
|
}
|
|
|
|
// Construct using com.test.lalala.Msg.SearchRequest.newBuilder()
|
|
private Builder() {
|
|
maybeForceBuilderInitialization();
|
|
}
|
|
|
|
private Builder(BuilderParent parent) {
|
|
super(parent);
|
|
maybeForceBuilderInitialization();
|
|
}
|
|
private void maybeForceBuilderInitialization() {
|
|
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
|
}
|
|
}
|
|
private static Builder create() {
|
|
return new Builder();
|
|
}
|
|
|
|
public Builder clear() {
|
|
super.clear();
|
|
query_ = "";
|
|
bitField0_ = (bitField0_ & ~0x00000001);
|
|
pageNumber_ = 0;
|
|
bitField0_ = (bitField0_ & ~0x00000002);
|
|
resultPerPage_ = 0;
|
|
bitField0_ = (bitField0_ & ~0x00000004);
|
|
return this;
|
|
}
|
|
|
|
public Builder clone() {
|
|
return create().mergeFrom(buildPartial());
|
|
}
|
|
|
|
public com.google.protobuf.Descriptors.Descriptor
|
|
getDescriptorForType() {
|
|
return com.test.lalala.Msg.SearchRequest.getDescriptor();
|
|
}
|
|
|
|
public com.test.lalala.Msg.SearchRequest getDefaultInstanceForType() {
|
|
return com.test.lalala.Msg.SearchRequest.getDefaultInstance();
|
|
}
|
|
|
|
public com.test.lalala.Msg.SearchRequest build() {
|
|
com.test.lalala.Msg.SearchRequest result = buildPartial();
|
|
if (!result.isInitialized()) {
|
|
throw newUninitializedMessageException(result);
|
|
}
|
|
return result;
|
|
}
|
|
|
|
private com.test.lalala.Msg.SearchRequest buildParsed()
|
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
com.test.lalala.Msg.SearchRequest result = buildPartial();
|
|
if (!result.isInitialized()) {
|
|
throw newUninitializedMessageException(
|
|
result).asInvalidProtocolBufferException();
|
|
}
|
|
return result;
|
|
}
|
|
|
|
public com.test.lalala.Msg.SearchRequest buildPartial() {
|
|
com.test.lalala.Msg.SearchRequest result = new com.test.lalala.Msg.SearchRequest(this);
|
|
int from_bitField0_ = bitField0_;
|
|
int to_bitField0_ = 0;
|
|
if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
|
|
to_bitField0_ |= 0x00000001;
|
|
}
|
|
result.query_ = query_;
|
|
if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
|
|
to_bitField0_ |= 0x00000002;
|
|
}
|
|
result.pageNumber_ = pageNumber_;
|
|
if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
|
|
to_bitField0_ |= 0x00000004;
|
|
}
|
|
result.resultPerPage_ = resultPerPage_;
|
|
result.bitField0_ = to_bitField0_;
|
|
onBuilt();
|
|
return result;
|
|
}
|
|
|
|
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
if (other instanceof com.test.lalala.Msg.SearchRequest) {
|
|
return mergeFrom((com.test.lalala.Msg.SearchRequest)other);
|
|
} else {
|
|
super.mergeFrom(other);
|
|
return this;
|
|
}
|
|
}
|
|
|
|
public Builder mergeFrom(com.test.lalala.Msg.SearchRequest other) {
|
|
if (other == com.test.lalala.Msg.SearchRequest.getDefaultInstance()) return this;
|
|
if (other.hasQuery()) {
|
|
setQuery(other.getQuery());
|
|
}
|
|
if (other.hasPageNumber()) {
|
|
setPageNumber(other.getPageNumber());
|
|
}
|
|
if (other.hasResultPerPage()) {
|
|
setResultPerPage(other.getResultPerPage());
|
|
}
|
|
this.mergeUnknownFields(other.getUnknownFields());
|
|
return this;
|
|
}
|
|
|
|
public final boolean isInitialized() {
|
|
if (!hasQuery()) {
|
|
|
|
return false;
|
|
}
|
|
if (!hasPageNumber()) {
|
|
|
|
return false;
|
|
}
|
|
if (!hasResultPerPage()) {
|
|
|
|
return false;
|
|
}
|
|
return true;
|
|
}
|
|
|
|
public Builder mergeFrom(
|
|
com.google.protobuf.CodedInputStream input,
|
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
throws java.io.IOException {
|
|
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
com.google.protobuf.UnknownFieldSet.newBuilder(
|
|
this.getUnknownFields());
|
|
while (true) {
|
|
int tag = input.readTag();
|
|
switch (tag) {
|
|
case 0:
|
|
this.setUnknownFields(unknownFields.build());
|
|
onChanged();
|
|
return this;
|
|
default: {
|
|
if (!parseUnknownField(input, unknownFields,
|
|
extensionRegistry, tag)) {
|
|
this.setUnknownFields(unknownFields.build());
|
|
onChanged();
|
|
return this;
|
|
}
|
|
break;
|
|
}
|
|
case 10: {
|
|
bitField0_ |= 0x00000001;
|
|
query_ = input.readBytes();
|
|
break;
|
|
}
|
|
case 16: {
|
|
bitField0_ |= 0x00000002;
|
|
pageNumber_ = input.readInt32();
|
|
break;
|
|
}
|
|
case 24: {
|
|
bitField0_ |= 0x00000004;
|
|
resultPerPage_ = input.readInt32();
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
private int bitField0_;
|
|
|
|
// required string query = 1;
|
|
private java.lang.Object query_ = "";
|
|
public boolean hasQuery() {
|
|
return ((bitField0_ & 0x00000001) == 0x00000001);
|
|
}
|
|
public String getQuery() {
|
|
java.lang.Object ref = query_;
|
|
if (!(ref instanceof String)) {
|
|
String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
|
|
query_ = s;
|
|
return s;
|
|
} else {
|
|
return (String) ref;
|
|
}
|
|
}
|
|
public Builder setQuery(String value) {
|
|
if (value == null) {
|
|
throw new NullPointerException();
|
|
}
|
|
bitField0_ |= 0x00000001;
|
|
query_ = value;
|
|
onChanged();
|
|
return this;
|
|
}
|
|
public Builder clearQuery() {
|
|
bitField0_ = (bitField0_ & ~0x00000001);
|
|
query_ = getDefaultInstance().getQuery();
|
|
onChanged();
|
|
return this;
|
|
}
|
|
void setQuery(com.google.protobuf.ByteString value) {
|
|
bitField0_ |= 0x00000001;
|
|
query_ = value;
|
|
onChanged();
|
|
}
|
|
|
|
// required int32 page_number = 2;
|
|
private int pageNumber_ ;
|
|
public boolean hasPageNumber() {
|
|
return ((bitField0_ & 0x00000002) == 0x00000002);
|
|
}
|
|
public int getPageNumber() {
|
|
return pageNumber_;
|
|
}
|
|
public Builder setPageNumber(int value) {
|
|
bitField0_ |= 0x00000002;
|
|
pageNumber_ = value;
|
|
onChanged();
|
|
return this;
|
|
}
|
|
public Builder clearPageNumber() {
|
|
bitField0_ = (bitField0_ & ~0x00000002);
|
|
pageNumber_ = 0;
|
|
onChanged();
|
|
return this;
|
|
}
|
|
|
|
// required int32 result_per_page = 3;
|
|
private int resultPerPage_ ;
|
|
public boolean hasResultPerPage() {
|
|
return ((bitField0_ & 0x00000004) == 0x00000004);
|
|
}
|
|
public int getResultPerPage() {
|
|
return resultPerPage_;
|
|
}
|
|
public Builder setResultPerPage(int value) {
|
|
bitField0_ |= 0x00000004;
|
|
resultPerPage_ = value;
|
|
onChanged();
|
|
return this;
|
|
}
|
|
public Builder clearResultPerPage() {
|
|
bitField0_ = (bitField0_ & ~0x00000004);
|
|
resultPerPage_ = 0;
|
|
onChanged();
|
|
return this;
|
|
}
|
|
|
|
// @@protoc_insertion_point(builder_scope:com.test.lalala.SearchRequest)
|
|
}
|
|
|
|
static {
|
|
defaultInstance = new SearchRequest(true);
|
|
defaultInstance.initFields();
|
|
}
|
|
|
|
// @@protoc_insertion_point(class_scope:com.test.lalala.SearchRequest)
|
|
}
|
|
|
|
private static com.google.protobuf.Descriptors.Descriptor
|
|
internal_static_com_test_lalala_SearchRequest_descriptor;
|
|
private static
|
|
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
|
internal_static_com_test_lalala_SearchRequest_fieldAccessorTable;
|
|
|
|
public static com.google.protobuf.Descriptors.FileDescriptor
|
|
getDescriptor() {
|
|
return descriptor;
|
|
}
|
|
private static com.google.protobuf.Descriptors.FileDescriptor
|
|
descriptor;
|
|
static {
|
|
java.lang.String[] descriptorData = {
|
|
"\n\tmsg.proto\022\017com.test.lalala\032\020as3options" +
|
|
".proto\"L\n\rSearchRequest\022\r\n\005query\030\001 \002(\t\022\023" +
|
|
"\n\013page_number\030\002 \002(\005\022\027\n\017result_per_page\030\003" +
|
|
" \002(\005B\034\202\265\030\030com.netease.protocGenAs3"
|
|
};
|
|
com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
|
|
new com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner() {
|
|
public com.google.protobuf.ExtensionRegistry assignDescriptors(
|
|
com.google.protobuf.Descriptors.FileDescriptor root) {
|
|
descriptor = root;
|
|
internal_static_com_test_lalala_SearchRequest_descriptor =
|
|
getDescriptor().getMessageTypes().get(0);
|
|
internal_static_com_test_lalala_SearchRequest_fieldAccessorTable = new
|
|
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
|
internal_static_com_test_lalala_SearchRequest_descriptor,
|
|
new java.lang.String[] { "Query", "PageNumber", "ResultPerPage", },
|
|
com.test.lalala.Msg.SearchRequest.class,
|
|
com.test.lalala.Msg.SearchRequest.Builder.class);
|
|
com.google.protobuf.ExtensionRegistry registry =
|
|
com.google.protobuf.ExtensionRegistry.newInstance();
|
|
registerAllExtensions(registry);
|
|
as3.As3Options.registerAllExtensions(registry);
|
|
return registry;
|
|
}
|
|
};
|
|
com.google.protobuf.Descriptors.FileDescriptor
|
|
.internalBuildGeneratedFileFrom(descriptorData,
|
|
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
|
as3.As3Options.getDescriptor(),
|
|
}, assigner);
|
|
}
|
|
|
|
// @@protoc_insertion_point(outer_class_scope)
|
|
}
|