Table of Contents

Class SnowflakeSelectComponentBuilder<TInfo, TBuilder>

Namespace
Discord.Interactions.Builders
Assembly
Discord.Net.Interactions.dll

Represents a builder for creating SnowflakeSelectComponentInfo.

public abstract class SnowflakeSelectComponentBuilder<TInfo, TBuilder> : InputComponentBuilder<TInfo, TBuilder>, ISnowflakeSelectComponentBuilder, IInputComponentBuilder, IModalComponentBuilder where TInfo : InputComponentInfo where TBuilder : InputComponentBuilder<TInfo, TBuilder>, ISnowflakeSelectComponentBuilder

Type Parameters

TInfo

The SnowflakeSelectComponentInfo this builder yields when built.

TBuilder

Inherited SnowflakeSelectComponentBuilder<TInfo, TBuilder> type.

Inheritance
ModalComponentBuilder<TInfo, TBuilder>
InputComponentBuilder<TInfo, TBuilder>
SnowflakeSelectComponentBuilder<TInfo, TBuilder>
Implements
Derived
Inherited Members

Constructors

SnowflakeSelectComponentBuilder(ModalBuilder, ComponentType)

public SnowflakeSelectComponentBuilder(ModalBuilder modal, ComponentType componentType)

Parameters

modal ModalBuilder

Parent modal of this input component.

componentType ComponentType

Type of this component.

Fields

_defaultValues

protected readonly List<SelectMenuDefaultValue> _defaultValues

Field Value

List<SelectMenuDefaultValue>

Properties

DefaultValues

Gets the default value collection for this select component.

public IReadOnlyCollection<SelectMenuDefaultValue> DefaultValues { get; }

Property Value

IReadOnlyCollection<SelectMenuDefaultValue>

DefaultValuesType

Gets the default value type of this select component.

public SelectDefaultValueType? DefaultValuesType { get; }

Property Value

SelectDefaultValueType?

MaxValues

Gets the maximum number of values that can be selected.

public int MaxValues { get; set; }

Property Value

int

MinValues

Gets the minimum number of values that can be selected.

public int MinValues { get; set; }

Property Value

int

Placeholder

Gets the placeholder text for this select component.

public string Placeholder { get; set; }

Property Value

string

Methods

AddDefaultValue(SelectMenuDefaultValue)

public TBuilder AddDefaultValue(SelectMenuDefaultValue defaultValue)

Parameters

defaultValue SelectMenuDefaultValue

Returns

TBuilder

WithComponentType(ComponentType)

public override TBuilder WithComponentType(ComponentType componentType)

Parameters

componentType ComponentType

New value of the ComponentType.

Returns

TBuilder

The builder instance.

WithMaxValues(int)

public TBuilder WithMaxValues(int maxValues)

Parameters

maxValues int

Returns

TBuilder

WithMinValues(int)

public TBuilder WithMinValues(int minValues)

Parameters

minValues int

Returns

TBuilder

WithPlaceholder(string)

public TBuilder WithPlaceholder(string placeholder)

Parameters

placeholder string

Returns

TBuilder