170 {
171 switch (
static_cast<EncodedType
>(
type)) {
173 return EncodableValue();
174 case EncodedType::kTrue:
175 return EncodableValue(true);
176 case EncodedType::kFalse:
177 return EncodableValue(false);
179 return EncodableValue(
stream->ReadInt32());
181 return EncodableValue(
stream->ReadInt64());
182 case EncodedType::kFloat64:
184 return EncodableValue(
stream->ReadDouble());
185 case EncodedType::kLargeInt:
186 case EncodedType::kString: {
188 std::string string_value;
189 string_value.resize(
size);
190 stream->ReadBytes(
reinterpret_cast<uint8_t*
>(&string_value[0]),
size);
191 return EncodableValue(string_value);
192 }
193 case EncodedType::kUInt8List:
194 return ReadVector<uint8_t>(
stream);
195 case EncodedType::kInt32List:
196 return ReadVector<int32_t>(
stream);
197 case EncodedType::kInt64List:
198 return ReadVector<int64_t>(
stream);
199 case EncodedType::kFloat64List:
200 return ReadVector<double>(
stream);
204 list_value.reserve(
length);
207 }
208 return EncodableValue(list_value);
209 }
210 case EncodedType::kMap: {
216 map_value.emplace(std::move(
key), std::move(
value));
217 }
218 return EncodableValue(map_value);
219 }
220 case EncodedType::kFloat32List: {
221 return ReadVector<float>(
stream);
222 }
223 }
224 std::cerr << "Unknown type in StandardCodecSerializer::ReadValueOfType: "
225 <<
static_cast<int>(
type) << std::endl;
226 return EncodableValue();
227}
EncodableValue ReadValue(ByteStreamReader *stream) const
size_t ReadSize(ByteStreamReader *stream) const
static constexpr const char * kList
std::vector< EncodableValue > EncodableList
std::map< EncodableValue, EncodableValue > EncodableMap
it will be possible to load the file into Perfetto s trace viewer disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive keep the shell running after the Dart script has completed enable serial On low power devices with low core running concurrent GC tasks on threads can cause them to contend with the UI thread which could potentially lead to jank This option turns off all concurrent GC activities domain network JSON encoded network policy per domain This overrides the DisallowInsecureConnections switch Embedder can specify whether to allow or disallow insecure connections at a domain level old gen heap size