Share via


DataSourceCollection Class

Contains a collection of DataSource objects. This class cannot be inherited.

Inheritance Hierarchy

System.Object
  Microsoft.AnalysisServices.ModelComponentCollection
    Microsoft.AnalysisServices.NamedComponentCollection
      Microsoft.AnalysisServices.MajorObjectCollection
        Microsoft.AnalysisServices.DataSourceCollection

Namespace:  Microsoft.AnalysisServices
Assembly:  Microsoft.AnalysisServices (in Microsoft.AnalysisServices.dll)

Syntax

'Declaration
<GuidAttribute("DB5C187C-4810-4318-B008-6607DFAD2A97")> _
Public NotInheritable Class DataSourceCollection _
    Inherits MajorObjectCollection
'Usage
Dim instance As DataSourceCollection
[GuidAttribute("DB5C187C-4810-4318-B008-6607DFAD2A97")]
public sealed class DataSourceCollection : MajorObjectCollection
[GuidAttribute(L"DB5C187C-4810-4318-B008-6607DFAD2A97")]
public ref class DataSourceCollection sealed : public MajorObjectCollection
[<SealedAttribute>]
[<GuidAttribute("DB5C187C-4810-4318-B008-6607DFAD2A97")>]
type DataSourceCollection =  
    class 
        inherit MajorObjectCollection 
    end
public final class DataSourceCollection extends MajorObjectCollection

The DataSourceCollection type exposes the following members.

Properties

  Name Description
Public property Count Gets the number of ModelComponent objects in the ModelComponentCollection. (Inherited from ModelComponentCollection.)
Public property IsFixedSize Gets a value indicating whether the ModelComponentCollection has a fixed size. (Inherited from ModelComponentCollection.)
Public property IsReadOnly Gets a value indicating whether the ModelComponentCollection is read-only. (Inherited from ModelComponentCollection.)
Public property IsSynchronized Gets a value indicating whether access to the ModelComponentCollection is synchronized (thread-safe). (Inherited from ModelComponentCollection.)
Public property Item[Int32] Gets the DataSource at the specified index from the collection.
Public property Item[String] Gets the DataSource, with the specified identifier, from the collection.
Public property Parent Gets the IModelComponent that contains the ModelComponentCollection. (Inherited from ModelComponentCollection.)
Public property SyncRoot Gets an object that can be used to synchronize access to the ModelComponentCollection. (Inherited from ModelComponentCollection.)

Top

Methods

  Name Description
