UNPKG

@treelab/skywalking-backend-js

Version:

The NodeJS agent for Apache SkyWalking

1,629 lines (1,406 loc) 47.7 kB
// source: logging/Logging.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('return this')(); var common_Common_pb = require('../common/Common_pb.js'); goog.object.extend(proto, common_Common_pb); goog.exportSymbol('proto.skywalking.v3.JSONLog', null, global); goog.exportSymbol('proto.skywalking.v3.LogData', null, global); goog.exportSymbol('proto.skywalking.v3.LogDataBody', null, global); goog.exportSymbol('proto.skywalking.v3.LogDataBody.ContentCase', null, global); goog.exportSymbol('proto.skywalking.v3.LogTags', null, global); goog.exportSymbol('proto.skywalking.v3.TextLog', null, global); goog.exportSymbol('proto.skywalking.v3.TraceContext', null, global); goog.exportSymbol('proto.skywalking.v3.YAMLLog', 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.skywalking.v3.LogData = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.skywalking.v3.LogData, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.skywalking.v3.LogData.displayName = 'proto.skywalking.v3.LogData'; } /** * 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.skywalking.v3.LogDataBody = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, proto.skywalking.v3.LogDataBody.oneofGroups_); }; goog.inherits(proto.skywalking.v3.LogDataBody, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.skywalking.v3.LogDataBody.displayName = 'proto.skywalking.v3.LogDataBody'; } /** * 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.skywalking.v3.TextLog = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.skywalking.v3.TextLog, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.skywalking.v3.TextLog.displayName = 'proto.skywalking.v3.TextLog'; } /** * 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.skywalking.v3.JSONLog = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.skywalking.v3.JSONLog, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.skywalking.v3.JSONLog.displayName = 'proto.skywalking.v3.JSONLog'; } /** * 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.skywalking.v3.YAMLLog = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.skywalking.v3.YAMLLog, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.skywalking.v3.YAMLLog.displayName = 'proto.skywalking.v3.YAMLLog'; } /** * 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.skywalking.v3.TraceContext = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, null, null); }; goog.inherits(proto.skywalking.v3.TraceContext, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.skywalking.v3.TraceContext.displayName = 'proto.skywalking.v3.TraceContext'; } /** * 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.skywalking.v3.LogTags = function(opt_data) { jspb.Message.initialize(this, opt_data, 0, -1, proto.skywalking.v3.LogTags.repeatedFields_, null); }; goog.inherits(proto.skywalking.v3.LogTags, jspb.Message); if (goog.DEBUG && !COMPILED) { /** * @public * @override */ proto.skywalking.v3.LogTags.displayName = 'proto.skywalking.v3.LogTags'; } 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.skywalking.v3.LogData.prototype.toObject = function(opt_includeInstance) { return proto.skywalking.v3.LogData.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.skywalking.v3.LogData} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.LogData.toObject = function(includeInstance, msg) { var f, obj = { timestamp: jspb.Message.getFieldWithDefault(msg, 1, 0), service: jspb.Message.getFieldWithDefault(msg, 2, ""), serviceinstance: jspb.Message.getFieldWithDefault(msg, 3, ""), endpoint: jspb.Message.getFieldWithDefault(msg, 4, ""), body: (f = msg.getBody()) && proto.skywalking.v3.LogDataBody.toObject(includeInstance, f), tracecontext: (f = msg.getTracecontext()) && proto.skywalking.v3.TraceContext.toObject(includeInstance, f), tags: (f = msg.getTags()) && proto.skywalking.v3.LogTags.toObject(includeInstance, f), layer: jspb.Message.getFieldWithDefault(msg, 8, "") }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.skywalking.v3.LogData} */ proto.skywalking.v3.LogData.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.skywalking.v3.LogData; return proto.skywalking.v3.LogData.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.skywalking.v3.LogData} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.skywalking.v3.LogData} */ proto.skywalking.v3.LogData.deserializeBinaryFromReader = function(msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: var value = /** @type {number} */ (reader.readInt64()); msg.setTimestamp(value); break; case 2: var value = /** @type {string} */ (reader.readString()); msg.setService(value); break; case 3: var value = /** @type {string} */ (reader.readString()); msg.setServiceinstance(value); break; case 4: var value = /** @type {string} */ (reader.readString()); msg.setEndpoint(value); break; case 5: var value = new proto.skywalking.v3.LogDataBody; reader.readMessage(value,proto.skywalking.v3.LogDataBody.deserializeBinaryFromReader); msg.setBody(value); break; case 6: var value = new proto.skywalking.v3.TraceContext; reader.readMessage(value,proto.skywalking.v3.TraceContext.deserializeBinaryFromReader); msg.setTracecontext(value); break; case 7: var value = new proto.skywalking.v3.LogTags; reader.readMessage(value,proto.skywalking.v3.LogTags.deserializeBinaryFromReader); msg.setTags(value); break; case 8: var value = /** @type {string} */ (reader.readString()); msg.setLayer(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.skywalking.v3.LogData.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.skywalking.v3.LogData.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.skywalking.v3.LogData} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.LogData.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getTimestamp(); if (f !== 0) { writer.writeInt64( 1, f ); } f = message.getService(); if (f.length > 0) { writer.writeString( 2, f ); } f = message.getServiceinstance(); if (f.length > 0) { writer.writeString( 3, f ); } f = message.getEndpoint(); if (f.length > 0) { writer.writeString( 4, f ); } f = message.getBody(); if (f != null) { writer.writeMessage( 5, f, proto.skywalking.v3.LogDataBody.serializeBinaryToWriter ); } f = message.getTracecontext(); if (f != null) { writer.writeMessage( 6, f, proto.skywalking.v3.TraceContext.serializeBinaryToWriter ); } f = message.getTags(); if (f != null) { writer.writeMessage( 7, f, proto.skywalking.v3.LogTags.serializeBinaryToWriter ); } f = message.getLayer(); if (f.length > 0) { writer.writeString( 8, f ); } }; /** * optional int64 timestamp = 1; * @return {number} */ proto.skywalking.v3.LogData.prototype.getTimestamp = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0)); }; /** * @param {number} value * @return {!proto.skywalking.v3.LogData} returns this */ proto.skywalking.v3.LogData.prototype.setTimestamp = function(value) { return jspb.Message.setProto3IntField(this, 1, value); }; /** * optional string service = 2; * @return {string} */ proto.skywalking.v3.LogData.prototype.getService = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); }; /** * @param {string} value * @return {!proto.skywalking.v3.LogData} returns this */ proto.skywalking.v3.LogData.prototype.setService = function(value) { return jspb.Message.setProto3StringField(this, 2, value); }; /** * optional string serviceInstance = 3; * @return {string} */ proto.skywalking.v3.LogData.prototype.getServiceinstance = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 3, "")); }; /** * @param {string} value * @return {!proto.skywalking.v3.LogData} returns this */ proto.skywalking.v3.LogData.prototype.setServiceinstance = function(value) { return jspb.Message.setProto3StringField(this, 3, value); }; /** * optional string endpoint = 4; * @return {string} */ proto.skywalking.v3.LogData.prototype.getEndpoint = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 4, "")); }; /** * @param {string} value * @return {!proto.skywalking.v3.LogData} returns this */ proto.skywalking.v3.LogData.prototype.setEndpoint = function(value) { return jspb.Message.setProto3StringField(this, 4, value); }; /** * optional LogDataBody body = 5; * @return {?proto.skywalking.v3.LogDataBody} */ proto.skywalking.v3.LogData.prototype.getBody = function() { return /** @type{?proto.skywalking.v3.LogDataBody} */ ( jspb.Message.getWrapperField(this, proto.skywalking.v3.LogDataBody, 5)); }; /** * @param {?proto.skywalking.v3.LogDataBody|undefined} value * @return {!proto.skywalking.v3.LogData} returns this */ proto.skywalking.v3.LogData.prototype.setBody = function(value) { return jspb.Message.setWrapperField(this, 5, value); }; /** * Clears the message field making it undefined. * @return {!proto.skywalking.v3.LogData} returns this */ proto.skywalking.v3.LogData.prototype.clearBody = function() { return this.setBody(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.skywalking.v3.LogData.prototype.hasBody = function() { return jspb.Message.getField(this, 5) != null; }; /** * optional TraceContext traceContext = 6; * @return {?proto.skywalking.v3.TraceContext} */ proto.skywalking.v3.LogData.prototype.getTracecontext = function() { return /** @type{?proto.skywalking.v3.TraceContext} */ ( jspb.Message.getWrapperField(this, proto.skywalking.v3.TraceContext, 6)); }; /** * @param {?proto.skywalking.v3.TraceContext|undefined} value * @return {!proto.skywalking.v3.LogData} returns this */ proto.skywalking.v3.LogData.prototype.setTracecontext = function(value) { return jspb.Message.setWrapperField(this, 6, value); }; /** * Clears the message field making it undefined. * @return {!proto.skywalking.v3.LogData} returns this */ proto.skywalking.v3.LogData.prototype.clearTracecontext = function() { return this.setTracecontext(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.skywalking.v3.LogData.prototype.hasTracecontext = function() { return jspb.Message.getField(this, 6) != null; }; /** * optional LogTags tags = 7; * @return {?proto.skywalking.v3.LogTags} */ proto.skywalking.v3.LogData.prototype.getTags = function() { return /** @type{?proto.skywalking.v3.LogTags} */ ( jspb.Message.getWrapperField(this, proto.skywalking.v3.LogTags, 7)); }; /** * @param {?proto.skywalking.v3.LogTags|undefined} value * @return {!proto.skywalking.v3.LogData} returns this */ proto.skywalking.v3.LogData.prototype.setTags = function(value) { return jspb.Message.setWrapperField(this, 7, value); }; /** * Clears the message field making it undefined. * @return {!proto.skywalking.v3.LogData} returns this */ proto.skywalking.v3.LogData.prototype.clearTags = function() { return this.setTags(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.skywalking.v3.LogData.prototype.hasTags = function() { return jspb.Message.getField(this, 7) != null; }; /** * optional string layer = 8; * @return {string} */ proto.skywalking.v3.LogData.prototype.getLayer = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 8, "")); }; /** * @param {string} value * @return {!proto.skywalking.v3.LogData} returns this */ proto.skywalking.v3.LogData.prototype.setLayer = function(value) { return jspb.Message.setProto3StringField(this, 8, value); }; /** * Oneof group definitions for this message. Each group defines the field * numbers belonging to that group. When of these fields' value is set, all * other fields in the group are cleared. During deserialization, if multiple * fields are encountered for a group, only the last value seen will be kept. * @private {!Array<!Array<number>>} * @const */ proto.skywalking.v3.LogDataBody.oneofGroups_ = [[2,3,4]]; /** * @enum {number} */ proto.skywalking.v3.LogDataBody.ContentCase = { CONTENT_NOT_SET: 0, TEXT: 2, JSON: 3, YAML: 4 }; /** * @return {proto.skywalking.v3.LogDataBody.ContentCase} */ proto.skywalking.v3.LogDataBody.prototype.getContentCase = function() { return /** @type {proto.skywalking.v3.LogDataBody.ContentCase} */(jspb.Message.computeOneofCase(this, proto.skywalking.v3.LogDataBody.oneofGroups_[0])); }; 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.skywalking.v3.LogDataBody.prototype.toObject = function(opt_includeInstance) { return proto.skywalking.v3.LogDataBody.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.skywalking.v3.LogDataBody} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.LogDataBody.toObject = function(includeInstance, msg) { var f, obj = { type: jspb.Message.getFieldWithDefault(msg, 1, ""), text: (f = msg.getText()) && proto.skywalking.v3.TextLog.toObject(includeInstance, f), json: (f = msg.getJson()) && proto.skywalking.v3.JSONLog.toObject(includeInstance, f), yaml: (f = msg.getYaml()) && proto.skywalking.v3.YAMLLog.toObject(includeInstance, 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.skywalking.v3.LogDataBody} */ proto.skywalking.v3.LogDataBody.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.skywalking.v3.LogDataBody; return proto.skywalking.v3.LogDataBody.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.skywalking.v3.LogDataBody} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.skywalking.v3.LogDataBody} */ proto.skywalking.v3.LogDataBody.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.setType(value); break; case 2: var value = new proto.skywalking.v3.TextLog; reader.readMessage(value,proto.skywalking.v3.TextLog.deserializeBinaryFromReader); msg.setText(value); break; case 3: var value = new proto.skywalking.v3.JSONLog; reader.readMessage(value,proto.skywalking.v3.JSONLog.deserializeBinaryFromReader); msg.setJson(value); break; case 4: var value = new proto.skywalking.v3.YAMLLog; reader.readMessage(value,proto.skywalking.v3.YAMLLog.deserializeBinaryFromReader); msg.setYaml(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.skywalking.v3.LogDataBody.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.skywalking.v3.LogDataBody.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.skywalking.v3.LogDataBody} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.LogDataBody.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getType(); if (f.length > 0) { writer.writeString( 1, f ); } f = message.getText(); if (f != null) { writer.writeMessage( 2, f, proto.skywalking.v3.TextLog.serializeBinaryToWriter ); } f = message.getJson(); if (f != null) { writer.writeMessage( 3, f, proto.skywalking.v3.JSONLog.serializeBinaryToWriter ); } f = message.getYaml(); if (f != null) { writer.writeMessage( 4, f, proto.skywalking.v3.YAMLLog.serializeBinaryToWriter ); } }; /** * optional string type = 1; * @return {string} */ proto.skywalking.v3.LogDataBody.prototype.getType = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** * @param {string} value * @return {!proto.skywalking.v3.LogDataBody} returns this */ proto.skywalking.v3.LogDataBody.prototype.setType = function(value) { return jspb.Message.setProto3StringField(this, 1, value); }; /** * optional TextLog text = 2; * @return {?proto.skywalking.v3.TextLog} */ proto.skywalking.v3.LogDataBody.prototype.getText = function() { return /** @type{?proto.skywalking.v3.TextLog} */ ( jspb.Message.getWrapperField(this, proto.skywalking.v3.TextLog, 2)); }; /** * @param {?proto.skywalking.v3.TextLog|undefined} value * @return {!proto.skywalking.v3.LogDataBody} returns this */ proto.skywalking.v3.LogDataBody.prototype.setText = function(value) { return jspb.Message.setOneofWrapperField(this, 2, proto.skywalking.v3.LogDataBody.oneofGroups_[0], value); }; /** * Clears the message field making it undefined. * @return {!proto.skywalking.v3.LogDataBody} returns this */ proto.skywalking.v3.LogDataBody.prototype.clearText = function() { return this.setText(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.skywalking.v3.LogDataBody.prototype.hasText = function() { return jspb.Message.getField(this, 2) != null; }; /** * optional JSONLog json = 3; * @return {?proto.skywalking.v3.JSONLog} */ proto.skywalking.v3.LogDataBody.prototype.getJson = function() { return /** @type{?proto.skywalking.v3.JSONLog} */ ( jspb.Message.getWrapperField(this, proto.skywalking.v3.JSONLog, 3)); }; /** * @param {?proto.skywalking.v3.JSONLog|undefined} value * @return {!proto.skywalking.v3.LogDataBody} returns this */ proto.skywalking.v3.LogDataBody.prototype.setJson = function(value) { return jspb.Message.setOneofWrapperField(this, 3, proto.skywalking.v3.LogDataBody.oneofGroups_[0], value); }; /** * Clears the message field making it undefined. * @return {!proto.skywalking.v3.LogDataBody} returns this */ proto.skywalking.v3.LogDataBody.prototype.clearJson = function() { return this.setJson(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.skywalking.v3.LogDataBody.prototype.hasJson = function() { return jspb.Message.getField(this, 3) != null; }; /** * optional YAMLLog yaml = 4; * @return {?proto.skywalking.v3.YAMLLog} */ proto.skywalking.v3.LogDataBody.prototype.getYaml = function() { return /** @type{?proto.skywalking.v3.YAMLLog} */ ( jspb.Message.getWrapperField(this, proto.skywalking.v3.YAMLLog, 4)); }; /** * @param {?proto.skywalking.v3.YAMLLog|undefined} value * @return {!proto.skywalking.v3.LogDataBody} returns this */ proto.skywalking.v3.LogDataBody.prototype.setYaml = function(value) { return jspb.Message.setOneofWrapperField(this, 4, proto.skywalking.v3.LogDataBody.oneofGroups_[0], value); }; /** * Clears the message field making it undefined. * @return {!proto.skywalking.v3.LogDataBody} returns this */ proto.skywalking.v3.LogDataBody.prototype.clearYaml = function() { return this.setYaml(undefined); }; /** * Returns whether this field is set. * @return {boolean} */ proto.skywalking.v3.LogDataBody.prototype.hasYaml = function() { return jspb.Message.getField(this, 4) != null; }; 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.skywalking.v3.TextLog.prototype.toObject = function(opt_includeInstance) { return proto.skywalking.v3.TextLog.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.skywalking.v3.TextLog} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.TextLog.toObject = function(includeInstance, msg) { var f, obj = { text: 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.skywalking.v3.TextLog} */ proto.skywalking.v3.TextLog.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.skywalking.v3.TextLog; return proto.skywalking.v3.TextLog.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.skywalking.v3.TextLog} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.skywalking.v3.TextLog} */ proto.skywalking.v3.TextLog.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.setText(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.skywalking.v3.TextLog.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.skywalking.v3.TextLog.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.skywalking.v3.TextLog} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.TextLog.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getText(); if (f.length > 0) { writer.writeString( 1, f ); } }; /** * optional string text = 1; * @return {string} */ proto.skywalking.v3.TextLog.prototype.getText = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** * @param {string} value * @return {!proto.skywalking.v3.TextLog} returns this */ proto.skywalking.v3.TextLog.prototype.setText = 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.skywalking.v3.JSONLog.prototype.toObject = function(opt_includeInstance) { return proto.skywalking.v3.JSONLog.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.skywalking.v3.JSONLog} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.JSONLog.toObject = function(includeInstance, msg) { var f, obj = { json: 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.skywalking.v3.JSONLog} */ proto.skywalking.v3.JSONLog.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.skywalking.v3.JSONLog; return proto.skywalking.v3.JSONLog.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.skywalking.v3.JSONLog} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.skywalking.v3.JSONLog} */ proto.skywalking.v3.JSONLog.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.setJson(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.skywalking.v3.JSONLog.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.skywalking.v3.JSONLog.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.skywalking.v3.JSONLog} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.JSONLog.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getJson(); if (f.length > 0) { writer.writeString( 1, f ); } }; /** * optional string json = 1; * @return {string} */ proto.skywalking.v3.JSONLog.prototype.getJson = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** * @param {string} value * @return {!proto.skywalking.v3.JSONLog} returns this */ proto.skywalking.v3.JSONLog.prototype.setJson = 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.skywalking.v3.YAMLLog.prototype.toObject = function(opt_includeInstance) { return proto.skywalking.v3.YAMLLog.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.skywalking.v3.YAMLLog} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.YAMLLog.toObject = function(includeInstance, msg) { var f, obj = { yaml: 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.skywalking.v3.YAMLLog} */ proto.skywalking.v3.YAMLLog.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.skywalking.v3.YAMLLog; return proto.skywalking.v3.YAMLLog.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.skywalking.v3.YAMLLog} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.skywalking.v3.YAMLLog} */ proto.skywalking.v3.YAMLLog.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.setYaml(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.skywalking.v3.YAMLLog.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.skywalking.v3.YAMLLog.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.skywalking.v3.YAMLLog} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.YAMLLog.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getYaml(); if (f.length > 0) { writer.writeString( 1, f ); } }; /** * optional string yaml = 1; * @return {string} */ proto.skywalking.v3.YAMLLog.prototype.getYaml = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** * @param {string} value * @return {!proto.skywalking.v3.YAMLLog} returns this */ proto.skywalking.v3.YAMLLog.prototype.setYaml = 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.skywalking.v3.TraceContext.prototype.toObject = function(opt_includeInstance) { return proto.skywalking.v3.TraceContext.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.skywalking.v3.TraceContext} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.TraceContext.toObject = function(includeInstance, msg) { var f, obj = { traceid: jspb.Message.getFieldWithDefault(msg, 1, ""), tracesegmentid: jspb.Message.getFieldWithDefault(msg, 2, ""), spanid: jspb.Message.getFieldWithDefault(msg, 3, 0) }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.skywalking.v3.TraceContext} */ proto.skywalking.v3.TraceContext.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.skywalking.v3.TraceContext; return proto.skywalking.v3.TraceContext.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.skywalking.v3.TraceContext} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.skywalking.v3.TraceContext} */ proto.skywalking.v3.TraceContext.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.setTraceid(value); break; case 2: var value = /** @type {string} */ (reader.readString()); msg.setTracesegmentid(value); break; case 3: var value = /** @type {number} */ (reader.readInt32()); msg.setSpanid(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.skywalking.v3.TraceContext.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.skywalking.v3.TraceContext.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.skywalking.v3.TraceContext} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.TraceContext.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getTraceid(); if (f.length > 0) { writer.writeString( 1, f ); } f = message.getTracesegmentid(); if (f.length > 0) { writer.writeString( 2, f ); } f = message.getSpanid(); if (f !== 0) { writer.writeInt32( 3, f ); } }; /** * optional string traceId = 1; * @return {string} */ proto.skywalking.v3.TraceContext.prototype.getTraceid = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, "")); }; /** * @param {string} value * @return {!proto.skywalking.v3.TraceContext} returns this */ proto.skywalking.v3.TraceContext.prototype.setTraceid = function(value) { return jspb.Message.setProto3StringField(this, 1, value); }; /** * optional string traceSegmentId = 2; * @return {string} */ proto.skywalking.v3.TraceContext.prototype.getTracesegmentid = function() { return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 2, "")); }; /** * @param {string} value * @return {!proto.skywalking.v3.TraceContext} returns this */ proto.skywalking.v3.TraceContext.prototype.setTracesegmentid = function(value) { return jspb.Message.setProto3StringField(this, 2, value); }; /** * optional int32 spanId = 3; * @return {number} */ proto.skywalking.v3.TraceContext.prototype.getSpanid = function() { return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0)); }; /** * @param {number} value * @return {!proto.skywalking.v3.TraceContext} returns this */ proto.skywalking.v3.TraceContext.prototype.setSpanid = function(value) { return jspb.Message.setProto3IntField(this, 3, value); }; /** * List of repeated fields within this message type. * @private {!Array<number>} * @const */ proto.skywalking.v3.LogTags.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.skywalking.v3.LogTags.prototype.toObject = function(opt_includeInstance) { return proto.skywalking.v3.LogTags.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.skywalking.v3.LogTags} msg The msg instance to transform. * @return {!Object} * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.LogTags.toObject = function(includeInstance, msg) { var f, obj = { dataList: jspb.Message.toObjectList(msg.getDataList(), common_Common_pb.KeyStringValuePair.toObject, includeInstance) }; if (includeInstance) { obj.$jspbMessageInstance = msg; } return obj; }; } /** * Deserializes binary data (in protobuf wire format). * @param {jspb.ByteSource} bytes The bytes to deserialize. * @return {!proto.skywalking.v3.LogTags} */ proto.skywalking.v3.LogTags.deserializeBinary = function(bytes) { var reader = new jspb.BinaryReader(bytes); var msg = new proto.skywalking.v3.LogTags; return proto.skywalking.v3.LogTags.deserializeBinaryFromReader(msg, reader); }; /** * Deserializes binary data (in protobuf wire format) from the * given reader into the given message object. * @param {!proto.skywalking.v3.LogTags} msg The message object to deserialize into. * @param {!jspb.BinaryReader} reader The BinaryReader to use. * @return {!proto.skywalking.v3.LogTags} */ proto.skywalking.v3.LogTags.deserializeBinaryFromReader = function(msg, reader) { while (reader.nextField()) { if (reader.isEndGroup()) { break; } var field = reader.getFieldNumber(); switch (field) { case 1: var value = new common_Common_pb.KeyStringValuePair; reader.readMessage(value,common_Common_pb.KeyStringValuePair.deserializeBinaryFromReader); msg.addData(value); break; default: reader.skipField(); break; } } return msg; }; /** * Serializes the message to binary data (in protobuf wire format). * @return {!Uint8Array} */ proto.skywalking.v3.LogTags.prototype.serializeBinary = function() { var writer = new jspb.BinaryWriter(); proto.skywalking.v3.LogTags.serializeBinaryToWriter(this, writer); return writer.getResultBuffer(); }; /** * Serializes the given message to binary data (in protobuf wire * format), writing to the given BinaryWriter. * @param {!proto.skywalking.v3.LogTags} message * @param {!jspb.BinaryWriter} writer * @suppress {unusedLocalVariables} f is only used for nested messages */ proto.skywalking.v3.LogTags.serializeBinaryToWriter = function(message, writer) { var f = undefined; f = message.getDataList(); if (f.length > 0) { writer.writeRepeatedMessage( 1, f, common_Common_pb.KeyStringValuePair.serializeBinaryToWriter ); } }; /** * repeated KeyStringValuePair data = 1; * @return {!Array<!proto.skywalking.v3.KeyStringValuePair>} */ proto.skywalking.v3.LogTags.prototype.getDataList = function() { return /** @type{!Array<!proto.skywalking.v3.KeyStringValuePair>} */ ( jspb.Message.getRepeatedWrapperField(this, common_Common_pb.KeyStringValuePair, 1)); }; /** * @param {!Array<!proto.skywalking.v3.KeyStringValuePair>} value * @return {!proto.skywalking.v3.LogTags} returns this */ proto.skywalking.v3.LogTags.prototype.setDataList = function(value) { return jspb.Message.setRepeatedWrapperField(this, 1, value); }; /** * @param {!proto.skywalking.v3.KeyStringValuePair=} opt_value * @param {number=} opt_index * @return {!proto.skywalking.v3.KeyStringValuePair} */ proto.skywalking.v3.LogTags.prototype.addData = function(opt_value, opt_index) { return jspb.Message.addToRepeatedWrapperField(this, 1, opt_value, proto.skywalking.v3.KeyStringValuePair, opt_index); }; /** * Clears the list making it empty but non-null. * @return {!proto.skywalking.v3.LogTags} returns this */ proto.skywalking.v3.LogTags.prototype.clearDataList = function() { return this.setDataList([]); }; goog.object.extend(exports, proto.skywalking.v3);