BusinessMgr

This commit is contained in:
Andy Howard
2025-01-16 13:20:10 +00:00
parent 79436b1a60
commit dea70843c5
2 changed files with 10 additions and 3 deletions
+1 -1
View File
@@ -10,7 +10,7 @@ namespace Sarand.Net.Standard.Base.Core
//-------------------------------------------------------------------
// Data members.
//-------------------------------------------------------------------
public CodeDesc (String code, String desc, String comment = "")
public CodeDesc(String code, String desc, String comment = "")
{
Code = StringUtil.EmptyOnNull(code);
Desc = StringUtil.EmptyOnNull(desc);
+9 -2
View File
@@ -9,14 +9,21 @@ namespace Sarand.Net.Standard.Base.Core
{
//-------------------------------------------------------------------
// Construction.
public TypeCodeDesc (int type, String code, String desc, String comment = "") :
public TypeCodeDesc(int type, String code, String desc, String comment = "") :
base(code, desc, comment)
{
Type = type;
}
//-------------------------------------------------------------------
/// <summary>Generic initialisation, ie. with type as enum.</summary>
public static TypeCodeDesc Create<T>(T type, String code, string desc, string comment = "") where T : struct, IConvertible
{
return new TypeCodeDesc((int)(type as IConvertible), code, desc, comment);
}
// Properties.
public int Type { get; }
//-------------------------------------------------------------------
}