ReSharper on CommonCore project

This commit is contained in:
Thomas Wiedebusch
2022-08-24 11:42:44 +02:00
parent a16ce66dbe
commit fbfb914268
7 changed files with 53 additions and 58 deletions
@@ -1,37 +1,36 @@
using System;
using System.Collections.Generic;
using System.Text;
namespace Xylem.Common.CommonCore.Exceptions.WaterMeter
{
public class LvlNotSupportedException : Exception, ICommonException
{
Guid? LCode = null;
public LvlNotSupportedException(Guid? Location = null)
Guid? _lCode;
public LvlNotSupportedException(Guid? location = null)
{
LCode = Location;
_lCode = location;
}
public LvlNotSupportedException(string message, Guid? Location = null)
public LvlNotSupportedException(String message, Guid? location = null)
: base(message)
{
LCode = Location;
_lCode = location;
}
public LvlNotSupportedException(string message, Exception inner, Guid? Location = null)
public LvlNotSupportedException(String message, Exception inner, Guid? location = null)
: base(message, inner)
{
LCode = Location;
_lCode = location;
}
public string GetHelpText()
public String GetHelpText()
{
var sb = new StringBuilder();
sb.AppendLine($"You can not login at this lvl if the meter is locked.");
sb.AppendLine($"Try to use an other level or unlock the meter.");
if (LCode.HasValue)
sb.AppendLine("You can not login at this lvl if the meter is locked.");
sb.AppendLine("Try to use an other level or unlock the meter.");
if (_lCode.HasValue)
{
sb.AppendLine($"LCode:{LCode.Value}");
sb.AppendLine($"LCode:{_lCode.Value}");
}
return sb.ToString();
}