Saxonite v1.2.8

This commit is contained in:
2022-07-16 13:33:22 +01:00
parent d523628d7f
commit 0cab7c6a9d
+6
View File
@@ -48,6 +48,7 @@ namespace Sarand.Net.Standard.Base.Bus
//-------------------------------------------------------------------
// Utilities.
/// <summary>Verify that the Item Id is non-null and that the Item Type is specified (>0) and the Id is valid (>0).</summary>
public static bool IsValid(ItemId itemId)
{
if (itemId == null) return false;
@@ -56,6 +57,11 @@ namespace Sarand.Net.Standard.Base.Bus
if (itemId.idType == ItemIdType.String && StringUtil.IsEmpty(itemId.StringId)) return false;
return true;
}
/// <summary>Return the Item Id if non-=null, otherwise empty Item Id.</summary>
public static ItemId InvalidOnNull (ItemId itemId)
{
return itemId ?? new ItemId();
}
//-------------------------------------------------------------------
// Comparison.