Lines Matching refs:val
57 ProtoOutputStream::internalWrite(uint64_t fieldId, T val, const char* typeName) in internalWrite() argument
62 case FIELD_TYPE_DOUBLE: writeDoubleImpl(id, (double)val); break; in internalWrite()
63 case FIELD_TYPE_FLOAT: writeFloatImpl(id, (float)val); break; in internalWrite()
64 case FIELD_TYPE_INT64: writeInt64Impl(id, (int64_t)val); break; in internalWrite()
65 case FIELD_TYPE_UINT64: writeUint64Impl(id, (uint64_t)val); break; in internalWrite()
66 case FIELD_TYPE_INT32: writeInt32Impl(id, (int32_t)val); break; in internalWrite()
67 case FIELD_TYPE_FIXED64: writeFixed64Impl(id, (uint64_t)val); break; in internalWrite()
68 case FIELD_TYPE_FIXED32: writeFixed32Impl(id, (uint32_t)val); break; in internalWrite()
69 case FIELD_TYPE_UINT32: writeUint32Impl(id, (uint32_t)val); break; in internalWrite()
70 case FIELD_TYPE_SFIXED32: writeSFixed32Impl(id, (int32_t)val); break; in internalWrite()
71 case FIELD_TYPE_SFIXED64: writeSFixed64Impl(id, (int64_t)val); break; in internalWrite()
72 case FIELD_TYPE_SINT32: writeZigzagInt32Impl(id, (int32_t)val); break; in internalWrite()
73 case FIELD_TYPE_SINT64: writeZigzagInt64Impl(id, (int64_t)val); break; in internalWrite()
76 writeEnumImpl(id, (int)val); in internalWrite()
83 writeBoolImpl(id, val != 0); in internalWrite()
100 ProtoOutputStream::write(uint64_t fieldId, double val) in write() argument
102 return internalWrite(fieldId, val, "double"); in write()
107 ProtoOutputStream::write(uint64_t fieldId, float val) in write() argument
109 return internalWrite(fieldId, val, "float"); in write()
113 ProtoOutputStream::write(uint64_t fieldId, int val) in write() argument
115 return internalWrite(fieldId, val, "int"); in write()
119 ProtoOutputStream::write(uint64_t fieldId, long val) in write() argument
124 case FIELD_TYPE_DOUBLE: writeDoubleImpl(id, (double)val); break; in write()
125 case FIELD_TYPE_FLOAT: writeFloatImpl(id, (float)val); break; in write()
126 case FIELD_TYPE_INT64: writeInt64Impl(id, (long long)val); break; in write()
127 case FIELD_TYPE_UINT64: writeUint64Impl(id, (uint64_t)val); break; in write()
128 case FIELD_TYPE_INT32: writeInt32Impl(id, (int)val); break; in write()
129 case FIELD_TYPE_FIXED64: writeFixed64Impl(id, (uint64_t)val); break; in write()
130 case FIELD_TYPE_FIXED32: writeFixed32Impl(id, (uint32_t)val); break; in write()
131 case FIELD_TYPE_UINT32: writeUint32Impl(id, (uint32_t)val); break; in write()
132 case FIELD_TYPE_SFIXED32: writeSFixed32Impl(id, (int)val); break; in write()
133 case FIELD_TYPE_SFIXED64: writeSFixed64Impl(id, (long long)val); break; in write()
134 case FIELD_TYPE_SINT32: writeZigzagInt32Impl(id, (int)val); break; in write()
135 case FIELD_TYPE_SINT64: writeZigzagInt64Impl(id, (long long)val); break; in write()
136 case FIELD_TYPE_ENUM: writeEnumImpl(id, (int)val); break; in write()
137 case FIELD_TYPE_BOOL: writeBoolImpl(id, val != 0); break; in write()
147 ProtoOutputStream::write(uint64_t fieldId, long long val) in write() argument
149 return internalWrite(fieldId, val, "long long"); in write()
153 ProtoOutputStream::write(uint64_t fieldId, bool val) in write() argument
159 writeBoolImpl(id, val); in write()
169 ProtoOutputStream::write(uint64_t fieldId, std::string val) in write() argument
175 writeUtf8StringImpl(id, val.c_str(), val.size()); in write()
185 ProtoOutputStream::write(uint64_t fieldId, const char* val, size_t size) in write() argument
192 writeUtf8StringImpl(id, val, size); in write()
196 writeMessageBytesImpl(id, val, size); in write()
558 ProtoOutputStream::writeDoubleImpl(uint32_t id, double val) in writeDoubleImpl() argument
561 mBuffer->writeRawFixed64(bit_cast<double, uint64_t>(val)); in writeDoubleImpl()
565 ProtoOutputStream::writeFloatImpl(uint32_t id, float val) in writeFloatImpl() argument
568 mBuffer->writeRawFixed32(bit_cast<float, uint32_t>(val)); in writeFloatImpl()
572 ProtoOutputStream::writeInt64Impl(uint32_t id, int64_t val) in writeInt64Impl() argument
575 mBuffer->writeRawVarint64(val); in writeInt64Impl()
579 ProtoOutputStream::writeInt32Impl(uint32_t id, int32_t val) in writeInt32Impl() argument
582 mBuffer->writeRawVarint32(val); in writeInt32Impl()
586 ProtoOutputStream::writeUint64Impl(uint32_t id, uint64_t val) in writeUint64Impl() argument
589 mBuffer->writeRawVarint64(val); in writeUint64Impl()
593 ProtoOutputStream::writeUint32Impl(uint32_t id, uint32_t val) in writeUint32Impl() argument
596 mBuffer->writeRawVarint32(val); in writeUint32Impl()
600 ProtoOutputStream::writeFixed64Impl(uint32_t id, uint64_t val) in writeFixed64Impl() argument
603 mBuffer->writeRawFixed64(val); in writeFixed64Impl()
607 ProtoOutputStream::writeFixed32Impl(uint32_t id, uint32_t val) in writeFixed32Impl() argument
610 mBuffer->writeRawFixed32(val); in writeFixed32Impl()
614 ProtoOutputStream::writeSFixed64Impl(uint32_t id, int64_t val) in writeSFixed64Impl() argument
617 mBuffer->writeRawFixed64(val); in writeSFixed64Impl()
621 ProtoOutputStream::writeSFixed32Impl(uint32_t id, int32_t val) in writeSFixed32Impl() argument
624 mBuffer->writeRawFixed32(val); in writeSFixed32Impl()
628 ProtoOutputStream::writeZigzagInt64Impl(uint32_t id, int64_t val) in writeZigzagInt64Impl() argument
631 mBuffer->writeRawVarint64((val << 1) ^ (val >> 63)); in writeZigzagInt64Impl()
635 ProtoOutputStream::writeZigzagInt32Impl(uint32_t id, int32_t val) in writeZigzagInt32Impl() argument
638 mBuffer->writeRawVarint32((val << 1) ^ (val >> 31)); in writeZigzagInt32Impl()
642 ProtoOutputStream::writeEnumImpl(uint32_t id, int val) in writeEnumImpl() argument
645 mBuffer->writeRawVarint32((uint32_t) val); in writeEnumImpl()
649 ProtoOutputStream::writeBoolImpl(uint32_t id, bool val) in writeBoolImpl() argument
652 mBuffer->writeRawVarint32(val ? 1 : 0); in writeBoolImpl()
656 ProtoOutputStream::writeUtf8StringImpl(uint32_t id, const char* val, size_t size) in writeUtf8StringImpl() argument
658 if (val == NULL) return; in writeUtf8StringImpl()
661 mBuffer->writeRawByte((uint8_t)val[i]); in writeUtf8StringImpl()
666 ProtoOutputStream::writeMessageBytesImpl(uint32_t id, const char* val, size_t size) in writeMessageBytesImpl() argument
668 if (val == NULL) return; in writeMessageBytesImpl()
671 mBuffer->writeRawByte(val[i]); in writeMessageBytesImpl()