diff options
author | liamwhite <liamwhite@users.noreply.github.com> | 2024-02-10 22:00:43 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-02-10 22:00:43 +0100 |
commit | 2337397a1530e2d0cd6cab4bd22517747b80de6c (patch) | |
tree | 8bcabd801561c8e63097fff8861f22a09fe8a9d6 /src/core/hle/service/bcat/bcat.cpp | |
parent | Merge pull request #12949 from liamwhite/multi-wait (diff) | |
parent | service: bcat: Address review issues (diff) | |
download | yuzu-2337397a1530e2d0cd6cab4bd22517747b80de6c.tar yuzu-2337397a1530e2d0cd6cab4bd22517747b80de6c.tar.gz yuzu-2337397a1530e2d0cd6cab4bd22517747b80de6c.tar.bz2 yuzu-2337397a1530e2d0cd6cab4bd22517747b80de6c.tar.lz yuzu-2337397a1530e2d0cd6cab4bd22517747b80de6c.tar.xz yuzu-2337397a1530e2d0cd6cab4bd22517747b80de6c.tar.zst yuzu-2337397a1530e2d0cd6cab4bd22517747b80de6c.zip |
Diffstat (limited to 'src/core/hle/service/bcat/bcat.cpp')
-rw-r--r-- | src/core/hle/service/bcat/bcat.cpp | 42 |
1 files changed, 28 insertions, 14 deletions
diff --git a/src/core/hle/service/bcat/bcat.cpp b/src/core/hle/service/bcat/bcat.cpp index d0ac17324..ea8b15998 100644 --- a/src/core/hle/service/bcat/bcat.cpp +++ b/src/core/hle/service/bcat/bcat.cpp @@ -1,24 +1,38 @@ // SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project // SPDX-License-Identifier: GPL-2.0-or-later +#include "core/hle/service/bcat/backend/backend.h" #include "core/hle/service/bcat/bcat.h" +#include "core/hle/service/bcat/news/service_creator.h" +#include "core/hle/service/bcat/service_creator.h" +#include "core/hle/service/server_manager.h" namespace Service::BCAT { -BCAT::BCAT(Core::System& system_, std::shared_ptr<Module> module_, - FileSystem::FileSystemController& fsc_, const char* name_) - : Interface(system_, std::move(module_), fsc_, name_) { - // clang-format off - static const FunctionInfo functions[] = { - {0, &BCAT::CreateBcatService, "CreateBcatService"}, - {1, &BCAT::CreateDeliveryCacheStorageService, "CreateDeliveryCacheStorageService"}, - {2, &BCAT::CreateDeliveryCacheStorageServiceWithApplicationId, "CreateDeliveryCacheStorageServiceWithApplicationId"}, - {3, nullptr, "CreateDeliveryCacheProgressService"}, - {4, nullptr, "CreateDeliveryCacheProgressServiceWithApplicationId"}, - }; - // clang-format on - RegisterHandlers(functions); +void LoopProcess(Core::System& system) { + auto server_manager = std::make_unique<ServerManager>(system); + + server_manager->RegisterNamedService("bcat:a", + std::make_shared<IServiceCreator>(system, "bcat:a")); + server_manager->RegisterNamedService("bcat:m", + std::make_shared<IServiceCreator>(system, "bcat:m")); + server_manager->RegisterNamedService("bcat:u", + std::make_shared<IServiceCreator>(system, "bcat:u")); + server_manager->RegisterNamedService("bcat:s", + std::make_shared<IServiceCreator>(system, "bcat:s")); + + server_manager->RegisterNamedService( + "news:a", std::make_shared<News::IServiceCreator>(system, 0xffffffff, "news:a")); + server_manager->RegisterNamedService( + "news:p", std::make_shared<News::IServiceCreator>(system, 0x1, "news:p")); + server_manager->RegisterNamedService( + "news:c", std::make_shared<News::IServiceCreator>(system, 0x2, "news:c")); + server_manager->RegisterNamedService( + "news:v", std::make_shared<News::IServiceCreator>(system, 0x4, "news:v")); + server_manager->RegisterNamedService( + "news:m", std::make_shared<News::IServiceCreator>(system, 0xd, "news:m")); + + ServerManager::RunServer(std::move(server_manager)); } -BCAT::~BCAT() = default; } // namespace Service::BCAT |