Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
16 commits
Select commit Hold shift + click to select a range
babfebf
chore(deps): update NuGet package versions in `Directory.Packages.props`
darthsharp Apr 20, 2026
1bac142
refactor(core): reorganize `CreativeCoders.HomeMatic` namespaces and …
darthsharp Apr 20, 2026
e6b5e05
chore(project): fix inconsistent formatting in package references in …
darthsharp Apr 20, 2026
5d34421
refactor(core): remove unused XML-RPC entities and enhance documentation
darthsharp Apr 20, 2026
56eced0
refactor(homeMatic): simplify `CcuDeviceBuilder` and make `ParamSetKe…
darthsharp Apr 20, 2026
0f48e12
refactor(core, xmlrpc): rename enums and properties for consistency
darthsharp Apr 20, 2026
e34bae0
feat(homeMatic): add `CcuRoutingTable` for efficient device-to-client…
darthsharp Apr 20, 2026
14a9578
feat(tests): add comprehensive unit tests for HomeMatic components
darthsharp Apr 20, 2026
8bf376d
feat(exporting): add support for `ParamValueNameWhitelist` in device …
darthsharp Apr 20, 2026
056539b
feat(tests): add builders for creating fake HomeMatic devices and cha…
darthsharp Apr 20, 2026
895f395
feat(core): enhance XML documentation for HomeMatic components
darthsharp Apr 20, 2026
8536c9f
Merge branch 'main' into feature/refactorprojects
darthsharp Apr 24, 2026
05bfac9
refactor: clean up namespaces and enhance XML documentation
darthsharp Apr 24, 2026
00e692b
refactor: improve type and collection definitions, add annotations
darthsharp Apr 24, 2026
f1f3dda
refactor(core, cli): apply `[PublicAPI]` and suppressions, enhance ty…
darthsharp Apr 25, 2026
33cc6d3
chore(tools): add `.editorconfig` with `configure_await_analysis_mode…
darthsharp Apr 25, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ trim_trailing_whitespace = true
# IDE0060: Remove unused parameter
dotnet_diagnostic.IDE0060.severity = warning
configure_await_analysis_mode = library
resharper_inheritdoc_consider_usage_highlighting = none
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -324,3 +324,4 @@ ASALocalRun/
.artifacts

.tests
.tokensave
57 changes: 27 additions & 30 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
@@ -1,31 +1,28 @@
<Project>

<PropertyGroup>
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
</PropertyGroup>

<ItemGroup>
<PackageVersion Include="CreativeCoders.CakeBuild" Version="6.7.1"/>
<PackageVersion Include="CreativeCoders.Cli.Core" Version="6.7.0"/>
<PackageVersion Include="CreativeCoders.Cli.Hosting" Version="6.7.0"/>
<PackageVersion Include="CreativeCoders.Configuration" Version="6.7.0"/>
<PackageVersion Include="CreativeCoders.Core" Version="6.7.0"/>
<PackageVersion Include="CreativeCoders.Net.JsonRpc" Version="6.7.0"/>
<PackageVersion Include="CreativeCoders.Net.XmlRpc" Version="6.7.0"/>
<PackageVersion Include="CreativeCoders.SysConsole.Cli.Actions" Version="6.7.0"/>
<PackageVersion Include="coverlet.collector" Version="8.0.1"/>
<PackageVersion Include="Devlooped.CredentialManager" Version="2.7.0"/>
<PackageVersion Include="FakeItEasy" Version="9.0.1"/>
<PackageVersion Include="AwesomeAssertions" Version="9.4.0"/>
<PackageVersion Include="JetBrains.Annotations" Version="2025.2.4"/>
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="10.0.6"/>
<PackageVersion Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="10.0.6"/>
<PackageVersion Include="Microsoft.Extensions.Http" Version="10.0.6"/>
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="18.4.0"/>
<PackageVersion Include="Spectre.Console" Version="0.54.0"/>
<PackageVersion Include="xunit" Version="2.9.3"/>
<PackageVersion Include="xunit.runner.visualstudio" Version="3.1.5"/>
<PackageVersion Include="XunitXml.TestLogger" Version="8.0.0"/>
</ItemGroup>

