Home
last modified time | relevance | path

Searched refs:jspb (Results 1 – 25 of 35) sorted by relevance

12

/external/protobuf/js/binary/
Dreader.js66 jspb.BinaryReader = function(opt_bytes, opt_start, opt_length) {
71 this.decoder_ = jspb.BinaryDecoder.alloc(opt_bytes, opt_start, opt_length);
83 this.nextField_ = jspb.BinaryConstants.INVALID_FIELD_NUMBER;
90 this.nextWireType_ = jspb.BinaryConstants.WireType.INVALID;
110 jspb.BinaryReader.instanceCache_ = [];
122 jspb.BinaryReader.alloc =
124 if (jspb.BinaryReader.instanceCache_.length) {
125 var newReader = jspb.BinaryReader.instanceCache_.pop();
131 return new jspb.BinaryReader(opt_bytes, opt_start, opt_length);
144 jspb.BinaryReader.prototype.alloc = jspb.BinaryReader.alloc;
[all …]
Dencoder.js53 jspb.BinaryEncoder = function() {
62 jspb.BinaryEncoder.prototype.length = function() {
70 jspb.BinaryEncoder.prototype.end = function() {
83 jspb.BinaryEncoder.prototype.writeSplitVarint64 = function(lowBits, highBits) {
87 (lowBits < jspb.BinaryConstants.TWO_TO_32));
89 (highBits < jspb.BinaryConstants.TWO_TO_32));
107 jspb.BinaryEncoder.prototype.writeUnsignedVarint32 = function(value) {
110 (value < jspb.BinaryConstants.TWO_TO_32));
126 jspb.BinaryEncoder.prototype.writeSignedVarint32 = function(value) {
128 goog.asserts.assert((value >= -jspb.BinaryConstants.TWO_TO_31) &&
[all …]
Dutils.js58 jspb.utils.split64Low = 0;
66 jspb.utils.split64High = 0;
74 jspb.utils.splitUint64 = function(value) {
78 jspb.BinaryConstants.TWO_TO_32) >>> 0;
80 jspb.utils.split64Low = lowBits;
81 jspb.utils.split64High = highBits;
90 jspb.utils.splitInt64 = function(value) {
98 jspb.BinaryConstants.TWO_TO_32);
113 jspb.utils.split64Low = lowBits;
114 jspb.utils.split64High = highBits;
[all …]
Dwriter.js77 jspb.BinaryWriter = function() {
99 this.encoder_ = new jspb.BinaryEncoder();
117 jspb.BinaryWriter.prototype.appendUint8Array_ = function(arr) {
132 jspb.BinaryWriter.prototype.beginDelimited_ = function(field) {
133 this.writeFieldHeader_(field, jspb.BinaryConstants.WireType.DELIMITED);
149 jspb.BinaryWriter.prototype.endDelimited_ = function(bookmark) {
171 jspb.BinaryWriter.prototype.writeSerializedMessage = function(
184 jspb.BinaryWriter.prototype.maybeWriteSerializedMessage = function(
195 jspb.BinaryWriter.prototype.reset = function() {
207 jspb.BinaryWriter.prototype.getResultBuffer = function() {
[all …]
Dproto_test.js120 msg.setOptionalGroup(new proto.jspb.test.TestAllTypes.OptionalGroup());
122 var submsg = new proto.jspb.test.ForeignMessage();
125 msg.setOptionalForeignEnum(proto.jspb.test.ForeignEnum.FOREIGN_FOO);
144 msg.setRepeatedGroupList([new proto.jspb.test.TestAllTypes.RepeatedGroup()]);
146 submsg = new proto.jspb.test.ForeignMessage();
149 msg.setRepeatedForeignEnumList([proto.jspb.test.ForeignEnum.FOREIGN_FOO]);
197 assertTrue(jspb.Message.equals(original, copy));
221 proto.jspb.test.ForeignEnum.FOREIGN_FOO);
226 proto.jspb.test.TestAllTypes.OneofFieldCase.ONEOF_STRING);
253 [proto.jspb.test.ForeignEnum.FOREIGN_FOO]);
[all …]
Ddecoder.js64 jspb.BinaryIterator = function(opt_decoder, opt_next, opt_elements) {
97 jspb.BinaryIterator.prototype.init_ =
116 jspb.BinaryIterator.instanceCache_ = [];
128 jspb.BinaryIterator.alloc = function(opt_decoder, opt_next, opt_elements) {
129 if (jspb.BinaryIterator.instanceCache_.length) {
130 var iterator = jspb.BinaryIterator.instanceCache_.pop();
134 return new jspb.BinaryIterator(opt_decoder, opt_next, opt_elements);
142 jspb.BinaryIterator.prototype.free = function() {
144 if (jspb.BinaryIterator.instanceCache_.length < 100) {
145 jspb.BinaryIterator.instanceCache_.push(this);
[all …]
Dutils_test.js83 jspb.utils.joinUnsignedDecimalString(0x89e80001, 0x8ac72304);
86 result = jspb.utils.joinUnsignedDecimalString(0xacd05f15, 0x1b69b4b);
89 result = jspb.utils.joinUnsignedDecimalString(0xeb1f0ad2, 0xab54a98c);
92 result = jspb.utils.joinUnsignedDecimalString(0xe3b70cb1, 0x891087b8);
96 result = jspb.utils.joinUnsignedDecimalString(0x00000000, 0x00000000);
99 result = jspb.utils.joinUnsignedDecimalString(0xFFFFFFFF, 0xFFFFFFFF);
105 result = jspb.utils.joinUnsignedDecimalString(low, 0);
112 result = jspb.utils.joinUnsignedDecimalString(0, high);
120 result = jspb.utils.joinUnsignedDecimalString(0x00000000, 0x00100000);
123 result = jspb.utils.joinUnsignedDecimalString(0x00000000, 0x00200000);
[all …]
Dconstants.js65 jspb.ConstBinaryMessage = function() {};
75 jspb.BinaryMessage = function() {};
83 jspb.ByteSource;
90 jspb.ScalarFieldType;
99 jspb.RepeatedFieldType;
111 jspb.AnyFieldType;
118 jspb.BuilderFunction;
125 jspb.ClonerFunction;
132 jspb.RecyclerFunction;
139 jspb.ReaderFunction;
[all …]
Darith.js53 jspb.arith.UInt64 = function(lo, hi) {
73 jspb.arith.UInt64.prototype.cmp = function(other) {
88 jspb.arith.UInt64.prototype.rightShift = function() {
91 return new jspb.arith.UInt64(lo >>> 0, hi >>> 0);
99 jspb.arith.UInt64.prototype.leftShift = function() {
102 return new jspb.arith.UInt64(lo >>> 0, hi >>> 0);
110 jspb.arith.UInt64.prototype.msb = function() {
119 jspb.arith.UInt64.prototype.lsb = function() {
128 jspb.arith.UInt64.prototype.zero = function() {
138 jspb.arith.UInt64.prototype.add = function(other) {
[all …]
Dreader_test.js58 var writer = new jspb.BinaryWriter();
66 jspb.BinaryReader.instanceCache_ = [];
71 var decoder1 = jspb.BinaryDecoder.alloc();
72 var decoder2 = jspb.BinaryDecoder.alloc();
73 var decoder3 = jspb.BinaryDecoder.alloc();
78 assertEquals(3, jspb.BinaryDecoder.instanceCache_.length);
79 assertEquals(0, jspb.BinaryReader.instanceCache_.length);
84 jspb.BinaryReader.alloc().free();
86 assertEquals(2, jspb.BinaryDecoder.instanceCache_.length);
87 assertEquals(1, jspb.BinaryReader.instanceCache_.length);
[all …]
Ddecoder_test.js61 var encoder = new jspb.BinaryEncoder();
73 var decoder = jspb.BinaryDecoder.alloc(encoder.end());
103 var encoder = new jspb.BinaryEncoder();
128 var decoder = jspb.BinaryDecoder.alloc(encoder.end());
154 jspb.BinaryDecoder.instanceCache_ = [];
158 jspb.BinaryDecoder.alloc().free();
160 assertEquals(1, jspb.BinaryDecoder.instanceCache_.length);
165 var decoder1 = jspb.BinaryDecoder.alloc();
166 var decoder2 = jspb.BinaryDecoder.alloc();
167 var decoder3 = jspb.BinaryDecoder.alloc();
[all …]
Darith_test.js49 var a = new jspb.arith.UInt64(1234, 5678);
50 var b = new jspb.arith.UInt64(1234, 5678);
82 var a = new jspb.arith.UInt64(1, 0);
119 var a = new jspb.arith.UInt64(/* lo = */ 0x89abcdef,
121 var b = new jspb.arith.UInt64(/* lo = */ 0xff52ab91,
170 var a = new jspb.arith.UInt64(loValues[i], hiValues[j]);
171 var b = new jspb.arith.UInt64(loValues[j], hiValues[i]);
203 var c = jspb.arith.UInt64.mul32x32(a, b);
232 var a = new jspb.arith.UInt64(testData[i][0], testData[i][1]);
273 var a = new jspb.arith.UInt64(testData[i][0], testData[i][1]);
[all …]
Dwriter_test.js62 var writer = new jspb.BinaryWriter();
70 writer = new jspb.BinaryWriter();
74 writer = new jspb.BinaryWriter();
114 var writer = new jspb.BinaryWriter();
/external/protobuf/js/
Dmessage_test.js84 var empty1 = new proto.jspb.test.Empty([]);
85 var empty2 = new proto.jspb.test.Empty([]);
91 var response = new proto.jspb.test.EnumContainer([]);
92 response.setOuterEnum(proto.jspb.test.OuterEnum.FOO);
93 assertEquals(proto.jspb.test.OuterEnum.FOO, response.getOuterEnum());
97 var data = new proto.jspb.test.DefaultValues([]);
105 var foo = new proto.jspb.test.Complex(data1);
106 var bar = new proto.jspb.test.Complex(data2);
138 var foo = new proto.jspb.test.Complex([
141 var bar = new proto.jspb.test.Complex([
[all …]
Dmessage.js95 jspb.ExtensionFieldInfo = function(fieldNumber, fieldName, ctor, toObjectFn,
125 jspb.ExtensionFieldInfo.prototype.isMessageType = function() {
135 jspb.Message = function() {
181 jspb.Message.SUPPORTS_UINT8ARRAY_ = (typeof Uint8Array == 'function');
189 jspb.Message.prototype.array;
199 jspb.Message.prototype.wrappers_;
208 jspb.Message.prototype.extensionObject_;
217 jspb.Message.prototype.pivot_;
226 jspb.Message.prototype.messageId_;
234 jspb.Message.prototype.convertedFloatingPointFields_;
[all …]
Ddebug.js53 jspb.debug.dump = function(message) {
57 goog.asserts.assert(message instanceof jspb.Message,
63 return /** @type {Object} */ (jspb.debug.dump_(message));
75 jspb.debug.dump_ = function(thing) {
83 return goog.array.map(thing, jspb.debug.dump_);
86 goog.asserts.assert(message instanceof jspb.Message,
99 object[jspb.debug.formatFieldName_(match[1])] = jspb.debug.dump_(val);
119 extensionsObject[jspb.debug.formatFieldName_(fieldName)] =
120 jspb.debug.dump_(extVal);
135 jspb.debug.formatFieldName_ = function(name) {
Ddebug_test.js50 var message = new proto.jspb.test.Simple1();
56 }, jspb.debug.dump(message));
66 }, jspb.debug.dump(message));
74 }, jspb.debug.dump(message));
82 var extension = new proto.jspb.test.IsExtension();
84 var extendable = new proto.jspb.test.HasExtensions();
88 extendable.setExtension(proto.jspb.test.IsExtension.extField, extension);
102 }, jspb.debug.dump(extendable));
Dproto3_test.js73 var msg = new proto.jspb.test.TestProto3();
99 proto.jspb.test.Proto3Enum.PROTO3_FOO);
127 var msg = new proto.jspb.test.TestProto3();
144 var submsg = new proto.jspb.test.ForeignMessage();
147 msg.setOptionalForeignEnum(proto.jspb.test.Proto3Enum.PROTO3_BAR);
164 submsg = new proto.jspb.test.ForeignMessage();
167 msg.setRepeatedForeignEnumList([proto.jspb.test.Proto3Enum.PROTO3_BAR]);
172 msg = proto.jspb.test.TestProto3.deserializeBinary(serialized);
191 proto.jspb.test.Proto3Enum.PROTO3_BAR);
212 [proto.jspb.test.Proto3Enum.PROTO3_BAR]);
[all …]
Dtest5.proto33 option java_package = "com.google.apps.jspb.proto";
36 package jspb.exttest.beta;
/external/grpc-grpc/examples/node/static_codegen/route_guide/
Droute_guide_pb.js8 var jspb = require('google-protobuf'); variable
9 var goog = jspb;
29 jspb.Message.initialize(this, opt_data, 0, -1, null, null);
31 goog.inherits(proto.routeguide.Point, jspb.Message);
37 if (jspb.Message.GENERATE_TO_OBJECT) {
81 var reader = new jspb.BinaryReader(bytes);
134 var writer = new jspb.BinaryWriter();
169 return /** @type {!proto.routeguide.Point} */ (jspb.Message.cloneMessage(this));
178 return /** @type {number} */ (jspb.Message.getFieldProto3(this, 1, 0));
184 jspb.Message.setField(this, 1, value);
[all …]
/external/grpc-grpc/examples/node/static_codegen/
Dhelloworld_pb.js8 var jspb = require('google-protobuf'); variable
9 var goog = jspb;
26 jspb.Message.initialize(this, opt_data, 0, -1, null, null);
28 goog.inherits(proto.helloworld.HelloRequest, jspb.Message);
34 if (jspb.Message.GENERATE_TO_OBJECT) {
77 var reader = new jspb.BinaryReader(bytes);
126 var writer = new jspb.BinaryWriter();
154 return /** @type {!proto.helloworld.HelloRequest} */ (jspb.Message.cloneMessage(this));
163 return /** @type {string} */ (jspb.Message.getFieldProto3(this, 1, ""));
169 jspb.Message.setField(this, 1, value);
[all …]
/external/protobuf/js/commonjs/
Dexport.js14 exports.Message = jspb.Message;
15 exports.BinaryReader = jspb.BinaryReader;
16 exports.BinaryWriter = jspb.BinaryWriter;
17 exports.ExtensionFieldInfo = jspb.ExtensionFieldInfo;
Dexport_testdeps.js18 exports.jspb = jspb;
Dimport_test.js48 var framing1 = new proto.jspb.test.framing.FramingMessage([]);
49 var framing2 = new proto.jspb.test.framing.FramingMessage([]);
/external/protobuf/js/commonjs/test7/
Dtest7.proto33 option java_package = "com.google.apps.jspb.proto";
36 package jspb.test.framing;
41 jspb.test.importing.ImportedMessage imported_message = 1;

12