Class StringSettingDescriptor
Descriptor for a free-text string setting. Supports min/max length and optional regex validation.
Inherited Members
Namespace: Zaya.Primitives
Assembly: Zaya.Primitives.dll
Syntax
public sealed class StringSettingDescriptor : SettingDescriptor
Constructors
| Edit this page View SourceStringSettingDescriptor(string, LocalizedString)
Initializes a new instance of the StringSettingDescriptor class.
Declaration
public StringSettingDescriptor(string key, LocalizedString displayName)
Parameters
| Type | Name | Description |
|---|---|---|
| string | key | Machine-readable key for this setting. |
| LocalizedString | displayName | Localizable UI label. |
Properties
| Edit this page View SourceDefaultValue
Gets or sets the default text value.
Declaration
public string? DefaultValue { get; init; }
Property Value
| Type | Description |
|---|---|
| string |
MaxLength
Gets or sets the maximum allowed string length (inclusive).
Declaration
public int? MaxLength { get; init; }
Property Value
| Type | Description |
|---|---|
| int? |
MinLength
Gets or sets the minimum allowed string length (inclusive).
Declaration
public int? MinLength { get; init; }
Property Value
| Type | Description |
|---|---|
| int? |
RegexPattern
Gets or sets an optional regex pattern for validation.
Declaration
public string? RegexPattern { get; init; }
Property Value
| Type | Description |
|---|---|
| string |