mirror of
https://github.com/DarthAffe/RGB.NET.git
synced 2025-12-12 17:48:31 +00:00
47 lines
1.5 KiB
C#
47 lines
1.5 KiB
C#
using System.Collections.Generic;
|
|
|
|
namespace RGB.NET.Core
|
|
{
|
|
/// <summary>
|
|
/// Represents a generic device provider.
|
|
/// </summary>
|
|
public interface IDeviceProvider
|
|
{
|
|
#region Properties & Fields
|
|
|
|
/// <summary>
|
|
/// Indicates if the used SDK is initialized and ready to use.
|
|
/// </summary>
|
|
bool IsInitialized { get; }
|
|
|
|
/// <summary>
|
|
/// Gets a list of <see cref="IRGBDevice"/> loaded by this <see cref="IDeviceProvider"/>.
|
|
/// </summary>
|
|
IEnumerable<IRGBDevice> Devices { get; }
|
|
|
|
/// <summary>
|
|
/// Gets whether the application has exclusive access to devices or not.
|
|
/// </summary>
|
|
bool HasExclusiveAccess { get; }
|
|
|
|
#endregion
|
|
|
|
#region Methods
|
|
|
|
/// <summary>
|
|
/// Initializes the <see cref="IDeviceProvider"/> if not already happened or reloads it if it is already initialized.
|
|
/// </summary>
|
|
/// <param name="exclusiveAccessIfPossible">Specifies whether the application should request exclusive access of possible or not.</param>
|
|
/// <param name="throwExceptions">Specifies whether exception during the initialization sequence should be thrown or not.</param>
|
|
/// <returns></returns>
|
|
bool Initialize(bool exclusiveAccessIfPossible = false, bool throwExceptions = false);
|
|
|
|
/// <summary>
|
|
/// Resets all handled <see cref="IRGBDevice"/> back top default.
|
|
/// </summary>
|
|
void ResetDevices();
|
|
|
|
#endregion
|
|
}
|
|
}
|