CodeNamespaceImportCollection クラス
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
CodeNamespaceImport オブジェクトのコレクションを表します。
public ref class CodeNamespaceImportCollection : System::Collections::IList
public class CodeNamespaceImportCollection : System.Collections.IList
[System.Runtime.InteropServices.ClassInterface(System.Runtime.InteropServices.ClassInterfaceType.AutoDispatch)]
[System.Runtime.InteropServices.ComVisible(true)]
[System.Serializable]
public class CodeNamespaceImportCollection : System.Collections.IList
type CodeNamespaceImportCollection = class
interface ICollection
interface IEnumerable
interface IList
type CodeNamespaceImportCollection = class
interface IList
interface ICollection
interface IEnumerable
[<System.Runtime.InteropServices.ClassInterface(System.Runtime.InteropServices.ClassInterfaceType.AutoDispatch)>]
[<System.Runtime.InteropServices.ComVisible(true)>]
[<System.Serializable>]
type CodeNamespaceImportCollection = class
interface IList
interface ICollection
interface IEnumerable
Public Class CodeNamespaceImportCollection
Implements IList
- 継承
-
CodeNamespaceImportCollection
- 属性
- 実装
次の例では、 クラスのメンバーの一部を CodeNamespaceImportCollection 示します。 この例では、 クラスの新しいインスタンスを初期化し、それにオブジェクトを追加 CodeNamespaceImport し、コレクション内のオブジェクトの合計数を取得します。
// Creates an empty CodeNamespaceImportCollection.
CodeNamespaceImportCollection^ collection =
gcnew CodeNamespaceImportCollection;
// Adds a CodeNamespaceImport to the collection.
collection->Add( gcnew CodeNamespaceImport( "System" ) );
// Adds an array of CodeNamespaceImport objects to the collection.
array<CodeNamespaceImport^>^ Imports = {
gcnew CodeNamespaceImport( "System" ),
gcnew CodeNamespaceImport( "System.Drawing" )};
collection->AddRange( Imports );
// Retrieves the count of the items in the collection.
int collectionCount = collection->Count;
// Creates an empty CodeNamespaceImportCollection.
CodeNamespaceImportCollection collection =
new CodeNamespaceImportCollection();
// Adds a CodeNamespaceImport to the collection.
collection.Add( new CodeNamespaceImport("System") );
// Adds an array of CodeNamespaceImport objects to the collection.
CodeNamespaceImport[] Imports = {
new CodeNamespaceImport("System"),
new CodeNamespaceImport("System.Drawing") };
collection.AddRange( Imports );
// Retrieves the count of the items in the collection.
int collectionCount = collection.Count;
' Creates an empty CodeNamespaceImportCollection.
Dim collection As New CodeNamespaceImportCollection()
' Adds a CodeNamespaceImport to the collection.
collection.Add(New CodeNamespaceImport("System"))
' Adds an array of CodeNamespaceImport objects to the collection.
Dim [Imports] As CodeNamespaceImport() = _
{New CodeNamespaceImport("System"), _
New CodeNamespaceImport("System.Drawing")}
collection.AddRange([Imports])
' Retrieves the count of the items in the collection.
Dim collectionCount As Integer = collection.Count
CodeNamespaceImportCollection クラスには、一連の CodeNamespaceImport オブジェクトの格納に使用できる単純なコレクション オブジェクトが用意されています。
Code |
CodeNamespaceImportCollection クラスの新しいインスタンスを初期化します。 |
Count |
コレクション内の名前空間の数を取得します。 |
Item[Int32] |
コレクション内の指定したインデックスでの CodeNamespaceImport オブジェクトを取得または設定します。 |
Add(Code |
CodeNamespaceImport オブジェクトをコレクションに追加します。 |
Add |
CodeNamespaceImport オブジェクトのセットをコレクションに追加します。 |
Clear() |
メンバーのコレクションを消去します。 |
Equals(Object) |
指定されたオブジェクトが現在のオブジェクトと等しいかどうかを判断します。 (継承元 Object) |
Get |
コレクション メンバーを列挙する列挙子を取得します。 |
Get |
既定のハッシュ関数として機能します。 (継承元 Object) |
Get |
現在のインスタンスの Type を取得します。 (継承元 Object) |
Memberwise |
現在の Object の簡易コピーを作成します。 (継承元 Object) |
To |
現在のオブジェクトを表す文字列を返します。 (継承元 Object) |
ICollection. |
ICollection の要素を Array にコピーします。Array の特定のインデックスからコピーが開始されます。 |
ICollection. |
ICollection に格納されている要素の数を取得します。 |
ICollection. |
ICollection へのアクセスが同期されている (スレッド セーフである) かどうかを示す値を取得します。 |
ICollection. |
ICollection へのアクセスを同期するために使用できるオブジェクトを取得します。 |
IEnumerable. |
コレクションを反復処理できる列挙子を返します。 |
IList. |
オブジェクトを IList に追加します。 |
IList. |
IList からすべての項目を削除します。 |
IList. |
IList に特定の値が格納されているかどうかを判断します。 |
IList. |
IList 内の特定の項目のインデックスを確認します。 |
IList. |
指定した位置にある IList に項目を挿入します。 |
IList. |
IList が固定サイズかどうかを示す値を取得します。 |
IList. |
IList が読み取り専用かどうかを示す値を取得します。 |
IList. |
指定したインデックスにある要素を取得または設定します。 |
IList. |
特定のオブジェクトが IList 内にあるときに、最初に出現したものを削除します。 |
IList. |
IList の指定したインデックスにある要素を削除します。 |
Cast<TResult>(IEnumerable) |
IEnumerable の要素を、指定した型にキャストします。 |
Of |
指定された型に基づいて IEnumerable の要素をフィルター処理します。 |
As |
クエリの並列化を有効にします。 |
As |
IEnumerable を IQueryable に変換します。 |
製品 | バージョン |
---|---|
.NET Framework | 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
Windows Desktop | 3.0, 3.1, 5, 6, 7, 8, 9 |
.NET に関するフィードバック
.NET はオープンソース プロジェクトです。 フィードバックを提供するにはリンクを選択します。