//\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
// UserRTX.NET satellite library | Author: Sergei Y.Kitáev
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
using System;

#if !WASM
namespace user_rtx { using u = user_rtx;
#else
namespace user_rtx.wasm { using u = user_rtx.wasm;
#endif

/// <summary>
/// String argument checking errors (exception creation)
/// </summary>
public static class str_argcheck_errors {
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
public static string PN( string? paramName ) => paramName ?? "value";
//==================================================================================================

public static ArgumentException NONEMPTY_STRING_WAS_EXPECTED( string? paramName ) =>
   new ArgumentException(
      "Non-empty string was expected.",
      PN(paramName) );

public static ArgumentException NONWS_STRING_WAS_EXPECTED( string? paramName ) =>
   new ArgumentException(
      "Non-whitespace string was expected.",
      PN(paramName) );

//--------------------------------------------------------------------------------------------------

public static ArgumentException LIST_OF_NONEMPTY_STRINGS_WAS_EXPECTED( string? paramName ) =>
   new ArgumentException(
      "List of non-empty strings was expected.",
      PN(paramName) );

public static ArgumentException LIST_OF_NONWS_STRINGS_WAS_EXPECTED( string? paramName ) =>
   new ArgumentException(
      "List of non-whitespace strings was expected.",
      PN(paramName) );

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
} // str_argcheck_errors

} // user_rtx (.wasm)
