lr: add support for location resolver disable commands

This commit is contained in:
Michael Scire
2022-10-11 10:47:40 -07:00
committed by SciresM
parent 05de5538d6
commit e1aff401ba
12 changed files with 110 additions and 10 deletions

View File

@@ -22,12 +22,13 @@ namespace ams::lr {
class ContentLocationResolverImpl : public LocationResolverImplBase {
private:
ncm::StorageId m_storage_id;
bool m_enabled;
/* Objects for this storage type. */
ncm::ContentMetaDatabase m_content_meta_database;
ncm::ContentStorage m_content_storage;
public:
ContentLocationResolverImpl(ncm::StorageId storage_id) : m_storage_id(storage_id), m_content_meta_database(), m_content_storage() { /* ... */ }
ContentLocationResolverImpl(ncm::StorageId storage_id, bool enabled) : m_storage_id(storage_id), m_enabled(enabled), m_content_meta_database(), m_content_storage() { /* ... */ }
~ContentLocationResolverImpl();
private:
@@ -61,6 +62,7 @@ namespace ams::lr {
Result RedirectApplicationProgramPathForDebugDeprecated(const Path &path, ncm::ProgramId id);
Result RedirectApplicationProgramPathForDebug(const Path &path, ncm::ProgramId id, ncm::ProgramId owner_id);
Result EraseProgramRedirectionForDebug(ncm::ProgramId id);
Result Disable();
};
static_assert(lr::IsILocationResolver<ContentLocationResolverImpl>);