</Project>
<PropertyGroup>
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
</PropertyGroup>
<ItemGroup>
<PackageVersion Include="CreativeCoders.CakeBuild" Version="6.7.2" />
<PackageVersion Include="CreativeCoders.Cli.Core" Version="6.7.2" />
<PackageVersion Include="CreativeCoders.Cli.Hosting" Version="6.7.2" />
<PackageVersion Include="CreativeCoders.Configuration" Version="6.7.2" />
<PackageVersion Include="CreativeCoders.Core" Version="6.7.2" />
<PackageVersion Include="CreativeCoders.Net.JsonRpc" Version="6.7.2" />
<PackageVersion Include="CreativeCoders.Net.XmlRpc" Version="6.7.2" />
<PackageVersion Include="CreativeCoders.SysConsole.Cli.Actions" Version="6.7.2" />
<PackageVersion Include="coverlet.collector" Version="8.0.1" />
<PackageVersion Include="Devlooped.CredentialManager" Version="2.7.0" />
<PackageVersion Include="FakeItEasy" Version="9.0.1" />
<PackageVersion Include="AwesomeAssertions" Version="9.4.0" />
<PackageVersion Include="JetBrains.Annotations" Version="2025.2.4" />
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="10.0.6" />
<PackageVersion Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="10.0.6" />
<PackageVersion Include="Microsoft.Extensions.Http" Version="10.0.6" />
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="18.4.0" />
<PackageVersion Include="Spectre.Console" Version="0.55.2" />
<PackageVersion Include="xunit" Version="2.9.3" />
<PackageVersion Include="xunit.runner.visualstudio" Version="3.1.5" />
<PackageVersion Include="XunitXml.TestLogger" Version="8.0.0" />
</ItemGroup>
</Project>
6 changes: 6 additions & 0 deletions HomeMatic.sln
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "__global", "__global", "{73
GitVersion.yml = GitVersion.yml
Directory.Packages.props = Directory.Packages.props
.github\dependabot.yml = .github\dependabot.yml
.editorconfig = .editorconfig
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Cli", "Cli", "{B79F3B3E-C9CE-4629-ADE3-B1659AF9C673}"
Expand Down Expand Up @@ -74,6 +75,11 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CreativeCoders.HomeMatic.To
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CreativeCoders.HomeMatic.Tools.Cli.Commands", "source\Tools\Cli\CreativeCoders.HomeMatic.Tools.Cli.Commands\CreativeCoders.HomeMatic.Tools.Cli.Commands.csproj", "{822ECD72-5DB0-4637-B794-CE27B02827AC}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "__docs", "__docs", "{24644358-1979-4A95-A64C-C686A71E2AF1}"
ProjectSection(SolutionItems) = preProject
docs\HomeMatic-XmlRpc.md = docs\HomeMatic-XmlRpc.md
EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down
1 change: 0 additions & 1 deletion build/BuildContext.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
using CreativeCoders.CakeBuild.Tasks.Templates.Settings;
using CreativeCoders.Core;
using CreativeCoders.Core.Collections;
using CreativeCoders.Core.IO;
using JetBrains.Annotations;

namespace Build;
Expand Down
9 changes: 0 additions & 9 deletions source/CreativeCoders.HomeMatic.Core/CcuDeviceKind.cs

This file was deleted.

30 changes: 30 additions & 0 deletions source/CreativeCoders.HomeMatic.Core/CcuDeviceUri.cs
Original file line number Diff line number Diff line change
@@ -1,20 +1,50 @@
using System.Diagnostics.CodeAnalysis;
using CreativeCoders.HomeMatic.XmlRpc;

namespace CreativeCoders.HomeMatic.Core;

