16 lines
456 B
C#
16 lines
456 B
C#
|
|
using System;
|
||
|
|
using RudderSdk.Core.Abstractions;
|
||
|
|
|
||
|
|
namespace RudderSdk.Core;
|
||
|
|
|
||
|
|
/// <summary>
|
||
|
|
/// Default <see cref="IDeviceIdProvider"/> generating a random GUID per app run.
|
||
|
|
/// Every run looks like a fresh device to the backend; provide a persistent
|
||
|
|
/// implementation for production.
|
||
|
|
/// </summary>
|
||
|
|
public sealed class GuidDeviceIdProvider : IDeviceIdProvider
|
||
|
|
{
|
||
|
|
/// <inheritdoc />
|
||
|
|
public string DeviceId { get; } = Guid.NewGuid().ToString("N");
|
||
|
|
}
|