mirror of
https://github.com/bitwarden/mobile.git
synced 2024-11-26 12:16:07 +01:00
setup new settings service
This commit is contained in:
parent
3ad1e8a3ba
commit
0cd09cf03a
@ -211,6 +211,7 @@ namespace Bit.Android
|
||||
.RegisterType<ILogService, LogService>(new ContainerControlledLifetimeManager())
|
||||
.RegisterType<IHttpService, HttpService>(new ContainerControlledLifetimeManager())
|
||||
.RegisterType<ITokenService, TokenService>(new ContainerControlledLifetimeManager())
|
||||
.RegisterType<ISettingsService, SettingsService>(new ContainerControlledLifetimeManager())
|
||||
// Repositories
|
||||
.RegisterType<IFolderRepository, FolderRepository>(new ContainerControlledLifetimeManager())
|
||||
.RegisterType<IFolderApiRepository, FolderApiRepository>(new ContainerControlledLifetimeManager())
|
||||
|
6
src/App/Abstractions/Services/ISettingsService.cs
Normal file
6
src/App/Abstractions/Services/ISettingsService.cs
Normal file
@ -0,0 +1,6 @@
|
||||
namespace Bit.App.Abstractions
|
||||
{
|
||||
public interface ISettingsService
|
||||
{
|
||||
}
|
||||
}
|
@ -38,6 +38,7 @@
|
||||
<Compile Include="Abstractions\Repositories\IAccountsApiRepository.cs" />
|
||||
<Compile Include="Abstractions\Repositories\IDeviceApiRepository.cs" />
|
||||
<Compile Include="Abstractions\Repositories\ISettingsRepository.cs" />
|
||||
<Compile Include="Abstractions\Services\ISettingsService.cs" />
|
||||
<Compile Include="Abstractions\Services\ITokenService.cs" />
|
||||
<Compile Include="Abstractions\Services\IHttpService.cs" />
|
||||
<Compile Include="Abstractions\Services\IDeviceInfoService.cs" />
|
||||
@ -183,6 +184,7 @@
|
||||
<DesignTime>True</DesignTime>
|
||||
<DependentUpon>AppResources.zh-Hans.resx</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Services\SettingsService.cs" />
|
||||
<Compile Include="Services\TokenService.cs" />
|
||||
<Compile Include="Services\AppIdService.cs" />
|
||||
<Compile Include="Abstractions\Services\ILockService.cs" />
|
||||
|
19
src/App/Services/SettingsService.cs
Normal file
19
src/App/Services/SettingsService.cs
Normal file
@ -0,0 +1,19 @@
|
||||
using Bit.App.Abstractions;
|
||||
using Plugin.Settings.Abstractions;
|
||||
|
||||
namespace Bit.App.Services
|
||||
{
|
||||
public class SettingsService : ISettingsService
|
||||
{
|
||||
private readonly ISettingsRepository _settingsRepository;
|
||||
private readonly ISettings _settings;
|
||||
|
||||
public SettingsService(
|
||||
ISettingsRepository settingsRepository,
|
||||
ISettings settings)
|
||||
{
|
||||
_settingsRepository = settingsRepository;
|
||||
_settings = settings;
|
||||
}
|
||||
}
|
||||
}
|
@ -281,6 +281,7 @@ namespace Bit.iOS.Extension
|
||||
.RegisterType<ILogService, LogService>(new ContainerControlledLifetimeManager())
|
||||
.RegisterType<IHttpService, HttpService>(new ContainerControlledLifetimeManager())
|
||||
.RegisterType<ITokenService, TokenService>(new ContainerControlledLifetimeManager())
|
||||
.RegisterType<ISettingsService, SettingsService>(new ContainerControlledLifetimeManager())
|
||||
// Repositories
|
||||
.RegisterType<IFolderRepository, FolderRepository>(new ContainerControlledLifetimeManager())
|
||||
.RegisterType<IFolderApiRepository, FolderApiRepository>(new ContainerControlledLifetimeManager())
|
||||
|
@ -266,7 +266,7 @@ namespace Bit.iOS
|
||||
.RegisterType<ILogService, LogService>(new ContainerControlledLifetimeManager())
|
||||
.RegisterType<IHttpService, HttpService>(new ContainerControlledLifetimeManager())
|
||||
.RegisterType<ITokenService, TokenService>(new ContainerControlledLifetimeManager())
|
||||
// Repositories
|
||||
.RegisterType<ISettingsService, SettingsService>(new ContainerControlledLifetimeManager())
|
||||
// Repositories
|
||||
.RegisterType<IFolderRepository, FolderRepository>(new ContainerControlledLifetimeManager())
|
||||
.RegisterType<IFolderApiRepository, FolderApiRepository>(new ContainerControlledLifetimeManager())
|
||||
|
Loading…
Reference in New Issue
Block a user