Bitwarden-app-android-iphon.../src/App/Models/Api/Request/DeviceRequest.cs

24 lines
687 B
C#
Raw Normal View History

2016-06-22 04:29:29 +02:00
using Bit.App.Abstractions;
using PushNotification.Plugin.Abstractions;
using Xamarin.Forms;
2016-06-18 22:10:09 +02:00
namespace Bit.App.Models.Api
{
public class DeviceRequest
{
2016-06-22 04:29:29 +02:00
public DeviceRequest() { }
public DeviceRequest(IAppIdService appIdService, IDeviceInfoService deviceInfoService)
2016-06-22 04:29:29 +02:00
{
Identifier = appIdService.AppId;
Name = deviceInfoService.Model;
Type = Device.OS == TargetPlatform.Android ? DeviceType.Android : DeviceType.iOS;
2016-06-22 04:29:29 +02:00
}
2016-06-18 22:10:09 +02:00
public DeviceType Type { get; set; }
public string Name { get; set; }
2016-06-22 04:29:29 +02:00
public string Identifier { get; set; }
2016-06-18 22:10:09 +02:00
public string PushToken { get; set; }
}
}