#include "reference_drivers/async_reference_driver.h"
#include <cstdint>
#include <memory>
#include <thread>
#include <tuple>
#include <utility>
#include <vector>
#include "ipcz/ipcz.h"
#include "reference_drivers/object.h"
#include "reference_drivers/single_process_reference_driver_base.h"
#include "third_party/abseil-cpp/absl/base/macros.h"
#include "third_party/abseil-cpp/absl/synchronization/mutex.h"
#include "third_party/abseil-cpp/absl/synchronization/notification.h"
#include "third_party/abseil-cpp/absl/types/span.h"
#include "util/ref_counted.h"
namespace ipcz::reference_drivers {
namespace {
class AsyncTransport : public ObjectImpl<AsyncTransport, Object::kTransport> { … };
IpczResult IPCZ_API CreateTransports(IpczDriverHandle transport0,
IpczDriverHandle transport1,
uint32_t,
const void*,
IpczDriverHandle* new_transport0,
IpczDriverHandle* new_transport1) { … }
IpczResult IPCZ_API ActivateTransport(IpczDriverHandle transport,
IpczHandle listener,
IpczTransportActivityHandler handler,
uint32_t,
const void*) { … }
IpczResult IPCZ_API DeactivateTransport(IpczDriverHandle transport,
uint32_t,
const void*) { … }
IpczResult IPCZ_API Transmit(IpczDriverHandle transport,
const void* data,
size_t num_bytes,
const IpczDriverHandle* handles,
size_t num_handles,
uint32_t,
const void*) { … }
IpczResult IPCZ_API SerializeWithForcedBrokering(IpczDriverHandle handle,
IpczDriverHandle transport,
uint32_t flags,
const void* options,
volatile void* data,
size_t* num_bytes,
IpczDriverHandle* handles,
size_t* num_handles) { … }
}
const IpczDriver kAsyncReferenceDriver = …;
const IpczDriver kAsyncReferenceDriverWithForcedBrokering = …;
AsyncTransportPair CreateAsyncTransportPair() { … }
std::pair<IpczDriverHandle, IpczDriverHandle>
CreateAsyncTransportPairForBrokers() { … }
}