#ifndef MOJO_PUBLIC_CPP_SYSTEM_MESSAGE_H_
#define MOJO_PUBLIC_CPP_SYSTEM_MESSAGE_H_
#include <limits>
#include <string_view>
#include <vector>
#include "base/numerics/safe_conversions.h"
#include "mojo/public/c/system/message_pipe.h"
#include "mojo/public/cpp/system/handle.h"
namespace mojo {
const MojoMessageHandle kInvalidMessageHandleValue = …;
class MessageHandle { … };
ScopedMessageHandle;
inline MojoResult CreateMessage(ScopedMessageHandle* handle,
MojoCreateMessageFlags flags) { … }
inline MojoResult GetMessageData(MessageHandle message,
void** buffer,
uint32_t* num_bytes,
std::vector<ScopedHandle>* handles,
MojoGetMessageDataFlags flags) { … }
inline MojoResult NotifyBadMessage(MessageHandle message,
const std::string_view& error) { … }
}
#endif