Table of Contents

Method ThrowIfNullOrWhiteSpace

Namespace
Gamelogic.Extensions
Assembly
Gamelogic.Extensions.dll

ThrowIfNullOrWhiteSpace(string, string)

Throws an ArgumentNullException if the string is null, empty, or whitespace.

public static string ThrowIfNullOrWhiteSpace(this string obj, string objArgName = null)

Parameters

obj string

The string to check.

objArgName string

The name of the argument.

Returns

string

The original string if it is not null, empty, or whitespace.

Exceptions

ArgumentNullException

obj is null, empty, or whitespace.