Skip to content
ConsoleMonster
Class

DateSelectionOptions

ConsoleMonster.Interactive

Namespace
ConsoleMonster.Interactive
Assembly
ConsoleMonster
Modifiers
sealed

Shared calendar data, civil-date bounds and culture for pickers and date questions.

Inheritance

  • object
  • DateSelectionOptions

Usage

Explore 40 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Accepted by parameters 24

Constructors

public DateSelectionOptions() #

Methods

public DatePicker CreatePicker(string key, bool range = false, object? value = null) #

Creates a persistent control over this shared configuration.

Parameters

key string required
range bool = false optional
value object? = null optional

Returns

DatePicker

Properties

public DateTime? Minimum { get; set; } #

Earliest permitted date.

public DateTime? Maximum { get; set; } #

Latest permitted date.

public Func<DateTime, bool>? Unavailable { get; set; } #

Rejects individual dates, including dates inside a range.

public CultureInfo? Culture { get; set; } #

Display and line-entry culture.

public DayOfWeek? FirstDayOfWeek { get; set; } #

First weekday; null follows Culture.

public DateTime Today { get; set; } #

Injectable civil date for today and the initial cursor.

public CalendarData Data { get; set; } #

Grouped status marks and labels.

Extension Methods

public static DateSelectionOptions Configure(DateSelectionOptions dateSelectionOptions, Action<DateSelectionOptions> configure) #

Assigns callbacks and related configuration without invoking delegate-valued properties.

Parameters

dateSelectionOptions ConsoleMonster.Interactive.DateSelectionOptions required
The instance.
configure System.Action<ConsoleMonster.Interactive.DateSelectionOptions> required
Assignments applied in order.

Returns

DateSelectionOptions The same instance.

Examples

// C# initializer or property                                                           // C# fluent
new global::ConsoleMonster.Interactive.DateSelectionOptions { Unavailable = value };    Ui.Options<global::ConsoleMonster.Interactive.DateSelectionOptions>().Configure(configured => configured.Unavailable = value);
public static DateSelectionOptions Culture(DateSelectionOptions dateSelectionOptions, CultureInfo? value) #

Sets DateSelectionOptions.Culture: Display and line-entry culture.

Parameters

dateSelectionOptions ConsoleMonster.Interactive.DateSelectionOptions required
The instance.
value System.Globalization.CultureInfo? required
The value.

Returns

DateSelectionOptions The same instance.

Examples

// C# initializer or property                                                       // C# fluent
new global::ConsoleMonster.Interactive.DateSelectionOptions { Culture = value };    Ui.Options<global::ConsoleMonster.Interactive.DateSelectionOptions>().Culture(value);
public static DateSelectionOptions Data(DateSelectionOptions dateSelectionOptions, CalendarData value) #

Sets DateSelectionOptions.Data: Grouped status marks and labels.

Parameters

dateSelectionOptions ConsoleMonster.Interactive.DateSelectionOptions required
The instance.
value ConsoleMonster.Dates.CalendarData required
The value.

Returns

DateSelectionOptions The same instance.

Examples

// C# initializer or property                                                    // C# fluent
new global::ConsoleMonster.Interactive.DateSelectionOptions { Data = value };    Ui.Options<global::ConsoleMonster.Interactive.DateSelectionOptions>().Data(value);
public static DateSelectionOptions FirstDayOfWeek(DateSelectionOptions dateSelectionOptions, DayOfWeek? value) #

Sets DateSelectionOptions.FirstDayOfWeek: First weekday; null follows Culture.

Parameters

dateSelectionOptions ConsoleMonster.Interactive.DateSelectionOptions required
The instance.
value System.DayOfWeek? required
The value.

Returns

DateSelectionOptions The same instance.

Examples

// C# initializer or property                                                              // C# fluent
new global::ConsoleMonster.Interactive.DateSelectionOptions { FirstDayOfWeek = value };    Ui.Options<global::ConsoleMonster.Interactive.DateSelectionOptions>().FirstDayOfWeek(value);
public static DateSelectionOptions Maximum(DateSelectionOptions dateSelectionOptions, DateTime? value) #

Sets DateSelectionOptions.Maximum: Latest permitted date.

Parameters

dateSelectionOptions ConsoleMonster.Interactive.DateSelectionOptions required
The instance.
value System.DateTime? required
The value.

Returns

DateSelectionOptions The same instance.

Examples

// C# initializer or property                                                       // C# fluent
new global::ConsoleMonster.Interactive.DateSelectionOptions { Maximum = value };    Ui.Options<global::ConsoleMonster.Interactive.DateSelectionOptions>().Maximum(value);
public static DateSelectionOptions Minimum(DateSelectionOptions dateSelectionOptions, DateTime? value) #

Sets DateSelectionOptions.Minimum: Earliest permitted date.

Parameters

dateSelectionOptions ConsoleMonster.Interactive.DateSelectionOptions required
The instance.
value System.DateTime? required
The value.

Returns

DateSelectionOptions The same instance.

Examples

// C# initializer or property                                                       // C# fluent
new global::ConsoleMonster.Interactive.DateSelectionOptions { Minimum = value };    Ui.Options<global::ConsoleMonster.Interactive.DateSelectionOptions>().Minimum(value);
public static DateSelectionOptions Today(DateSelectionOptions dateSelectionOptions, DateTime value) #

Sets DateSelectionOptions.Today: Injectable civil date for today and the initial cursor.

Parameters

dateSelectionOptions ConsoleMonster.Interactive.DateSelectionOptions required
The instance.
value System.DateTime required
The value.

Returns

DateSelectionOptions The same instance.

Examples

// C# initializer or property                                                     // C# fluent
new global::ConsoleMonster.Interactive.DateSelectionOptions { Today = value };    Ui.Options<global::ConsoleMonster.Interactive.DateSelectionOptions>().Today(value);