forked from amkovkov/GranuSightSoftware2
refactor: hardware services
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
namespace GSS2.Core.Abstractions;
|
||||
|
||||
public abstract record ServiceConfigurationBase
|
||||
{
|
||||
public virtual string ToString(string separator, int indent)
|
||||
{
|
||||
List<string?> strs = new List<string?>();
|
||||
foreach (var prop in GetType().GetProperties())
|
||||
strs.Add($"{prop.Name}: {prop.GetValue(this)}");
|
||||
return string.Join(separator, strs.Select(s => $"{new string(' ', indent)}{s}"));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user