MCPcopy Create free account
hub / github.com/apache/thrift / writeMapBegin

Method writeMapBegin

lib/php/lib/Protocol/TCompactProtocol.php:265–278  ·  view source on GitHub ↗
($key_type, $val_type, $size)

Source from the content-addressed store, hash-verified

263 }
264
265 public function writeMapBegin($key_type, $val_type, $size)
266 {
267 $written = 0;
268 if ($size == 0) {
269 $written = $this->writeByte(0);
270 } else {
271 $written = $this->writeVarint($size) +
272 $this->writeUByte(self::$ctypes[$key_type] << 4 |
273 self::$ctypes[$val_type]);
274 }
275 $this->containers[] = $this->state;
276
277 return $written;
278 }
279
280 public function writeCollectionEnd()
281 {

Callers

nothing calls this directly

Calls 3

writeByteMethod · 0.95
writeVarintMethod · 0.95
writeUByteMethod · 0.95

Tested by

no test coverage detected