#include "mojo/public/cpp/base/read_only_file_mojom_traits.h"
#include "base/files/file.h"
#include "build/build_config.h"
#if BUILDFLAG(IS_POSIX) || BUILDFLAG(IS_FUCHSIA)
#include <fcntl.h>
#include <sys/stat.h>
#include <unistd.h>
#endif
#if BUILDFLAG(IS_WIN)
#include <windows.h>
#include "base/win/security_util.h"
#endif
namespace mojo {
namespace {
bool IsReadOnlyFile(base::File& file) { … }
bool IsPhysicalFile(base::File& file) { … }
}
mojo::PlatformHandle StructTraits<mojo_base::mojom::ReadOnlyFileDataView,
base::File>::fd(base::File& file) { … }
bool StructTraits<mojo_base::mojom::ReadOnlyFileDataView, base::File>::Read(
mojo_base::mojom::ReadOnlyFileDataView data,
base::File* file) { … }
}