Class
FieldOptionCollection<T>

Base collection for managing options in choice fields; add, remove, index, and enumerate items.

Definition

Namespace:Telerik.Windows.Documents.Fixed.Model.InteractiveForms

Assembly:Telerik.Windows.Documents.Fixed.dll

Type Parameters:

T

The type of field option that extends FieldOptionBase.

Syntax:

cs-api-definition
public class FieldOptionCollection<T> : IEnumerable<T>, IEnumerable where T : FieldOptionBase

Inheritance: objectFieldOptionCollection<T>

Derived Classes: ChoiceOptionCollectionRadioOptionCollection

Implements: IEnumerableIEnumerable<T>

Properties

Count

The total number of options in the collection.

Declaration

cs-api-definition
public int Count { get; }

Property Value

int

The number of options in the collection.

this[int]

Get or set the option at the specified index.

Declaration

cs-api-definition
public T this[int index] { get; set; }

Parameters

index

int

The zero-based index of the option to get or set.

Property Value

T

The field option at the specified index.

Exceptions

ArgumentOutOfRangeException

Thrown when the index is outside the bounds of the collection.

ArgumentNullException

Thrown when attempting to set a null value.

Methods

Add(T)

Add an option to the end of the collection.

Declaration

cs-api-definition
public void Add(T option)

Parameters

option

T

The option.

Clear()

Remove all options from the collection.

Declaration

cs-api-definition
public void Clear()

GetEnumerator()

Return an enumerator that iterates through the options.

Declaration

cs-api-definition
public IEnumerator<T> GetEnumerator()

Returns

IEnumerator<T>

The options.

Implements IEnumerable<T>.GetEnumerator()

RemoveAt(int)

Remove the option at the specified index.

Declaration

cs-api-definition
public void RemoveAt(int index)

Parameters

index

int

The option index.