Public method Add() Creates and adds a DataSource to the end of the collection.
Public method Add(String) Creates and adds a DataSource, with the specified identifier, to the end of the collection.
Public method Add(DataSource) Adds a DataSource to the end of the collection.
Protected method Add(ModelComponent) Adds a ModelComponent to the end of the MajorObjectCollection. (Inherited from MajorObjectCollection.)
Public method Add(String, String) Creates and adds a DataSource, with the specified name and identifier, to the end of the collection.
Protected method Add(ModelComponent, Boolean) Infrastructure. Adds a ModelComponent object to the ModelComponentCollection. (Inherited from ModelComponentCollection.)
Public method AddNew(String) Creates and adds a DataSource, with the specified key, to the end of the collection.
Public method AddNew(String, String) Creates and adds a DataSource, with the specified name and key, to the end of the collection.
Public method CanAdd Infrastructure. Indicates whether the collection can add a ModelComponent. (Inherited from NamedComponentCollection.)
Protected method ChangeKey Infrastructure. Changes the specified keys to the collection. (Inherited from ModelComponentCollection.)
Public method Clear Removes all elements from the ModelComponentCollection. (Inherited from ModelComponentCollection.)
Public method Contains(String) Indicates whether the collection contains a DataSource, with the specified identifier.
Public method Contains(DataSource) Indicates whether the collection contains a specified DataSource.
Public method ContainsName Indicates whether the component contains its name. (Inherited from NamedComponentCollection.)
Public method CopyTo Copies the entire ModelComponentCollection to a one-dimensional Array, starting at the specified index of the target array. (Inherited from ModelComponentCollection.)
Public method Equals (Inherited from Object.)
Public method Find Gets the DataSource, with the specified identifier, from the collection.
Public method FindByName Gets the DataSource, with the specified name, from the collection.
Public method GetByName Gets the DataSource, with the specified name, from the collection.
Public method GetEnumerator Returns an enumerator that can iterate through the ModelComponentCollection. (Inherited from ModelComponentCollection.)
Public method GetHashCode (Inherited from Object.)
Public method GetNewID() Gets a new unique ID for the component. (Inherited from NamedComponentCollection.)
Public method GetNewID(String) Gets the value for the new unique ID. (Inherited from NamedComponentCollection.)
Public method GetNewName() Gets a unique new name for the component. (Inherited from NamedComponentCollection.)
Public method GetNewName(String) Gets a unique new name for the component with the specified name prefix. (Inherited from NamedComponentCollection.)
Public method GetType (Inherited from Object.)
Public method IndexOf(String) Gets the index of a DataSource with the specified identifier.
Public method IndexOf(DataSource) Gets the index of a specified DataSource.
Public method IndexOfName Gets the index of the NamedComponent, identified by name, in the collection. (Inherited from NamedComponentCollection.)
Public method Insert(Int32) Creates and inserts a DataSource into the collection at the specified index.
Public method Insert(Int32, DataSource) Inserts a DataSource into the collection at the specified index.
Public method Insert(Int32, String) Creates and inserts a DataSource, with the specified identifier, into the collection at the specified index.
Protected method Insert(Int32, ModelComponent) Inserts a ModelComponent in the MajorObjectCollection at the specified index. (Inherited from MajorObjectCollection.)
Public method Insert(Int32, String, String) Creates and inserts a DataSource, with the specified name and identifier, into the collection at the specified index.
Public method IsValidID(String) Determines whether the named component collection identifier is valid. (Inherited from NamedComponentCollection.)
Public method IsValidID(String, String%) Determines whether the named component collection identifier is valid. (Inherited from NamedComponentCollection.)
Public method IsValidName(String) Determines whether the named component collection name is valid. (Inherited from NamedComponentCollection.)
Public method IsValidName(String, String%) Determines whether the named component collection name is valid. (Inherited from NamedComponentCollection.)
Protected method IsValidName(String, Type, ModelType, Int32, String%) (Inherited from NamedComponentCollection.)
Public method Move(Int32, Int32) Moves a DataSource at the current specified index to a new specified index in the collection.
Public method Move(String, Int32) Moves a DataSource, with the specified identifier, to the specified index in the collection.
Public method Move(DataSource, Int32) Moves a DataSource to a new index in the collection.
Public method Remove(String) Removes the DataSource, with the specified identifier, from the collection.
Public method Remove(DataSource) Removes the specified DataSource from the collection.
Protected method Remove(IModelComponent) Removes the specified IModelComponent from the collection. (Inherited from ModelComponentCollection.)
Public method Remove(String, Boolean) Infrastructure. Removes a DataSource from this collection.
Public method Remove(DataSource, Boolean) Infrastructure. Removes the specified DataSource from this collection.
Public method RemoveAt(Int32) Removes the IModelComponent at the specified index from the ModelComponentCollection. (Inherited from ModelComponentCollection.)
Public method RemoveAt(Int32, Boolean) Infrastructure. Removes the IModelComponent at the specified index from the ModelComponentCollection. (Inherited from ModelComponentCollection.)
Public method ToString (Inherited from Object.)

Top

Events

  Name Description
Public event CollectionChanged Infrastructure. Occurs when the collection changes. (Inherited from ModelComponentCollection.)
Public event CollectionChanging Infrastructure. Occurs when the collection is changing. (Inherited from ModelComponentCollection.)

Top

Explicit Interface Implementations

  Name Description
Explicit interface implemetationPrivate method IList.Add Adds an item to the collection. (Inherited from ModelComponentCollection.)
Explicit interface implemetationPrivate method IList.Clear Removes all items from the collection. (Inherited from ModelComponentCollection.)
Explicit interface implemetationPrivate method IList.Contains Indicates whether the collection contains a specific value. (Inherited from ModelComponentCollection.)
Explicit interface implemetationPrivate method IList.IndexOf Determines the index of a specific item in the collection. (Inherited from ModelComponentCollection.)
Explicit interface implemetationPrivate method IList.Insert Inserts an item to the collection at the specified index. (Inherited from ModelComponentCollection.)
Explicit interface implemetationPrivate property IList.Item Gets or sets the element at the specified index. (Inherited from ModelComponentCollection.)
Explicit interface implemetationPrivate method IList.Remove Removes the first occurrence of a specified object from the collection. (Inherited from ModelComponentCollection.)
Explicit interface implemetationPrivate method IList.RemoveAt Removes the item at the specified index. (Inherited from ModelComponentCollection.)
Explicit interface implemetationPrivate method IModelComponentCollection.Contains Indicates whether the collection contains a specific value. (Inherited from ModelComponentCollection.)
Explicit interface implemetationPrivate method IModelComponentCollection.Remove(IModelComponent) Removes the first occurrence of a specific IModelComponent from the ModelComponentCollection. (Inherited from ModelComponentCollection.)
Explicit interface implemetationPrivate method IModelComponentCollection.Remove(IModelComponent, Boolean) Removes the first occurrence of a specific IModelComponent from the ModelComponentCollection. (Inherited from ModelComponentCollection.)
Explicit interface implemetationPrivate method IOnDemandLoadableCollection.BlockOnDemandLoad Specifies the blocked demand load. (Inherited from ModelComponentCollection.)
Explicit interface implemetationPrivate property IOnDemandLoadableCollection.Loaded Gets or sets a value that indicates whether the collection is loaded. (Inherited from ModelComponentCollection.)

Top

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Reference

Microsoft.AnalysisServices Namespace