Class Arguments
Functions for parameter validation.
Inspiration from InfluxDB java - thanks
Inheritance
System.Object
Arguments
Namespace: InfluxDB.Client.Core
Assembly: InfluxDB.Client.Core.dll
Syntax
public static class Arguments : object
Methods
CheckDuration(String, String)
Enforces that the string is duration literal.
Declaration
public static void CheckDuration(string value, string name)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | the string to test |
System.String | name | the variable name for reporting |
CheckNonEmptyString(String, String)
Enforces that the string is not empty.
Declaration
public static void CheckNonEmptyString(string value, string name)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | the string to test |
System.String | name | the variable name for reporting |
CheckNotNegativeNumber(Int32, String)
Enforces that the number is not negative.
Declaration
public static void CheckNotNegativeNumber(int number, string name)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | number | the number to test |
System.String | name | the variable name for reporting |
CheckNotNull(Object, String)
Checks that the specified object reference is not null.
Declaration
public static void CheckNotNull(object obj, string name)
Parameters
Type | Name | Description |
---|---|---|
System.Object | obj | the object to test |
System.String | name | the variable name for reporting |
CheckPositiveNumber(Int32, String)
Enforces that the number is larger than 0.
Declaration
public static void CheckPositiveNumber(int number, string name)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | number | the number to test |
System.String | name | the variable name for reporting |