#include "services/on_device_model/public/cpp/model_assets.h"
#include <cstdint>
#include <string_view>
#include "base/files/file.h"
#include "base/files/file_util.h"
#include "base/task/thread_pool.h"
#include "build/build_config.h"
namespace on_device_model {
namespace {
#if BUILDFLAG(IS_FUCHSIA)
constexpr uint32_t kWeightsFlags =
base::File::FLAG_OPEN | base::File::FLAG_READ | base::File::FLAG_WRITE;
#else
constexpr uint32_t kWeightsFlags = …;
#endif
void PrefetchFile(const base::FilePath& path) { … }
}
ModelAssetPaths::ModelAssetPaths() = default;
ModelAssetPaths::ModelAssetPaths(const ModelAssetPaths&) = default;
ModelAssetPaths::~ModelAssetPaths() = default;
ModelAssets::ModelAssets() = default;
ModelAssets::ModelAssets(ModelAssets&&) = default;
ModelAssets& ModelAssets::operator=(ModelAssets&&) = default;
ModelAssets::~ModelAssets() = default;
ModelAssets LoadModelAssets(const ModelAssetPaths& paths) { … }
AdaptationAssetPaths::AdaptationAssetPaths() = default;
AdaptationAssetPaths::AdaptationAssetPaths(const AdaptationAssetPaths&) =
default;
AdaptationAssetPaths::~AdaptationAssetPaths() = default;
AdaptationAssets::AdaptationAssets() = default;
AdaptationAssets::AdaptationAssets(AdaptationAssets&&) = default;
AdaptationAssets& AdaptationAssets::operator=(AdaptationAssets&&) = default;
AdaptationAssets::~AdaptationAssets() = default;
AdaptationAssets LoadAdaptationAssets(const AdaptationAssetPaths& paths) { … }
}