Definition
Assembly: CloudNimble.EasyAF.Core.dll Namespace: CloudNimble.EasyAF.Core Inheritance: System.ObjectSyntax
Summary
Provides methods for ensuring that method arguments meet specific criteria. This class provides a consistent way to validate arguments and throw appropriate exceptions.Examples
Methods
ArgumentNotNull
Ensures that the specified argument is not null.Syntax
Parameters
| Name | Type | Description |
|---|---|---|
argument | object | The argument to validate. |
argumentName | string | The name of the argument being validated. |
Exceptions
| Exception | Description |
|---|---|
ArgumentNullException | Thrown when argument is null. |
ArgumentNotNullOrWhiteSpace
Ensures that the specified argument is not null or whitespace.Syntax
Parameters
| Name | Type | Description |
|---|---|---|
argument | string | The argument to validate. |
argumentName | string | The name of the argument being validated. |
Exceptions
| Exception | Description |
|---|---|
ArgumentException | Thrown when argument is null or whitespace. |