#include "content/browser/hyphenation/hyphenation_impl.h"
#include <map>
#include <utility>
#include "base/files/file.h"
#include "base/files/file_path.h"
#include "base/files/file_util.h"
#include "base/metrics/histogram_macros.h"
#include "base/no_destructor.h"
#include "base/ranges/algorithm.h"
#include "base/strings/string_util.h"
#include "base/strings/stringprintf.h"
#include "base/task/sequenced_task_runner.h"
#include "base/task/thread_pool.h"
#include "base/timer/elapsed_timer.h"
#include "build/build_config.h"
#include "content/public/browser/browser_thread.h"
#include "content/public/browser/content_browser_client.h"
#include "content/public/common/content_client.h"
#include "mojo/public/cpp/bindings/self_owned_receiver.h"
namespace {
struct Dictionaries { … };
bool IsValidLocale(const std::string& locale) { … }
base::File GetDictionaryFile(const std::string& locale) { … }
}
namespace hyphenation {
HyphenationImpl::HyphenationImpl() { … }
HyphenationImpl::~HyphenationImpl() { … }
void HyphenationImpl::Create(
mojo::PendingReceiver<blink::mojom::Hyphenation> receiver) { … }
scoped_refptr<base::SequencedTaskRunner> HyphenationImpl::GetTaskRunner() { … }
#if !BUILDFLAG(IS_ANDROID)
void HyphenationImpl::RegisterGetDictionary() { … }
void HyphenationImpl::SetDirectory(const base::FilePath& dir) { … }
#endif
void HyphenationImpl::OpenDictionary(const std::string& locale,
OpenDictionaryCallback callback) { … }
}