| 90 | } |
| 91 | |
| 92 | Value marshallBinary(const std::vector<uint8_t>& value, const Ref<BridgeContext>& /*bridgeContext*/) { |
| 93 | auto bytes = makeShared<ByteBuffer>(); |
| 94 | bytes->set(value.data(), value.data() + value.size()); |
| 95 | |
| 96 | return Value(makeShared<ValueTypedArray>(TypedArrayType::Uint8Array, bytes->toBytesView())); |
| 97 | } |
| 98 | |
| 99 | std::string unmarshallString(const Value& value, const Ref<BridgeContext>& bridgeContext) { |
| 100 | return value.checkedTo<StringBox>(*bridgeContext).slowToString(); |
nothing calls this directly
no test coverage detected