Show / Hide Table of Contents

Interface IRGBDeviceProvider

Represents a generic device provider.

Inherited Members
IDisposable.Dispose()
Namespace: RGB.NET.Core
Assembly: RGB.NET.Core.dll
Syntax
public interface IRGBDeviceProvider : IDisposable

Properties

| Edit this page View Source

Devices

Gets a collection of IRGBDevice loaded by this IRGBDeviceProvider.

Declaration
IReadOnlyList<IRGBDevice> Devices { get; }
Property Value
Type Description
IReadOnlyList<IRGBDevice>
| Edit this page View Source

IsInitialized

Indicates if the used SDK is initialized and ready to use.

Declaration
bool IsInitialized { get; }
Property Value
Type Description
bool
| Edit this page View Source

ThrowsExceptions

Indicates if exceptions in the device provider are thrown or silently ignored.

Declaration
bool ThrowsExceptions { get; }
Property Value
Type Description
bool
Remarks

This should only be set to true for debugging/development purposes. Production code should use the Exception-Event to handle exceptions.

| Edit this page View Source

UpdateTriggers

Gets a collection IDeviceUpdateTrigger registered to this device provider.

Declaration
IReadOnlyList<(int id, IDeviceUpdateTrigger trigger)> UpdateTriggers { get; }
Property Value
Type Description
IReadOnlyList<(int id, IDeviceUpdateTrigger trigger)>

Methods

| Edit this page View Source

Initialize(RGBDeviceType, bool)

Initializes the device provider and loads available devices.

Declaration
bool Initialize(RGBDeviceType loadFilter = (RGBDeviceType)-1, bool throwExceptions = false)
Parameters
Type Name Description
RGBDeviceType loadFilter

RGBDeviceType-flags to filter the devices to load.

bool throwExceptions

Specifies if exceptions should be thrown or silently be ignored.

Returns
Type Description
bool

true if the initialization was successful; false otherwise.

Events

| Edit this page View Source

DevicesChanged

Occures when the devices provided by this device provider changed.

Declaration
event EventHandler<DevicesChangedEventArgs>? DevicesChanged
Event Type
Type Description
EventHandler<DevicesChangedEventArgs>
| Edit this page View Source

Exception

Occurs when an exception is thrown in the device provider.

Declaration
event EventHandler<ExceptionEventArgs>? Exception
Event Type
Type Description
EventHandler<ExceptionEventArgs>
  • Edit this page
  • View Source
In this article
Back to top Generated by DocFX