New to Telerik UI for ASP.NET AJAX? Start a free 30-day trial

MediaPlayerFiles collection. Used in RadMediaPlayer playlist. For more information, please see the Playlist topic.

Definition

Namespace:Telerik.Web.UI

Assembly:Telerik.Web.UI.dll

Syntax:

C#
public class MediaPlayerFilesCollection : IList, ICollection, IList<MediaPlayerFile>, ICollection<MediaPlayerFile>, IEnumerable<MediaPlayerFile>, IEnumerable, IStateManager

Inheritance: objectMediaPlayerFilesCollection

Implements: ICollectionICollection<MediaPlayerFile>IEnumerableIEnumerable<MediaPlayerFile>IListIList<MediaPlayerFile>IStateManager...

Inherited Members object.ToString()object.Equals(object)object.Equals(object, object)object.ReferenceEquals(object, object)object.GetHashCode()object.GetType()object.MemberwiseClone()...

Constructors

Constructor for the MediaPlayerFiles collection. Used in RadMediaPlayer playlist. For more information, please see the Playlist topic.

C#
public MediaPlayerFilesCollection(RadMediaPlayer owner)
Parameters:ownerRadMediaPlayer

Owner RadMediaPlayer control

Properties

Returns the number of items in the collection

C#
public int Count { get; }

Implements: ICollection<MediaPlayerFile>.Count

Gets a value indicating whether the collection is read-only.

C#
public bool IsReadOnly { get; }

Implements: ICollection<MediaPlayerFile>.IsReadOnly

Owner RadMediaPlayer control

C#
public RadMediaPlayer Owner { get; }

Access a MediaPlayerFile in the collection by index.

C#
public MediaPlayerFile this[int index] { get; }
Parameters:indexint

The index in the collection.

Property Value:

The MediaPlayerFile at the specified position.

Methods

Adds file to the collection

C#
public void Add(MediaPlayerFile item)
Parameters:itemMediaPlayerFile

File to add

Implements: ICollection<MediaPlayerFile>.Add(MediaPlayerFile)

Clears the collection

C#
public void Clear()

Implements: ICollection<MediaPlayerFile>.Clear()

Determines of the file presents in the collection

C#
public bool Contains(MediaPlayerFile item)
Parameters:itemMediaPlayerFile

File to find

Returns:

bool

true if the file is found; otherwise false.

Implements: ICollection<MediaPlayerFile>.Contains(MediaPlayerFile)

Copies all the elements of the current one-dimensional array to the specified one-dimensional array starting at the specified destination array index.

C#
public void CopyTo(MediaPlayerFile[] array, int arrayIndex)
Parameters:arrayMediaPlayerFile[]

The one-dimensional array that is the destination of the elements copied from the current array.

arrayIndexint

Integer that represents the index in array at which copying begins.

Implements: ICollection<MediaPlayerFile>.CopyTo(MediaPlayerFile[], int)

Returns an enumerator that iterates through the collection.

C#
public IEnumerator<MediaPlayerFile> GetEnumerator()
Returns:

IEnumerator<MediaPlayerFile>

Returns an enumerator that iterates through the collection.

Implements: IEnumerable<MediaPlayerFile>.GetEnumerator()

Returns a collection of files, filtered by file type

C#
public List<MediaPlayerFile> GetFilesByType(string fileType)
Parameters:fileTypestring

File types to find

Returns:

List<MediaPlayerFile>

Collection of items with the given file type

Determines the index of a specific file in the MediaPlayerFilesCollection.

C#
public int IndexOf(MediaPlayerFile item)
Parameters:itemMediaPlayerFile

The object to locate in the MediaPlayerFilesCollection.

Returns:

int

The index of value if found in the collection; otherwise, -1.

Implements: IList<MediaPlayerFile>.IndexOf(MediaPlayerFile)

Inserts a file to the MediaPlayerFilesCollection at the specified index.

C#
public void Insert(int index, MediaPlayerFile item)
Parameters:indexint

The zero-based index at which file should be inserted.

itemMediaPlayerFile

The MediaPlayerFile to insert into the collection.

Implements: IList<MediaPlayerFile>.Insert(int, MediaPlayerFile)

Removes the first occurrence of a specific object from the collection.

C#
public bool Remove(MediaPlayerFile item)
Parameters:itemMediaPlayerFile

File to remove

Returns:

bool

true if file is successfully removed; otherwise, false.

Implements: ICollection<MediaPlayerFile>.Remove(MediaPlayerFile)

Removes the MediaPlayerFilesCollection file at the specified index.

C#
public void RemoveAt(int index)
Parameters:indexint

The zero-based index of the file to remove.

Implements: IList<MediaPlayerFile>.RemoveAt(int)