#include "net/base/directory_lister.h"
#include <algorithm>
#include <utility>
#include "base/check.h"
#include "base/files/file_enumerator.h"
#include "base/files/file_util.h"
#include "base/functional/bind.h"
#include "base/i18n/file_util_icu.h"
#include "base/location.h"
#include "base/notreached.h"
#include "base/task/sequenced_task_runner.h"
#include "base/task/task_runner.h"
#include "base/task/thread_pool.h"
#include "base/threading/thread_restrictions.h"
#include "net/base/net_errors.h"
namespace net {
namespace {
bool IsDotDot(const base::FilePath& path) { … }
bool CompareAlphaDirsFirst(const DirectoryLister::DirectoryListerData& a,
const DirectoryLister::DirectoryListerData& b) { … }
void SortData(std::vector<DirectoryLister::DirectoryListerData>* data,
DirectoryLister::ListingType listing_type) { … }
}
DirectoryLister::DirectoryLister(const base::FilePath& dir,
DirectoryListerDelegate* delegate)
: … { … }
DirectoryLister::DirectoryLister(const base::FilePath& dir,
ListingType type,
DirectoryListerDelegate* delegate)
: … { … }
DirectoryLister::~DirectoryLister() { … }
void DirectoryLister::Start() { … }
void DirectoryLister::Cancel() { … }
DirectoryLister::Core::Core(const base::FilePath& dir,
ListingType type,
DirectoryLister* lister)
: … { … }
DirectoryLister::Core::~Core() = default;
void DirectoryLister::Core::CancelOnOriginSequence() { … }
void DirectoryLister::Core::Start() { … }
bool DirectoryLister::Core::IsCancelled() const { … }
void DirectoryLister::Core::DoneOnOriginSequence(
std::unique_ptr<DirectoryList> directory_list,
int error) const { … }
void DirectoryLister::OnListFile(const DirectoryListerData& data) { … }
void DirectoryLister::OnListDone(int error) { … }
}