wechaty-grpc
Version:
gRPC for Wechaty
1,293 lines (1,118 loc) • 42.2 kB
JavaScript
// source: wechaty/puppet/tag.proto
/**
* @fileoverview
* @enhanceable
* @suppress {missingRequire} reports error on implicit type usages.
* @suppress {messageConventions} JS Compiler reports an error if a variable or
* field starts with 'MSG_' and isn't a translatable message.
* @public
*/
// GENERATED CODE -- DO NOT EDIT!
/* eslint-disable */
// @ts-nocheck
var jspb = require('google-protobuf');
var goog = jspb;
var global = (function() {
if (this) { return this; }
if (typeof window !== 'undefined') { return window; }
if (typeof global !== 'undefined') { return global; }
if (typeof self !== 'undefined') { return self; }
return Function('return this')();
}.call(null));
var google_protobuf_wrappers_pb = require('google-protobuf/google/protobuf/wrappers_pb.js');
goog.object.extend(proto, google_protobuf_wrappers_pb);
goog.exportSymbol('proto.wechaty.puppet.TagContactAddRequest', null, global);
goog.exportSymbol('proto.wechaty.puppet.TagContactAddResponse', null, global);
goog.exportSymbol('proto.wechaty.puppet.TagContactDeleteRequest', null, global);
goog.exportSymbol('proto.wechaty.puppet.TagContactDeleteResponse', null, global);
goog.exportSymbol('proto.wechaty.puppet.TagContactListRequest', null, global);
goog.exportSymbol('proto.wechaty.puppet.TagContactListResponse', null, global);
goog.exportSymbol('proto.wechaty.puppet.TagContactRemoveRequest', null, global);
goog.exportSymbol('proto.wechaty.puppet.TagContactRemoveResponse', null, global);
/**
* Generated by JsPbCodeGenerator.
* @param {Array=} opt_data Optional initial data array, typically from a
* server response, or constructed directly in Javascript. The array is used
* in place and becomes part of the constructed object. It is not cloned.
* If no data is provided, the constructed object will be empty, but still
* valid.
* @extends {jspb.Message}
* @constructor
*/
proto.wechaty.puppet.TagContactAddRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.wechaty.puppet.TagContactAddRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.wechaty.puppet.TagContactAddRequest.displayName = 'proto.wechaty.puppet.TagContactAddRequest';
}
/**
* Generated by JsPbCodeGenerator.
* @param {Array=} opt_data Optional initial data array, typically from a
* server response, or constructed directly in Javascript. The array is used
* in place and becomes part of the constructed object. It is not cloned.
* If no data is provided, the constructed object will be empty, but still
* valid.
* @extends {jspb.Message}
* @constructor
*/
proto.wechaty.puppet.TagContactAddResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.wechaty.puppet.TagContactAddResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.wechaty.puppet.TagContactAddResponse.displayName = 'proto.wechaty.puppet.TagContactAddResponse';
}
/**
* Generated by JsPbCodeGenerator.
* @param {Array=} opt_data Optional initial data array, typically from a
* server response, or constructed directly in Javascript. The array is used
* in place and becomes part of the constructed object. It is not cloned.
* If no data is provided, the constructed object will be empty, but still
* valid.
* @extends {jspb.Message}
* @constructor
*/
proto.wechaty.puppet.TagContactRemoveRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.wechaty.puppet.TagContactRemoveRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.wechaty.puppet.TagContactRemoveRequest.displayName = 'proto.wechaty.puppet.TagContactRemoveRequest';
}
/**
* Generated by JsPbCodeGenerator.
* @param {Array=} opt_data Optional initial data array, typically from a
* server response, or constructed directly in Javascript. The array is used
* in place and becomes part of the constructed object. It is not cloned.
* If no data is provided, the constructed object will be empty, but still
* valid.
* @extends {jspb.Message}
* @constructor
*/
proto.wechaty.puppet.TagContactRemoveResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.wechaty.puppet.TagContactRemoveResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.wechaty.puppet.TagContactRemoveResponse.displayName = 'proto.wechaty.puppet.TagContactRemoveResponse';
}
/**
* Generated by JsPbCodeGenerator.
* @param {Array=} opt_data Optional initial data array, typically from a
* server response, or constructed directly in Javascript. The array is used
* in place and becomes part of the constructed object. It is not cloned.
* If no data is provided, the constructed object will be empty, but still
* valid.
* @extends {jspb.Message}
* @constructor
*/
proto.wechaty.puppet.TagContactDeleteRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.wechaty.puppet.TagContactDeleteRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.wechaty.puppet.TagContactDeleteRequest.displayName = 'proto.wechaty.puppet.TagContactDeleteRequest';
}
/**
* Generated by JsPbCodeGenerator.
* @param {Array=} opt_data Optional initial data array, typically from a
* server response, or constructed directly in Javascript. The array is used
* in place and becomes part of the constructed object. It is not cloned.
* If no data is provided, the constructed object will be empty, but still
* valid.
* @extends {jspb.Message}
* @constructor
*/
proto.wechaty.puppet.TagContactDeleteResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.wechaty.puppet.TagContactDeleteResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.wechaty.puppet.TagContactDeleteResponse.displayName = 'proto.wechaty.puppet.TagContactDeleteResponse';
}
/**
* Generated by JsPbCodeGenerator.
* @param {Array=} opt_data Optional initial data array, typically from a
* server response, or constructed directly in Javascript. The array is used
* in place and becomes part of the constructed object. It is not cloned.
* If no data is provided, the constructed object will be empty, but still
* valid.
* @extends {jspb.Message}
* @constructor
*/
proto.wechaty.puppet.TagContactListRequest = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, null, null);
};
goog.inherits(proto.wechaty.puppet.TagContactListRequest, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.wechaty.puppet.TagContactListRequest.displayName = 'proto.wechaty.puppet.TagContactListRequest';
}
/**
* Generated by JsPbCodeGenerator.
* @param {Array=} opt_data Optional initial data array, typically from a
* server response, or constructed directly in Javascript. The array is used
* in place and becomes part of the constructed object. It is not cloned.
* If no data is provided, the constructed object will be empty, but still
* valid.
* @extends {jspb.Message}
* @constructor
*/
proto.wechaty.puppet.TagContactListResponse = function(opt_data) {
jspb.Message.initialize(this, opt_data, 0, -1, proto.wechaty.puppet.TagContactListResponse.repeatedFields_, null);
};
goog.inherits(proto.wechaty.puppet.TagContactListResponse, jspb.Message);
if (goog.DEBUG && !COMPILED) {
/**
* @public
* @override
*/
proto.wechaty.puppet.TagContactListResponse.displayName = 'proto.wechaty.puppet.TagContactListResponse';
}
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.wechaty.puppet.TagContactAddRequest.prototype.toObject = function(opt_includeInstance) {
return proto.wechaty.puppet.TagContactAddRequest.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
* the JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.wechaty.puppet.TagContactAddRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactAddRequest.toObject = function(includeInstance, msg) {
var f, obj = {
id: jspb.Message.getFieldWithDefault(msg, 1, ""),
contactId: jspb.Message.getFieldWithDefault(msg, 2, "")
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.wechaty.puppet.TagContactAddRequest}
*/
proto.wechaty.puppet.TagContactAddRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.wechaty.puppet.TagContactAddRequest;
return proto.wechaty.puppet.TagContactAddRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.wechaty.puppet.TagContactAddRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.wechaty.puppet.TagContactAddRequest}
*/
proto.wechaty.puppet.TagContactAddRequest.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = /** @type {string} */ (reader.readString());
msg.setId(value);
break;
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setContactId(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.wechaty.puppet.TagContactAddRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.wechaty.puppet.TagContactAddRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.wechaty.puppet.TagContactAddRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactAddRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getId();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getContactId();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
};
/**
* optional string id = 1;
* @return {string}
*/
proto.wechaty.puppet.TagContactAddRequest.prototype.getId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.wechaty.puppet.TagContactAddRequest} returns this
*/
proto.wechaty.puppet.TagContactAddRequest.prototype.setId = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
/**
* optional string contact_id = 2;
* @return {string}
*/
proto.wechaty.puppet.TagContactAddRequest.prototype.getContactId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/**
* @param {string} value
* @return {!proto.wechaty.puppet.TagContactAddRequest} returns this
*/
proto.wechaty.puppet.TagContactAddRequest.prototype.setContactId = function(value) {
return jspb.Message.setProto3StringField(this, 2, value);
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.wechaty.puppet.TagContactAddResponse.prototype.toObject = function(opt_includeInstance) {
return proto.wechaty.puppet.TagContactAddResponse.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
* the JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.wechaty.puppet.TagContactAddResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactAddResponse.toObject = function(includeInstance, msg) {
var f, obj = {
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.wechaty.puppet.TagContactAddResponse}
*/
proto.wechaty.puppet.TagContactAddResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.wechaty.puppet.TagContactAddResponse;
return proto.wechaty.puppet.TagContactAddResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.wechaty.puppet.TagContactAddResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.wechaty.puppet.TagContactAddResponse}
*/
proto.wechaty.puppet.TagContactAddResponse.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.wechaty.puppet.TagContactAddResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.wechaty.puppet.TagContactAddResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.wechaty.puppet.TagContactAddResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactAddResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.wechaty.puppet.TagContactRemoveRequest.prototype.toObject = function(opt_includeInstance) {
return proto.wechaty.puppet.TagContactRemoveRequest.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
* the JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.wechaty.puppet.TagContactRemoveRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactRemoveRequest.toObject = function(includeInstance, msg) {
var f, obj = {
id: jspb.Message.getFieldWithDefault(msg, 1, ""),
contactId: jspb.Message.getFieldWithDefault(msg, 2, "")
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.wechaty.puppet.TagContactRemoveRequest}
*/
proto.wechaty.puppet.TagContactRemoveRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.wechaty.puppet.TagContactRemoveRequest;
return proto.wechaty.puppet.TagContactRemoveRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.wechaty.puppet.TagContactRemoveRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.wechaty.puppet.TagContactRemoveRequest}
*/
proto.wechaty.puppet.TagContactRemoveRequest.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = /** @type {string} */ (reader.readString());
msg.setId(value);
break;
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setContactId(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.wechaty.puppet.TagContactRemoveRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.wechaty.puppet.TagContactRemoveRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.wechaty.puppet.TagContactRemoveRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactRemoveRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getId();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
f = message.getContactId();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
};
/**
* optional string id = 1;
* @return {string}
*/
proto.wechaty.puppet.TagContactRemoveRequest.prototype.getId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.wechaty.puppet.TagContactRemoveRequest} returns this
*/
proto.wechaty.puppet.TagContactRemoveRequest.prototype.setId = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
/**
* optional string contact_id = 2;
* @return {string}
*/
proto.wechaty.puppet.TagContactRemoveRequest.prototype.getContactId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/**
* @param {string} value
* @return {!proto.wechaty.puppet.TagContactRemoveRequest} returns this
*/
proto.wechaty.puppet.TagContactRemoveRequest.prototype.setContactId = function(value) {
return jspb.Message.setProto3StringField(this, 2, value);
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.wechaty.puppet.TagContactRemoveResponse.prototype.toObject = function(opt_includeInstance) {
return proto.wechaty.puppet.TagContactRemoveResponse.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
* the JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.wechaty.puppet.TagContactRemoveResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactRemoveResponse.toObject = function(includeInstance, msg) {
var f, obj = {
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.wechaty.puppet.TagContactRemoveResponse}
*/
proto.wechaty.puppet.TagContactRemoveResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.wechaty.puppet.TagContactRemoveResponse;
return proto.wechaty.puppet.TagContactRemoveResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.wechaty.puppet.TagContactRemoveResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.wechaty.puppet.TagContactRemoveResponse}
*/
proto.wechaty.puppet.TagContactRemoveResponse.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.wechaty.puppet.TagContactRemoveResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.wechaty.puppet.TagContactRemoveResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.wechaty.puppet.TagContactRemoveResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactRemoveResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.wechaty.puppet.TagContactDeleteRequest.prototype.toObject = function(opt_includeInstance) {
return proto.wechaty.puppet.TagContactDeleteRequest.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
* the JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.wechaty.puppet.TagContactDeleteRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactDeleteRequest.toObject = function(includeInstance, msg) {
var f, obj = {
id: jspb.Message.getFieldWithDefault(msg, 1, "")
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.wechaty.puppet.TagContactDeleteRequest}
*/
proto.wechaty.puppet.TagContactDeleteRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.wechaty.puppet.TagContactDeleteRequest;
return proto.wechaty.puppet.TagContactDeleteRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.wechaty.puppet.TagContactDeleteRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.wechaty.puppet.TagContactDeleteRequest}
*/
proto.wechaty.puppet.TagContactDeleteRequest.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = /** @type {string} */ (reader.readString());
msg.setId(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.wechaty.puppet.TagContactDeleteRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.wechaty.puppet.TagContactDeleteRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.wechaty.puppet.TagContactDeleteRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactDeleteRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getId();
if (f.length > 0) {
writer.writeString(
1,
f
);
}
};
/**
* optional string id = 1;
* @return {string}
*/
proto.wechaty.puppet.TagContactDeleteRequest.prototype.getId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
};
/**
* @param {string} value
* @return {!proto.wechaty.puppet.TagContactDeleteRequest} returns this
*/
proto.wechaty.puppet.TagContactDeleteRequest.prototype.setId = function(value) {
return jspb.Message.setProto3StringField(this, 1, value);
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.wechaty.puppet.TagContactDeleteResponse.prototype.toObject = function(opt_includeInstance) {
return proto.wechaty.puppet.TagContactDeleteResponse.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
* the JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.wechaty.puppet.TagContactDeleteResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactDeleteResponse.toObject = function(includeInstance, msg) {
var f, obj = {
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.wechaty.puppet.TagContactDeleteResponse}
*/
proto.wechaty.puppet.TagContactDeleteResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.wechaty.puppet.TagContactDeleteResponse;
return proto.wechaty.puppet.TagContactDeleteResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.wechaty.puppet.TagContactDeleteResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.wechaty.puppet.TagContactDeleteResponse}
*/
proto.wechaty.puppet.TagContactDeleteResponse.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.wechaty.puppet.TagContactDeleteResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.wechaty.puppet.TagContactDeleteResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.wechaty.puppet.TagContactDeleteResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactDeleteResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
};
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.wechaty.puppet.TagContactListRequest.prototype.toObject = function(opt_includeInstance) {
return proto.wechaty.puppet.TagContactListRequest.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
* the JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.wechaty.puppet.TagContactListRequest} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactListRequest.toObject = function(includeInstance, msg) {
var f, obj = {
contactIdStringValueDeprecated: (f = msg.getContactIdStringValueDeprecated()) && google_protobuf_wrappers_pb.StringValue.toObject(includeInstance, f),
contactId: jspb.Message.getFieldWithDefault(msg, 2, "")
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.wechaty.puppet.TagContactListRequest}
*/
proto.wechaty.puppet.TagContactListRequest.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.wechaty.puppet.TagContactListRequest;
return proto.wechaty.puppet.TagContactListRequest.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.wechaty.puppet.TagContactListRequest} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.wechaty.puppet.TagContactListRequest}
*/
proto.wechaty.puppet.TagContactListRequest.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = new google_protobuf_wrappers_pb.StringValue;
reader.readMessage(value,google_protobuf_wrappers_pb.StringValue.deserializeBinaryFromReader);
msg.setContactIdStringValueDeprecated(value);
break;
case 2:
var value = /** @type {string} */ (reader.readString());
msg.setContactId(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.wechaty.puppet.TagContactListRequest.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.wechaty.puppet.TagContactListRequest.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.wechaty.puppet.TagContactListRequest} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactListRequest.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getContactIdStringValueDeprecated();
if (f != null) {
writer.writeMessage(
1,
f,
google_protobuf_wrappers_pb.StringValue.serializeBinaryToWriter
);
}
f = message.getContactId();
if (f.length > 0) {
writer.writeString(
2,
f
);
}
};
/**
* optional google.protobuf.StringValue contact_id_string_value_deprecated = 1;
* @return {?proto.google.protobuf.StringValue}
*/
proto.wechaty.puppet.TagContactListRequest.prototype.getContactIdStringValueDeprecated = function() {
return /** @type{?proto.google.protobuf.StringValue} */ (
jspb.Message.getWrapperField(this, google_protobuf_wrappers_pb.StringValue, 1));
};
/**
* @param {?proto.google.protobuf.StringValue|undefined} value
* @return {!proto.wechaty.puppet.TagContactListRequest} returns this
*/
proto.wechaty.puppet.TagContactListRequest.prototype.setContactIdStringValueDeprecated = function(value) {
return jspb.Message.setWrapperField(this, 1, value);
};
/**
* Clears the message field making it undefined.
* @return {!proto.wechaty.puppet.TagContactListRequest} returns this
*/
proto.wechaty.puppet.TagContactListRequest.prototype.clearContactIdStringValueDeprecated = function() {
return this.setContactIdStringValueDeprecated(undefined);
};
/**
* Returns whether this field is set.
* @return {boolean}
*/
proto.wechaty.puppet.TagContactListRequest.prototype.hasContactIdStringValueDeprecated = function() {
return jspb.Message.getField(this, 1) != null;
};
/**
* optional string contact_id = 2;
* @return {string}
*/
proto.wechaty.puppet.TagContactListRequest.prototype.getContactId = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
};
/**
* @param {string} value
* @return {!proto.wechaty.puppet.TagContactListRequest} returns this
*/
proto.wechaty.puppet.TagContactListRequest.prototype.setContactId = function(value) {
return jspb.Message.setProto3StringField(this, 2, value);
};
/**
* List of repeated fields within this message type.
* @private {!Array<number>}
* @const
*/
proto.wechaty.puppet.TagContactListResponse.repeatedFields_ = [1];
if (jspb.Message.GENERATE_TO_OBJECT) {
/**
* Creates an object representation of this proto.
* Field names that are reserved in JavaScript and will be renamed to pb_name.
* Optional fields that are not set will be set to undefined.
* To access a reserved field use, foo.pb_<name>, eg, foo.pb_default.
* For the list of reserved names please see:
* net/proto2/compiler/js/internal/generator.cc#kKeyword.
* @param {boolean=} opt_includeInstance Deprecated. whether to include the
* JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @return {!Object}
*/
proto.wechaty.puppet.TagContactListResponse.prototype.toObject = function(opt_includeInstance) {
return proto.wechaty.puppet.TagContactListResponse.toObject(opt_includeInstance, this);
};
/**
* Static version of the {@see toObject} method.
* @param {boolean|undefined} includeInstance Deprecated. Whether to include
* the JSPB instance for transitional soy proto support:
* http://goto/soy-param-migration
* @param {!proto.wechaty.puppet.TagContactListResponse} msg The msg instance to transform.
* @return {!Object}
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactListResponse.toObject = function(includeInstance, msg) {
var f, obj = {
idsList: (f = jspb.Message.getRepeatedField(msg, 1)) == null ? undefined : f
};
if (includeInstance) {
obj.$jspbMessageInstance = msg;
}
return obj;
};
}
/**
* Deserializes binary data (in protobuf wire format).
* @param {jspb.ByteSource} bytes The bytes to deserialize.
* @return {!proto.wechaty.puppet.TagContactListResponse}
*/
proto.wechaty.puppet.TagContactListResponse.deserializeBinary = function(bytes) {
var reader = new jspb.BinaryReader(bytes);
var msg = new proto.wechaty.puppet.TagContactListResponse;
return proto.wechaty.puppet.TagContactListResponse.deserializeBinaryFromReader(msg, reader);
};
/**
* Deserializes binary data (in protobuf wire format) from the
* given reader into the given message object.
* @param {!proto.wechaty.puppet.TagContactListResponse} msg The message object to deserialize into.
* @param {!jspb.BinaryReader} reader The BinaryReader to use.
* @return {!proto.wechaty.puppet.TagContactListResponse}
*/
proto.wechaty.puppet.TagContactListResponse.deserializeBinaryFromReader = function(msg, reader) {
while (reader.nextField()) {
if (reader.isEndGroup()) {
break;
}
var field = reader.getFieldNumber();
switch (field) {
case 1:
var value = /** @type {string} */ (reader.readString());
msg.addIds(value);
break;
default:
reader.skipField();
break;
}
}
return msg;
};
/**
* Serializes the message to binary data (in protobuf wire format).
* @return {!Uint8Array}
*/
proto.wechaty.puppet.TagContactListResponse.prototype.serializeBinary = function() {
var writer = new jspb.BinaryWriter();
proto.wechaty.puppet.TagContactListResponse.serializeBinaryToWriter(this, writer);
return writer.getResultBuffer();
};
/**
* Serializes the given message to binary data (in protobuf wire
* format), writing to the given BinaryWriter.
* @param {!proto.wechaty.puppet.TagContactListResponse} message
* @param {!jspb.BinaryWriter} writer
* @suppress {unusedLocalVariables} f is only used for nested messages
*/
proto.wechaty.puppet.TagContactListResponse.serializeBinaryToWriter = function(message, writer) {
var f = undefined;
f = message.getIdsList();
if (f.length > 0) {
writer.writeRepeatedString(
1,
f
);
}
};
/**
* repeated string ids = 1;
* @return {!Array<string>}
*/
proto.wechaty.puppet.TagContactListResponse.prototype.getIdsList = function() {
return /** @type {!Array<string>} */ (jspb.Message.getRepeatedField(this, 1));
};
/**
* @param {!Array<string>} value
* @return {!proto.wechaty.puppet.TagContactListResponse} returns this
*/
proto.wechaty.puppet.TagContactListResponse.prototype.setIdsList = function(value) {
return jspb.Message.setField(this, 1, value || []);
};
/**
* @param {string} value
* @param {number=} opt_index
* @return {!proto.wechaty.puppet.TagContactListResponse} returns this
*/
proto.wechaty.puppet.TagContactListResponse.prototype.addIds = function(value, opt_index) {
return jspb.Message.addToRepeatedField(this, 1, value, opt_index);
};
/**
* Clears the list making it empty but non-null.
* @return {!proto.wechaty.puppet.TagContactListResponse} returns this
*/
proto.wechaty.puppet.TagContactListResponse.prototype.clearIdsList = function() {
return this.setIdsList([]);
};
goog.object.extend(exports, proto.wechaty.puppet);