/// <summary>
/// Represents a URI that uniquely identifies a device on a specific CCU.
/// </summary>
[ExcludeFromCodeCoverage]
public class CcuDeviceUri
{
/// <summary>
/// Gets the host name or IP address of the CCU.
/// </summary>
/// <value>The network host name or IP address of the CCU.</value>
public required string CcuHost { get; init; }

/// <summary>
/// Gets the logical name of the CCU.
/// </summary>
/// <value>The human-readable name of the CCU. The default is an empty string.</value>
public string CcuName { get; init; } = string.Empty;

/// <summary>
/// Gets the kind of device addressed by this URI.
/// </summary>
/// <value>One of the enumeration values that specifies the device kind.</value>
public required CcuDeviceKind Kind { get; init; }

/// <summary>
/// Gets the device address within the CCU.
/// </summary>
/// <value>The device or channel address.</value>
public required string Address { get; init; }

/// <summary>
/// Gets the preferred display name for the CCU host.
/// </summary>
/// <value>
/// The value of <see cref="CcuName"/> if it is not empty; otherwise, the value of <see cref="CcuHost"/>.
/// </value>
public string HostDisplayName => string.IsNullOrWhiteSpace(CcuName) ? CcuHost : CcuName;

/// <summary>
/// Returns a string representation of this URI in the form <c>{Kind}://{CcuHost}/{Address}</c>.
/// </summary>
/// <returns>A string representation of the device URI.</returns>
public override string ToString()
{
return $"{Kind}://{CcuHost}/{Address}";
Expand Down
34 changes: 32 additions & 2 deletions source/CreativeCoders.HomeMatic.Core/CcuLogLevel.cs
Original file line number Diff line number Diff line change
@@ -1,15 +1,45 @@
using JetBrains.Annotations;
using JetBrains.Annotations;

namespace CreativeCoders.HomeMatic.Core;

/// <summary>
/// Specifies the severity of log entries produced by the CCU.
/// </summary>
[PublicAPI]
public enum CcuLogLevel
{
/// <summary>
/// All log entries are included.
/// </summary>
All = 0,

/// <summary>
/// Detailed diagnostic messages used for debugging.
/// </summary>
Debug = 1,

/// <summary>
/// Informational messages that describe normal operation.
/// </summary>
Info = 2,

/// <summary>
/// Notable events that do not indicate a problem.
/// </summary>
Notice = 3,

/// <summary>
/// Conditions that may indicate a potential problem.
/// </summary>
Warning = 4,

/// <summary>
/// Errors that affect the current operation.
/// </summary>
Error = 5,

/// <summary>
/// Fatal errors that prevent further operation.
/// </summary>
FatalError = 6
}
}
40 changes: 0 additions & 40 deletions source/CreativeCoders.HomeMatic.Core/CcuRpcPorts.cs

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,8 @@
<PackageReference Include="Microsoft.Extensions.DependencyInjection.Abstractions" />
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\CreativeCoders.HomeMatic.XmlRpc\CreativeCoders.HomeMatic.XmlRpc.csproj" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
@@ -1,29 +1,76 @@
using System.Collections.Generic;
using CreativeCoders.HomeMatic.Core.Parameters;
using CreativeCoders.HomeMatic.XmlRpc.Parameters;

namespace CreativeCoders.HomeMatic.Core.Devices;

/// <summary>
/// Describes the metadata of a single HomeMatic parameter as reported by the CCU.
/// </summary>
public class CcuParameterDescription
{
/// <summary>
/// Gets the identifier of the parameter.
/// </summary>
/// <value>The parameter identifier, or <see langword="null"/> if not provided.</value>
public required string? Id { get; init; }

/// <summary>
/// Gets the default value of the parameter.
/// </summary>
/// <value>The default value, or <see langword="null"/> if not provided.</value>
public required object? DefaultValue { get; init; }

/// <summary>
/// Gets the minimum value allowed for the parameter.
/// </summary>
/// <value>The minimum value, or <see langword="null"/> if not provided.</value>
public required object? MinValue { get; init; }

/// <summary>
/// Gets the maximum value allowed for the parameter.
/// </summary>
/// <value>The maximum value, or <see langword="null"/> if not provided.</value>
public required object? MaxValue { get; init; }

/// <summary>
/// Gets the raw type string as reported by the CCU.
/// </summary>
/// <value>The type string, or <see langword="null"/> if not provided.</value>
public required string? Type { get; init; }

/// <summary>
/// Gets the strongly-typed data type of the parameter.
/// </summary>
/// <value>One of the enumeration values that specifies the data type.</value>
public required ParameterDataType DataType { get; init; }

/// <summary>
/// Gets the unit string of the parameter value.
/// </summary>
/// <value>The unit string, or <see langword="null"/> if not provided.</value>
public required string? Unit { get; init; }

/// <summary>
/// Gets the tab order used when displaying the parameter in the CCU UI.
/// </summary>
/// <value>The tab-order index.</value>
public required int TabOrder { get; init; }

/// <summary>
/// Gets the control hint used for the parameter in the CCU UI.
/// </summary>
/// <value>The control hint string, or <see langword="null"/> if not provided.</value>
public required string? Control { get; init; }

/// <summary>
/// Gets the list of allowed enum value names when the parameter is of enum type.
/// </summary>
/// <value>The enumerable of enum value names.</value>
public required IEnumerable<string> ValuesList { get; init; } = [];

/// <summary>
/// Gets the special values associated with the parameter (for example, error or invalid markers).
/// </summary>
/// <value>The enumerable of special-value dictionaries keyed by name.</value>
public required IEnumerable<Dictionary<string, object>> SpecialValues { get; init; } = [];
}
11 changes: 0 additions & 11 deletions source/CreativeCoders.HomeMatic.Core/Devices/ChannelDirection.cs

This file was deleted.

This file was deleted.

7 changes: 7 additions & 0 deletions source/CreativeCoders.HomeMatic.Core/Devices/ICcuDevice.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,14 @@

namespace CreativeCoders.HomeMatic.Core.Devices;

/// <summary>
/// Represents a HomeMatic device including its channels and runtime state.
/// </summary>
public interface ICcuDevice : ICcuDeviceBase, ICcuDeviceData
{
/// <summary>
/// Gets the channels that belong to this device.
/// </summary>
/// <value>The enumerable of <see cref="ICcuDeviceChannel"/> instances.</value>
IEnumerable<ICcuDeviceChannel> Channels { get; }
}
Loading
Loading