diff --git a/Essentials-Architecture.md b/Essentials-Architecture.md index 5f1b1e5..2cc5e4f 100644 --- a/Essentials-Architecture.md +++ b/Essentials-Architecture.md @@ -123,20 +123,20 @@ In each device/room step, a device factory process is called. We call subsequent ``` // Try local factories first - var newDev = DeviceFactory.GetDevice(devConf); +var newDev = DeviceFactory.GetDevice(devConf); - if (newDev == null) - newDev = BridgeFactory.GetDevice(devConf); +if (newDev == null) + newDev = BridgeFactory.GetDevice(devConf); - // Then associated library factories - if (newDev == null) - newDev = PepperDash.Essentials.Core.DeviceFactory.GetDevice(devConf); - if (newDev == null) - newDev = PepperDash.Essentials.Devices.Common.DeviceFactory.GetDevice(devConf); - if (newDev == null) - newDev = PepperDash.Essentials.DM.DeviceFactory.GetDevice(devConf); - if (newDev == null) - newDev = PepperDash.Essentials.Devices.Displays.DisplayDeviceFactory.GetDevice(devConf); +// Then associated library factories +if (newDev == null) + newDev = PepperDash.Essentials.Core.DeviceFactory.GetDevice(devConf); +if (newDev == null) + newDev = PepperDash.Essentials.Devices.Common.DeviceFactory.GetDevice(devConf); +if (newDev == null) + newDev = PepperDash.Essentials.DM.DeviceFactory.GetDevice(devConf); +if (newDev == null) + newDev = PepperDash.Essentials.Devices.Displays.DisplayDeviceFactory.GetDevice(devConf); ``` In each respective factory, or device constructor, the config's properties object is either converted to a config object or read from using `JToken` methods. This builds the device which may be ready to go, or may require activation as described above.