#ifndef COMPONENTS_DOWNLOAD_INTERNAL_BACKGROUND_SERVICE_ENTRY_UTILS_H_
#define COMPONENTS_DOWNLOAD_INTERNAL_BACKGROUND_SERVICE_ENTRY_UTILS_H_
#include <map>
#include <set>
#include <vector>
#include "components/download/internal/background_service/model.h"
#include "components/download/internal/background_service/scheduler/device_status.h"
#include "components/download/public/background_service/clients.h"
#include "components/download/public/background_service/download_metadata.h"
namespace download {
class DownloadDriver;
struct DownloadMetaData;
struct Entry;
namespace util {
uint32_t GetNumberOfLiveEntriesForClient(DownloadClient client,
const std::vector<Entry*>& entries);
std::map<DownloadClient, std::vector<DownloadMetaData>>
MapEntriesToMetadataForClients(const std::set<DownloadClient>& clients,
const std::vector<Entry*>& entries,
DownloadDriver* driver);
Criteria GetSchedulingCriteria(const Model::EntryList& entries,
int optimal_battery_percentage);
bool EntryBetterThan(const Entry& lhs, const Entry& rhs);
DownloadMetaData BuildDownloadMetaData(Entry* entry, DownloadDriver* driver);
}
}
#endif