function GPBJsonWire::serializeFieldToStream
1 call to GPBJsonWire::serializeFieldToStream()
- Message::serializeFieldToJsonStream in vendor/
google/ protobuf/ src/ Google/ Protobuf/ Internal/ Message.php - @ignore
File
-
vendor/
google/ protobuf/ src/ Google/ Protobuf/ Internal/ GPBJsonWire.php, line 15
Class
Namespace
Google\Protobuf\InternalCode
public static function serializeFieldToStream($value, $field, &$output, $has_field_name = true) {
if ($has_field_name) {
$output->writeRaw("\"", 1);
$field_name = GPBJsonWire::formatFieldName($field);
$output->writeRaw($field_name, strlen($field_name));
$output->writeRaw("\":", 2);
}
return static::serializeFieldValueToStream($value, $field, $output, !$has_field_name);
}