Lines Matching defs:encoder
210 bool CacheSignature::Encode(DataEncoder &encoder) const {
216 encoder.AppendU8(eSignatureUUID);
217 encoder.AppendU8(uuid_bytes.size());
218 encoder.AppendData(uuid_bytes);
221 encoder.AppendU8(eSignatureModTime);
222 encoder.AppendU32(*m_mod_time);
225 encoder.AppendU8(eSignatureObjectModTime);
226 encoder.AppendU32(*m_obj_mod_time);
228 encoder.AppendU8(eSignatureEnd);
277 bool ConstStringTable::Encode(DataEncoder &encoder) {
282 encoder.AppendData(kStringTableIdentifier);
283 size_t length_offset = encoder.GetByteSize();
284 encoder.AppendU32(0); // Total length of all strings which will be fixed up.
285 size_t strtab_offset = encoder.GetByteSize();
286 encoder.AppendU8(0); // Start the string table with an empty string.
290 encoder.GetByteSize() - strtab_offset);
291 // Append the C string into the encoder
292 encoder.AppendCString(s.GetStringRef());
295 encoder.PutU32(length_offset, encoder.GetByteSize() - strtab_offset);