#### [DiGi\.Core\.Parameter](DiGi.Core.Parameter.Overview.md 'DiGi\.Core\.Parameter\.Overview')
## DiGi\.Core\.Parameter Namespace
### Classes
## Create Class
Provides factory methods for creating parameter\-related objects\.
```csharp
public static class Create
```
Inheritance [System\.Object](https://learn.microsoft.com/en-us/dotnet/api/system.object 'System\.Object') → Create
### Methods
## Create\.ExternalParameterDefinition\(Guid, string, string, ParameterType, Type, AccessType, bool, string\) Method
Creates a new external parameter definition with the specified properties\.
```csharp
public static DiGi.Core.Parameter.Classes.ExternalParameterDefinition? ExternalParameterDefinition(System.Guid guid, string? name, string? description, DiGi.Core.Parameter.Enums.ParameterType parameterType, System.Type? type, DiGi.Core.Parameter.Enums.AccessType accessType=DiGi.Core.Parameter.Enums.AccessType.ReadWrite, bool nullable=true, string? groupName=null);
```
#### Parameters
`guid` [System\.Guid](https://learn.microsoft.com/en-us/dotnet/api/system.guid 'System\.Guid')
The unique identifier for the parameter\.
`name` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')
The name of the parameter\.
`description` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')
A description of the parameter\.
`parameterType` [ParameterType](DiGi.Core.Parameter.Enums.md#DiGi.Core.Parameter.Enums.ParameterType 'DiGi\.Core\.Parameter\.Enums\.ParameterType')
The type category of the parameter\.
`type` [System\.Type](https://learn.microsoft.com/en-us/dotnet/api/system.type 'System\.Type')
The underlying system type of the parameter\.
`accessType` [AccessType](DiGi.Core.Parameter.Enums.md#DiGi.Core.Parameter.Enums.AccessType 'DiGi\.Core\.Parameter\.Enums\.AccessType')
The access level of the parameter\.
`nullable` [System\.Boolean](https://learn.microsoft.com/en-us/dotnet/api/system.boolean 'System\.Boolean')
Whether the parameter can be null\.
`groupName` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')
The name of the group this parameter belongs to\.
#### Returns
[ExternalParameterDefinition](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.ExternalParameterDefinition 'DiGi\.Core\.Parameter\.Classes\.ExternalParameterDefinition')
A new instance of [ExternalParameterDefinition](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.ExternalParameterDefinition 'DiGi\.Core\.Parameter\.Classes\.ExternalParameterDefinition'), or null if creation fails\.
## Create\.ExternalParameterDefinition\(Guid, string, string, double, double, Type, AccessType, bool, string\) Method
Creates a new external parameter definition with specified range constraints\.
```csharp
public static DiGi.Core.Parameter.Classes.ExternalParameterDefinition? ExternalParameterDefinition(System.Guid guid, string? name, string? description, double min, double max, System.Type? type, DiGi.Core.Parameter.Enums.AccessType accessType=DiGi.Core.Parameter.Enums.AccessType.ReadWrite, bool nullable=true, string? groupName=null);
```
#### Parameters
`guid` [System\.Guid](https://learn.microsoft.com/en-us/dotnet/api/system.guid 'System\.Guid')
The unique identifier for the parameter\.
`name` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')
The name of the parameter\.
`description` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')
A description of the parameter\.
`min` [System\.Double](https://learn.microsoft.com/en-us/dotnet/api/system.double 'System\.Double')
The minimum value constraint\.
`max` [System\.Double](https://learn.microsoft.com/en-us/dotnet/api/system.double 'System\.Double')
The maximum value constraint\.
`type` [System\.Type](https://learn.microsoft.com/en-us/dotnet/api/system.type 'System\.Type')
The type of the parameter\.
`accessType` [AccessType](DiGi.Core.Parameter.Enums.md#DiGi.Core.Parameter.Enums.AccessType 'DiGi\.Core\.Parameter\.Enums\.AccessType')
The access level of the parameter\.
`nullable` [System\.Boolean](https://learn.microsoft.com/en-us/dotnet/api/system.boolean 'System\.Boolean')
Whether the parameter can be null\.
`groupName` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')
The name of the group this parameter belongs to\.
#### Returns
[ExternalParameterDefinition](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.ExternalParameterDefinition 'DiGi\.Core\.Parameter\.Classes\.ExternalParameterDefinition')
A new instance of [ExternalParameterDefinition](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.ExternalParameterDefinition 'DiGi\.Core\.Parameter\.Classes\.ExternalParameterDefinition'), or null if creation fails\.
## Create\.JsonArray\(this IEnumerable\\) Method
Converts a collection of types to a JsonArray\.
```csharp
public static System.Text.Json.Nodes.JsonArray? JsonArray(this System.Collections.Generic.IEnumerable? types);
```
#### Parameters
`types` [System\.Collections\.Generic\.IEnumerable<](https://learn.microsoft.com/en-us/dotnet/api/system.collections.generic.ienumerable-1 'System\.Collections\.Generic\.IEnumerable\`1')[System\.Type](https://learn.microsoft.com/en-us/dotnet/api/system.type 'System\.Type')[>](https://learn.microsoft.com/en-us/dotnet/api/system.collections.generic.ienumerable-1 'System\.Collections\.Generic\.IEnumerable\`1')
The collection of types to convert\.
#### Returns
[System\.Text\.Json\.Nodes\.JsonArray](https://learn.microsoft.com/en-us/dotnet/api/system.text.json.nodes.jsonarray 'System\.Text\.Json\.Nodes\.JsonArray')
A JsonArray containing the full type names, or null if the input is null\.
## Create\.Parameter\(string, object\) Method
Creates a parameter using a specified name and value\.
```csharp
public static DiGi.Core.Parameter.Classes.Parameter? Parameter(string? name, object? value);
```
#### Parameters
`name` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')
The name of the parameter\.
`value` [System\.Object](https://learn.microsoft.com/en-us/dotnet/api/system.object 'System\.Object')
The value to assign to the parameter\.
#### Returns
[Parameter](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.Parameter 'DiGi\.Core\.Parameter\.Classes\.Parameter')
A [Parameter](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.Parameter 'DiGi\.Core\.Parameter\.Classes\.Parameter') instance, or null\.
## Create\.Parameter\(this IParameterDefinition, object, SetValueSettings\) Method
Creates a parameter based on the provided definition and value\.
```csharp
public static DiGi.Core.Parameter.Classes.Parameter? Parameter(this DiGi.Core.Parameter.Interfaces.IParameterDefinition? parameterDefinition, object? value, DiGi.Core.Parameter.Classes.SetValueSettings? setValueSettings=null);
```
#### Parameters
`parameterDefinition` [IParameterDefinition](DiGi.Core.Parameter.Interfaces.md#DiGi.Core.Parameter.Interfaces.IParameterDefinition 'DiGi\.Core\.Parameter\.Interfaces\.IParameterDefinition')
The definition of the parameter\.
`value` [System\.Object](https://learn.microsoft.com/en-us/dotnet/api/system.object 'System\.Object')
The value to assign to the parameter\.
`setValueSettings` [SetValueSettings](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.SetValueSettings 'DiGi\.Core\.Parameter\.Classes\.SetValueSettings')
Optional settings for setting the value\.
#### Returns
[Parameter](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.Parameter 'DiGi\.Core\.Parameter\.Classes\.Parameter')
A [Parameter](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.Parameter 'DiGi\.Core\.Parameter\.Classes\.Parameter') instance, or null\.
## Create\.Types\(this JsonArray\) Method
Converts a JsonArray to a list of types\.
```csharp
public static System.Collections.Generic.List? Types(this System.Text.Json.Nodes.JsonArray? jsonArray);
```
#### Parameters
`jsonArray` [System\.Text\.Json\.Nodes\.JsonArray](https://learn.microsoft.com/en-us/dotnet/api/system.text.json.nodes.jsonarray 'System\.Text\.Json\.Nodes\.JsonArray')
The JsonArray to convert\.
#### Returns
[System\.Collections\.Generic\.List<](https://learn.microsoft.com/en-us/dotnet/api/system.collections.generic.list-1 'System\.Collections\.Generic\.List\`1')[System\.Type](https://learn.microsoft.com/en-us/dotnet/api/system.type 'System\.Type')[>](https://learn.microsoft.com/en-us/dotnet/api/system.collections.generic.list-1 'System\.Collections\.Generic\.List\`1')
A list of types, or null if the input is null\.
## Query Class
```csharp
public static class Query
```
Inheritance [System\.Object](https://learn.microsoft.com/en-us/dotnet/api/system.object 'System\.Object') → Query
### Methods
## Query\.AssociatedTypes\(Type\) Method
Retrieves the associated types for the specified type\.
```csharp
public static DiGi.Core.Parameter.Classes.AssociatedTypes? AssociatedTypes(System.Type? type);
```
#### Parameters
`type` [System\.Type](https://learn.microsoft.com/en-us/dotnet/api/system.type 'System\.Type')
The type for which to retrieve associated types\.
#### Returns
[AssociatedTypes](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.AssociatedTypes 'DiGi\.Core\.Parameter\.Classes\.AssociatedTypes')
The associated types for the specified type, or null if none are found\.
## Query\.Description\(this Enum\) Method
Gets the description of the specified enumeration value\.
```csharp
public static string? Description(this System.Enum? @enum);
```
#### Parameters
`enum` [System\.Enum](https://learn.microsoft.com/en-us/dotnet/api/system.enum 'System\.Enum')
The enumeration value for which to get the description\.
#### Returns
[System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')
The description of the specified enumeration value, or null if no description is found\.
## Query\.Description\(this Type\) Method
Gets the description of the specified type\.
```csharp
public static string? Description(this System.Type? type);
```
#### Parameters
`type` [System\.Type](https://learn.microsoft.com/en-us/dotnet/api/system.type 'System\.Type')
The type for which to get the description\.
#### Returns
[System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')
The description of the specified type, or null if no description is found\.
## Query\.IsValid\(this ParameterType, object\) Method
Validates whether the provided value is valid for the given parameter type\.
```csharp
public static bool IsValid(this DiGi.Core.Parameter.Enums.ParameterType parameterType, object? value);
```
#### Parameters
`parameterType` [ParameterType](DiGi.Core.Parameter.Enums.md#DiGi.Core.Parameter.Enums.ParameterType 'DiGi\.Core\.Parameter\.Enums\.ParameterType')
The parameter type to validate against\.
`value` [System\.Object](https://learn.microsoft.com/en-us/dotnet/api/system.object 'System\.Object')
The value to be validated\.
#### Returns
[System\.Boolean](https://learn.microsoft.com/en-us/dotnet/api/system.boolean 'System\.Boolean')
True if the value is valid for the specified parameter type; otherwise, false\.
## Query\.ParameterProperties\(Enum\) Method
Retrieves the properties associated with the specified enumeration value\.
```csharp
public static DiGi.Core.Parameter.Classes.ParameterProperties? ParameterProperties(System.Enum? @enum);
```
#### Parameters
`enum` [System\.Enum](https://learn.microsoft.com/en-us/dotnet/api/system.enum 'System\.Enum')
The enumeration value to retrieve properties for\.
#### Returns
[ParameterProperties](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.ParameterProperties 'DiGi\.Core\.Parameter\.Classes\.ParameterProperties')
The [ParameterProperties](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.ParameterProperties 'DiGi\.Core\.Parameter\.Classes\.ParameterProperties') associated with the specified enumeration, or `null` if not found\.
## Query\.ParameterProperties\(Type, string\) Method
Retrieves the properties associated with the specified type and identifier\.
```csharp
public static DiGi.Core.Parameter.Classes.ParameterProperties? ParameterProperties(System.Type? type, string? text);
```
#### Parameters
`type` [System\.Type](https://learn.microsoft.com/en-us/dotnet/api/system.type 'System\.Type')
The type to retrieve properties for\.
`text` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')
The identifier text used to look up the properties\.
#### Returns
[ParameterProperties](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.ParameterProperties 'DiGi\.Core\.Parameter\.Classes\.ParameterProperties')
The [ParameterProperties](DiGi.Core.Parameter.Classes.md#DiGi.Core.Parameter.Classes.ParameterProperties 'DiGi\.Core\.Parameter\.Classes\.ParameterProperties') associated with the specified type and text, or `null` if not found\.
## Query\.ParameterType\(Enum\) Method
Gets the parameter type for the specified enumeration value\.
```csharp
public static DiGi.Core.Parameter.Enums.ParameterType ParameterType(System.Enum? @enum);
```
#### Parameters
`enum` [System\.Enum](https://learn.microsoft.com/en-us/dotnet/api/system.enum 'System\.Enum')
The enumeration value\.
#### Returns
[ParameterType](DiGi.Core.Parameter.Enums.md#DiGi.Core.Parameter.Enums.ParameterType 'DiGi\.Core\.Parameter\.Enums\.ParameterType')
The corresponding [ParameterType](DiGi.Core.Parameter.Enums.md#DiGi.Core.Parameter.Enums.ParameterType 'DiGi\.Core\.Parameter\.Enums\.ParameterType')\.
## Query\.ParameterType\(Type, string\) Method
Gets the parameter type for the specified type and identifier\.
```csharp
public static DiGi.Core.Parameter.Enums.ParameterType ParameterType(System.Type? type, string? text);
```
#### Parameters
`type` [System\.Type](https://learn.microsoft.com/en-us/dotnet/api/system.type 'System\.Type')
The type to evaluate\.
`text` [System\.String](https://learn.microsoft.com/en-us/dotnet/api/system.string 'System\.String')
The identifier text\.
#### Returns
[ParameterType](DiGi.Core.Parameter.Enums.md#DiGi.Core.Parameter.Enums.ParameterType 'DiGi\.Core\.Parameter\.Enums\.ParameterType')
The corresponding [ParameterType](DiGi.Core.Parameter.Enums.md#DiGi.Core.Parameter.Enums.ParameterType 'DiGi\.Core\.Parameter\.Enums\.ParameterType')\.
## Query\.ParameterValue\\(Enum\) Method
Retrieves the parameter value associated with the specified enumeration\.
```csharp
public static TParameterValue? ParameterValue(System.Enum? @enum)
where TParameterValue : DiGi.Core.Parameter.Classes.ParameterValue;
```
#### Type parameters
`TParameterValue`
The type of the parameter value\.
#### Parameters
`enum` [System\.Enum](https://learn.microsoft.com/en-us/dotnet/api/system.enum 'System\.Enum')
The enumeration for which to retrieve the parameter value\.
#### Returns
[TParameterValue](DiGi.Core.Parameter.md#DiGi.Core.Parameter.Query.ParameterValue_TParameterValue_(System.Enum).TParameterValue 'DiGi\.Core\.Parameter\.Query\.ParameterValue\\(System\.Enum\)\.TParameterValue')
The parameter value associated with the specified enumeration, or null if not found\.
## Query\.Read\(this AccessType\) Method
Determines whether the specified access type allows read operations\.
```csharp
public static bool Read(this DiGi.Core.Parameter.Enums.AccessType accessType);
```
#### Parameters
`accessType` [AccessType](DiGi.Core.Parameter.Enums.md#DiGi.Core.Parameter.Enums.AccessType 'DiGi\.Core\.Parameter\.Enums\.AccessType')
The access type to check for read permissions\.
#### Returns
[System\.Boolean](https://learn.microsoft.com/en-us/dotnet/api/system.boolean 'System\.Boolean')
True if the access type allows read operations; otherwise, false\.
## Query\.Types\(Enum\) Method
Retrieves the types associated with the specified enumeration\.
```csharp
public static System.Type[]? Types(System.Enum? @enum);
```
#### Parameters
`enum` [System\.Enum](https://learn.microsoft.com/en-us/dotnet/api/system.enum 'System\.Enum')
The enumeration to retrieve types for\.
#### Returns
[System\.Type](https://learn.microsoft.com/en-us/dotnet/api/system.type 'System\.Type')[\[\]](https://learn.microsoft.com/en-us/dotnet/api/system.array 'System\.Array')
An array of [System\.Type](https://learn.microsoft.com/en-us/dotnet/api/system.type 'System\.Type') objects associated with the specified enumeration, or `null`\.
## Query\.Write\(this AccessType\) Method
Determines whether the specified access type allows write operations\.
```csharp
public static bool Write(this DiGi.Core.Parameter.Enums.AccessType accessType);
```
#### Parameters
`accessType` [AccessType](DiGi.Core.Parameter.Enums.md#DiGi.Core.Parameter.Enums.AccessType 'DiGi\.Core\.Parameter\.Enums\.AccessType')
The access type to evaluate\.
#### Returns
[System\.Boolean](https://learn.microsoft.com/en-us/dotnet/api/system.boolean 'System\.Boolean')
True if the specified access type allows write operations; otherwise, false\.