BindingList<T> クラス

定義

データ バインディングをサポートするジェネリック コレクションを提供します。

generic <typename T>
public ref class BindingList : System::Collections::ObjectModel::Collection<T>, System::ComponentModel::IBindingList, System::ComponentModel::ICancelAddNew, System::ComponentModel::IRaiseItemChangedEvents
public class BindingList<T> : System.Collections.ObjectModel.Collection<T>, System.ComponentModel.IBindingList, System.ComponentModel.ICancelAddNew, System.ComponentModel.IRaiseItemChangedEvents
[System.Serializable]
public class BindingList<T> : System.Collections.ObjectModel.Collection<T>, System.ComponentModel.IBindingList, System.ComponentModel.ICancelAddNew, System.ComponentModel.IRaiseItemChangedEvents
type BindingList<'T> = class
    inherit Collection<'T>
    interface ICollection
    interface IEnumerable
    interface IList
    interface IBindingList
    interface ICancelAddNew
    interface IRaiseItemChangedEvents
[<System.Serializable>]
type BindingList<'T> = class
    inherit Collection<'T>
    interface IBindingList
    interface IList
    interface ICollection
    interface IEnumerable
    interface ICancelAddNew
    interface IRaiseItemChangedEvents
Public Class BindingList(Of T)
Inherits Collection(Of T)
Implements IBindingList, ICancelAddNew, IRaiseItemChangedEvents

型パラメーター

T

リスト内の要素の型です。

継承
BindingList<T>
属性
実装

次のコード例では、ビジネス オブジェクトを BindingList<T> 含むコンポーネントへのバインドを示します。 これは、 メソッドを含む完全な例です Main

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace BindingListOfTExamples
{
    public partial class Form1 : Form
    {
        private TextBox textBox2;
        private ListBox listBox1;
        private Button button1;
        private TextBox textBox1;
        Random randomNumber = new Random();
    
        public Form1()
        {
           this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
           this.textBox1 = new System.Windows.Forms.TextBox();
           this.textBox2 = new System.Windows.Forms.TextBox();
           this.listBox1 = new System.Windows.Forms.ListBox();
           this.button1 = new System.Windows.Forms.Button();
           this.textBox1.Location = new System.Drawing.Point(169, 26);
           this.textBox1.Size = new System.Drawing.Size(100, 20);
           this.textBox1.Text = "Bracket";
           this.textBox2.Location = new System.Drawing.Point(169, 57);
           this.textBox2.ReadOnly = true;
           this.textBox2.Size = new System.Drawing.Size(100, 20);
           this.textBox2.Text = "4343";
           this.listBox1.FormattingEnabled = true;
           this.listBox1.Location = new System.Drawing.Point(12, 12);
           this.listBox1.Size = new System.Drawing.Size(120, 95);
           this.button1.Location = new System.Drawing.Point(180, 83);
           this.button1.Size = new System.Drawing.Size(75, 23);
           this.button1.Text = "Add New Item";
           this.button1.Click += new System.EventHandler(this.button1_Click);
           this.ClientSize = new System.Drawing.Size(292, 266);
           this.Controls.Add(this.button1);
           this.Controls.Add(this.listBox1);
           this.Controls.Add(this.textBox2);
           this.Controls.Add(this.textBox1);
           this.Text = "Parts Form";
           this.Load += new EventHandler(Form1_Load);
        }
    
        void Form1_Load(object sender, EventArgs e)
        {
            InitializeListOfParts();
            listBox1.DataSource = listOfParts;
            listBox1.DisplayMember = "PartName";
            listOfParts.AddingNew += new AddingNewEventHandler(listOfParts_AddingNew);
            listOfParts.ListChanged += new ListChangedEventHandler(listOfParts_ListChanged);
        }

        // Declare a new BindingListOfT with the Part business object.
        BindingList<Part> listOfParts; 
        private void InitializeListOfParts()
        {
            // Create the new BindingList of Part type.
            listOfParts = new BindingList<Part>();
    
            // Allow new parts to be added, but not removed once committed.        
            listOfParts.AllowNew = true;
            listOfParts.AllowRemove = false;

            // Raise ListChanged events when new parts are added.
            listOfParts.RaiseListChangedEvents = true;

            // Do not allow parts to be edited.
            listOfParts.AllowEdit = false;
            
            // Add a couple of parts to the list.
            listOfParts.Add(new Part("Widget", 1234));
            listOfParts.Add(new Part("Gadget", 5647));
        }

        // Create a new part from the text in the two text boxes.
        void listOfParts_AddingNew(object sender, AddingNewEventArgs e)
        {
            e.NewObject = new Part(textBox1.Text, int.Parse(textBox2.Text));
        }

        // Add the new part unless the part number contains
        // spaces. In that case cancel the add.
        private void button1_Click(object sender, EventArgs e)
        {
            Part newPart = listOfParts.AddNew();

            if (newPart.PartName.Contains(" "))
            {
                MessageBox.Show("Part names cannot contain spaces.");
                listOfParts.CancelNew(listOfParts.IndexOf(newPart));
            }
            else
            {
                textBox2.Text = randomNumber.Next(9999).ToString();
                textBox1.Text = "Enter part name";
            }
        }

        void listOfParts_ListChanged(object sender, ListChangedEventArgs e)
        {
            MessageBox.Show(e.ListChangedType.ToString());
        }

        [STAThread]
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.Run(new Form1());
        }
    }
    
    // A simple business object for example purposes.
    public class Part
    {
        private string name;
        private int number;
        public Part() { }
        public Part(string nameForPart, int numberForPart)
        {
            PartName = nameForPart;
            PartNumber = numberForPart;
        }

        public string PartName
        {
            get { return name; }
            set { name = value; }
        }

        public int PartNumber
        {
            get { return number; }
            set { number = value; }
        }
    }
}

Option Explicit On
Option Strict On
Imports System.Collections.Generic
Imports System.ComponentModel
Imports System.Drawing
Imports System.Text
Imports System.Windows.Forms

Class Form1
    Inherits Form

    Private textBox2 As TextBox
    Private listBox1 As ListBox
    Private WithEvents button1 As Button
    Private textBox1 As TextBox
    Private randomNumber As New Random()

    Public Sub New()
        Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
        Me.textBox1 = New System.Windows.Forms.TextBox()
        Me.textBox2 = New System.Windows.Forms.TextBox()
        Me.listBox1 = New System.Windows.Forms.ListBox()
        Me.button1 = New System.Windows.Forms.Button()
        Me.textBox1.Location = New System.Drawing.Point(169, 26)
        Me.textBox1.Size = New System.Drawing.Size(100, 20)
        Me.textBox1.Text = "Bracket"
        Me.textBox2.Location = New System.Drawing.Point(169, 57)
        Me.textBox2.ReadOnly = True
        Me.textBox2.Size = New System.Drawing.Size(100, 20)
        Me.textBox2.Text = "4343"
        Me.listBox1.FormattingEnabled = True
        Me.listBox1.Location = New System.Drawing.Point(12, 12)
        Me.listBox1.Size = New System.Drawing.Size(120, 95)
        Me.button1.Location = New System.Drawing.Point(180, 83)
        Me.button1.Size = New System.Drawing.Size(75, 23)
        Me.button1.Text = "Add New Item"
        Me.ClientSize = New System.Drawing.Size(292, 266)
        Me.Controls.Add(Me.button1)
        Me.Controls.Add(Me.listBox1)
        Me.Controls.Add(Me.textBox2)
        Me.Controls.Add(Me.textBox1)
        Me.Text = "Parts Form"
        AddHandler Me.Load, AddressOf Form1_Load

    End Sub

    Sub Form1_Load(ByVal sender As Object, ByVal e As EventArgs)
        InitializeListOfParts()
        listBox1.DataSource = listOfParts
        listBox1.DisplayMember = "PartName"
    End Sub

    ' Declare a new BindingListOfT with the Part business object.
    Private WithEvents listOfParts As BindingList(Of Part)

    Private Sub InitializeListOfParts()

        ' Create the new BindingList of Part type.
        listOfParts = New BindingList(Of Part)

        ' Allow new parts to be added, but not removed once committed.        
        listOfParts.AllowNew = True
        listOfParts.AllowRemove = False

        ' Raise ListChanged events when new parts are added.
        listOfParts.RaiseListChangedEvents = True

        ' Do not allow parts to be edited.
        listOfParts.AllowEdit = False

        ' Add a couple of parts to the list.
        listOfParts.Add(New Part("Widget", 1234))
        listOfParts.Add(New Part("Gadget", 5647))

    End Sub

    ' Create a new part from the text in the two text boxes.
    Private Sub listOfParts_AddingNew(ByVal sender As Object, _
        ByVal e As AddingNewEventArgs) Handles listOfParts.AddingNew
        e.NewObject = New Part(textBox1.Text, Integer.Parse(textBox2.Text))

    End Sub


    ' Add the new part unless the part number contains
    ' spaces. In that case cancel the add.
    Private Sub button1_Click(ByVal sender As Object, _
        ByVal e As EventArgs) Handles button1.Click

        Dim newPart As Part = listOfParts.AddNew()

        If newPart.PartName.Contains(" ") Then
            MessageBox.Show("Part names cannot contain spaces.")
            listOfParts.CancelNew(listOfParts.IndexOf(newPart))
        Else
            textBox2.Text = randomNumber.Next(9999).ToString()
            textBox1.Text = "Enter part name"
        End If

    End Sub

    <STAThread()> _
    Shared Sub Main()
        Application.EnableVisualStyles()
        Application.Run(New Form1())

    End Sub
End Class

' A simple business object for example purposes.
Public Class Part
    Private name As String
    Private number As Integer

    Public Sub New()
    End Sub

    Public Sub New(ByVal nameForPart As String, _
        ByVal numberForPart As Integer)
        PartName = nameForPart
        PartNumber = numberForPart

    End Sub


    Public Property PartName() As String
        Get
            Return name
        End Get
        Set(ByVal value As String)
            name = Value
        End Set
    End Property

    Public Property PartNumber() As Integer
        Get
            Return number
        End Get
        Set(ByVal value As Integer)
            number = Value
        End Set
    End Property
End Class

注釈

クラスは BindingList<T> 、双方向のデータ バインディング メカニズムを作成するための基本クラスとして使用できます。 BindingList<T> は、 インターフェイスの具象的で汎用的な実装を IBindingList 提供します。 これは、および 関連CurrencyManagerする の間IEditableObjectIBindingListの微妙な相互作用のために困難な場合がある、完全なIBindingListインターフェイスを実装する代わりに使用します。 ただし、一般的なソリューション プログラマは、 を直接使用する代わりに、 などの BindingSourceデータ バインディング機能を提供するクラスを使用 BindingList<T>します。

BindingList<T> は、拡張可能 AddNew なメソッドを使用してファクトリで作成されたインスタンスをサポートします。 (この同じ種類の拡張性は、 などのBindingSource他のクラスでも見つかります)。さらに、このクラスは インターフェイスをICancelAddNew実装するため、 メソッドと CancelNew メソッドを使用して新しい項目のトランザクション コミットまたはロールバックをEndNew有効にします。

コンストラクター

BindingList<T>()

既定値を使用して BindingList<T> クラスの新しいインスタンスを初期化します。

BindingList<T>(IList<T>)

指定されたリストを使用して、BindingList<T> クラスの新しいインスタンスを初期化します。

プロパティ

AllowEdit

リスト内の項目を編集できるかどうかを示す値を取得または設定します。

AllowNew

AddNew() メソッドを使用してリストに項目を追加できるかどうかを示す値を取得または設定します。

AllowRemove

コレクションから項目を削除できるかどうかを示す値を取得または設定します。

Count

Collection<T> に実際に含まれる要素の数を取得します。

(継承元 Collection<T>)
IsSortedCore

リストが並べ替えられたかどうかを示す値を取得します。

Item[Int32]

指定したインデックスにある要素を取得または設定します。

(継承元 Collection<T>)
Items

IList<T> をラップする Collection<T> ラッパーを取得します。

(継承元 Collection<T>)
RaiseListChangedEvents

リストの項目を追加または削除すると ListChanged イベントが発生するかどうかを示す値を取得または設定します。

SortDirectionCore

リストが並べ替えられる順序を取得します。

SortPropertyCore

派生クラスで並べ替えが実装されている場合、リストの並べ替えに使用されるプロパティ記述子を取得します。実装されていない場合は null を返します。

SupportsChangeNotificationCore

ListChanged イベントが有効かどうかを示す値を取得します。

SupportsSearchingCore

リストが検索をサポートしているかどうかを示す値を取得します。

SupportsSortingCore

リストが並べ替えをサポートしているかどうかを示す値を取得します。

メソッド

Add(T)

Collection<T> の末尾にオブジェクトを追加します。

(継承元 Collection<T>)
AddNew()

新しい項目をコレクションに追加します。

AddNewCore()

コレクションの末尾に新しい項目を追加します。

ApplySortCore(PropertyDescriptor, ListSortDirection)

派生クラスでオーバーライドされた場合は、項目を並べ替えます。それ以外の場合は NotSupportedException をスローします。

CancelNew(Int32)

保留中の新しい項目を破棄します。

Clear()

Collection<T> からすべての要素を削除します。

(継承元 Collection<T>)
ClearItems()

コレクションからすべての要素を削除します。

Contains(T)

ある要素が Collection<T> 内に存在するかどうかを判断します。

(継承元 Collection<T>)
CopyTo(T[], Int32)

Collection<T> 全体を互換性のある 1 次元の Array にコピーします。コピー操作は、コピー先の配列の指定したインデックスから始まります。

(継承元 Collection<T>)
EndNew(Int32)

保留中の新しい項目をコレクションにコミットします。

Equals(Object)

指定されたオブジェクトが現在のオブジェクトと等しいかどうかを判断します。

(継承元 Object)
FindCore(PropertyDescriptor, Object)

検索が派生クラスに実装されている場合、指定した値の指定したプロパティ記述子を持つ項目のインデックスを検索します。実装されていない場合は NotSupportedException がスローされます。

GetEnumerator()

Collection<T> を反復処理する列挙子を返します。

(継承元 Collection<T>)
GetHashCode()

既定のハッシュ関数として機能します。

(継承元 Object)
GetType()

現在のインスタンスの Type を取得します。

(継承元 Object)
IndexOf(T)

Collection<T> 全体から指定したオブジェクトを検索し、最初に見つかったオブジェクトのインデックス (0 から始まる) を返します。

(継承元 Collection<T>)
Insert(Int32, T)

Collection<T> 内の指定したインデックスの位置に要素を挿入します。

(継承元 Collection<T>)
InsertItem(Int32, T)

リスト内の指定したインデックス位置に、指定した項目を挿入します。

MemberwiseClone()

現在の Object の簡易コピーを作成します。

(継承元 Object)
OnAddingNew(AddingNewEventArgs)

AddingNew イベントを発生させます。

OnListChanged(ListChangedEventArgs)

ListChanged イベントを発生させます。

Remove(T)

特定のオブジェクトが Collection<T> 内にあるときに、最初に出現したものを削除します。

(継承元 Collection<T>)
RemoveAt(Int32)

Collection<T> の指定したインデックスにある要素を削除します。

(継承元 Collection<T>)
RemoveItem(Int32)

指定したインデックス位置にある項目を削除します。

RemoveSortCore()

派生クラスで並べ替えが実装されている場合は、ApplySortCore(PropertyDescriptor, ListSortDirection) を使用して適用された並べ替えをすべて解除します。それ以外の場合は NotSupportedException を発生させます。

ResetBindings()

種類が ListChangedReset イベントを発生させます。

ResetItem(Int32)

指定した位置の項目に対して、種類が ListChangedItemChanged イベントを発生させます。

SetItem(Int32, T)

指定したインデックス位置の項目を、指定した項目で置き換えます。

ToString()

現在のオブジェクトを表す文字列を返します。

(継承元 Object)

イベント

AddingNew

項目がリストに追加される前に発生します。

ListChanged

リストまたはリスト内の項目が変更された場合に発生します。

明示的なインターフェイスの実装

IBindingList.AddIndex(PropertyDescriptor)

このメンバーの詳細については、「AddIndex(PropertyDescriptor)」をご覧ください。

IBindingList.AddNew()

リストに新しい項目を追加します。 詳細については、「AddNew()」を参照してください。

IBindingList.AllowEdit

リスト内の項目を編集できるかどうかを示す値を取得します。

IBindingList.AllowNew

AddNew() メソッドを使用してリストに新しい項目を追加できるかどうかを示す値を取得します。

IBindingList.AllowRemove

リストから項目を削除できるかどうかを示す値を取得します。

IBindingList.ApplySort(PropertyDescriptor, ListSortDirection)

PropertyDescriptorListSortDirection に基づいて並べ替えを行います。 このメンバーの詳細については、ApplySort(PropertyDescriptor, ListSortDirection) のトピックを参照してください。

IBindingList.Find(PropertyDescriptor, Object)

このメンバーの詳細については、「Find(PropertyDescriptor, Object)」をご覧ください。

IBindingList.IsSorted

このメンバーの詳細については、「IsSorted」をご覧ください。

IBindingList.RemoveIndex(PropertyDescriptor)

このメンバーの詳細については、「RemoveIndex(PropertyDescriptor)」をご覧ください。

IBindingList.RemoveSort()

このメンバーの詳細については、「RemoveSort()」をご覧ください。

IBindingList.SortDirection

このメンバーの詳細については、「SortDirection」をご覧ください。

IBindingList.SortProperty

このメンバーの詳細については、「SortProperty」をご覧ください。

IBindingList.SupportsChangeNotification

このメンバーの詳細については、「SupportsChangeNotification」をご覧ください。

IBindingList.SupportsSearching

このメンバーの詳細については、「SupportsSearching」をご覧ください。

IBindingList.SupportsSorting

このメンバーの詳細については、「SupportsSorting」をご覧ください。

ICollection.CopyTo(Array, Int32)

ICollection の要素を Array にコピーします。Array の特定のインデックスからコピーが開始されます。

(継承元 Collection<T>)
ICollection.IsSynchronized

ICollection へのアクセスが同期されている (スレッド セーフである) かどうかを示す値を取得します。

(継承元 Collection<T>)
ICollection.SyncRoot

ICollection へのアクセスを同期するために使用できるオブジェクトを取得します。

(継承元 Collection<T>)
ICollection<T>.IsReadOnly

ICollection<T> が読み取り専用かどうかを示す値を取得します。

(継承元 Collection<T>)
IEnumerable.GetEnumerator()

コレクションを反復処理する列挙子を返します。

(継承元 Collection<T>)
IList.Add(Object)

IList に項目を追加します。

(継承元 Collection<T>)
IList.Contains(Object)

IList に特定の値が格納されているかどうかを判断します。

(継承元 Collection<T>)
IList.IndexOf(Object)

IList 内の特定の項目のインデックスを確認します。

(継承元 Collection<T>)
IList.Insert(Int32, Object)

IList 内の指定したインデックス位置に項目を挿入します。

(継承元 Collection<T>)
IList.IsFixedSize

IList が固定サイズかどうかを示す値を取得します。

(継承元 Collection<T>)
IList.IsReadOnly

IList が読み取り専用かどうかを示す値を取得します。

(継承元 Collection<T>)
IList.Item[Int32]

指定したインデックスにある要素を取得または設定します。

(継承元 Collection<T>)
IList.Remove(Object)

特定のオブジェクトが IList 内にあるときに、最初に出現したものを削除します。

(継承元 Collection<T>)
IRaiseItemChangedEvents.RaisesItemChangedEvents

項目のプロパティ値が変更されると、種類が ListChangedItemChanged イベントが発生するかどうかを示す値を取得します。 このメンバーは、派生クラスでオーバーライドすることはできません。

拡張メソッド

ToFrozenDictionary<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)

FrozenDictionary<TKey,TValue>指定したキー セレクター関数に従って から IEnumerable<T> を作成します。

ToFrozenDictionary<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>, IEqualityComparer<TKey>)

指定されたキー セレクター関数および要素セレクター関数に従って、FrozenDictionary<TKey,TValue> から IEnumerable<T> を作成します。

ToFrozenSet<T>(IEnumerable<T>, IEqualityComparer<T>)

FrozenSet<T>指定した値を使用して を作成します。

AsReadOnly<T>(IList<T>)

指定したリストの読み取り専用 ReadOnlyCollection<T> ラッパーを返します。

ToImmutableArray<TSource>(IEnumerable<TSource>)

指定されたコレクションから、変更できない配列を作成します。

ToImmutableDictionary<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

ソース キーに変換関数を適用し、変更できないディクショナリを既存の要素のコレクションから作成します。

ToImmutableDictionary<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)

シーケンスの変換に基づき、変更できないディクショナリを作成します。

ToImmutableDictionary<TSource,TKey,TValue>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TValue>)

シーケンスを列挙して変換し、その内容の変更できないディクショナリを生成します。

ToImmutableDictionary<TSource,TKey,TValue>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TValue>, IEqualityComparer<TKey>)

シーケンスを列挙して変換し、指定されたキーの比較子を使用してその内容の変更できないディクショナリを生成します。

ToImmutableDictionary<TSource,TKey,TValue>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TValue>, IEqualityComparer<TKey>, IEqualityComparer<TValue>)

シーケンスを列挙して変換し、指定されたキーの比較子および値の比較子を使用してその内容の変更できないディクショナリを生成します。

ToImmutableHashSet<TSource>(IEnumerable<TSource>)

シーケンスを列挙し、その内容の変更できないハッシュ セットを生成します。

ToImmutableHashSet<TSource>(IEnumerable<TSource>, IEqualityComparer<TSource>)

シーケンスを列挙し、その内容の変更できないハッシュ セットを生成して、指定された等値比較子をセットの種類に使用します。

ToImmutableList<TSource>(IEnumerable<TSource>)

シーケンスを列挙し、その内容の変更できないリストを生成します。

ToImmutableSortedDictionary<TSource,TKey,TValue>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TValue>)

シーケンスを列挙して変換し、その内容の変更できない並べ替えられたディクショナリを生成します。

ToImmutableSortedDictionary<TSource,TKey,TValue>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TValue>, IComparer<TKey>)

シーケンスを列挙して変換し、指定されたキーの比較子を使用してその内容の変更できない並べ替えられたディクショナリを生成します。

ToImmutableSortedDictionary<TSource,TKey,TValue>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TValue>, IComparer<TKey>, IEqualityComparer<TValue>)

シーケンスを列挙して変換し、指定されたキーの比較子と値の比較子を使用してその内容の変更できない並べ替えられたディクショナリを生成します。

ToImmutableSortedSet<TSource>(IEnumerable<TSource>)

シーケンスを列挙し、その内容の変更できない並べ替えられたセットを生成します。

ToImmutableSortedSet<TSource>(IEnumerable<TSource>, IComparer<TSource>)

シーケンスを列挙し、その内容の変更できない並べ替えられたセットを生成して、指定された比較子を使用します。

CopyToDataTable<T>(IEnumerable<T>)

指定した入力 DataTable オブジェクトに応じて (ジェネリック パラメーター TDataRow)、IEnumerable<T> オブジェクトのコピーを格納する DataRow を返します。

CopyToDataTable<T>(IEnumerable<T>, DataTable, LoadOption)

指定した入力 DataRow オブジェクトに応じて (ジェネリック パラメーター TDataTable)、指定した IEnumerable<T>DataRow オブジェクトをコピーします。

CopyToDataTable<T>(IEnumerable<T>, DataTable, LoadOption, FillErrorEventHandler)

指定した入力 DataRow オブジェクトに応じて (ジェネリック パラメーター TDataTable)、指定した IEnumerable<T>DataRow オブジェクトをコピーします。

Aggregate<TSource>(IEnumerable<TSource>, Func<TSource,TSource,TSource>)

シーケンスにアキュムレータ関数を適用します。

Aggregate<TSource,TAccumulate>(IEnumerable<TSource>, TAccumulate, Func<TAccumulate,TSource,TAccumulate>)

シーケンスにアキュムレータ関数を適用します。 指定されたシード値が最初のアキュムレータ値として使用されます。

Aggregate<TSource,TAccumulate,TResult>(IEnumerable<TSource>, TAccumulate, Func<TAccumulate,TSource,TAccumulate>, Func<TAccumulate,TResult>)

シーケンスにアキュムレータ関数を適用します。 指定したシード値は最初のアキュムレータ値として使用され、指定した関数は結果値の選択に使用されます。

AggregateBy<TSource,TKey,TAccumulate>(IEnumerable<TSource>, Func<TSource, TKey>, TAccumulate, Func<TAccumulate,TSource,TAccumulate>, IEqualityComparer<TKey>)

データ バインディングをサポートするジェネリック コレクションを提供します。

AggregateBy<TSource,TKey,TAccumulate>(IEnumerable<TSource>, Func<TSource, TKey>, Func<TKey,TAccumulate>, Func<TAccumulate,TSource,TAccumulate>, IEqualityComparer<TKey>)

データ バインディングをサポートするジェネリック コレクションを提供します。

All<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

シーケンスのすべての要素が条件を満たしているかどうかを判断します。

Any<TSource>(IEnumerable<TSource>)

シーケンスに要素が含まれているかどうかを判断します。

Any<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

シーケンスの任意の要素が条件を満たしているかどうかを判断します。

Append<TSource>(IEnumerable<TSource>, TSource)

シーケンスの末尾に値を追加します。

AsEnumerable<TSource>(IEnumerable<TSource>)

IEnumerable<T> として型指定された入力を返します。

Average<TSource>(IEnumerable<TSource>, Func<TSource,Decimal>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する Decimal 値のシーケンスの平均値を計算します。

Average<TSource>(IEnumerable<TSource>, Func<TSource,Double>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する Double 値のシーケンスの平均値を計算します。

Average<TSource>(IEnumerable<TSource>, Func<TSource,Int32>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する Int32 値のシーケンスの平均値を計算します。

Average<TSource>(IEnumerable<TSource>, Func<TSource,Int64>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する Int64 値のシーケンスの平均値を計算します。

Average<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Decimal>>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する null 許容の Decimal 値のシーケンスの平均値を計算します。

Average<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Double>>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する null 許容の Double 値のシーケンスの平均値を計算します。

Average<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int32>>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する null 許容の Int32 値のシーケンスの平均値を計算します。

Average<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int64>>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する null 許容の Int64 値のシーケンスの平均値を計算します。

Average<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Single>>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する null 許容の Single 値のシーケンスの平均値を計算します。

Average<TSource>(IEnumerable<TSource>, Func<TSource,Single>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する Single 値のシーケンスの平均値を計算します。

Cast<TResult>(IEnumerable)

IEnumerable の要素を、指定した型にキャストします。

Chunk<TSource>(IEnumerable<TSource>, Int32)

シーケンスの要素を最大サイズの sizeチャンクに分割します。

Concat<TSource>(IEnumerable<TSource>, IEnumerable<TSource>)

2 つのシーケンスを連結します。

Contains<TSource>(IEnumerable<TSource>, TSource)

既定の等値比較子を使用して、指定した要素がシーケンスに含まれているかどうかを判断します。

Contains<TSource>(IEnumerable<TSource>, TSource, IEqualityComparer<TSource>)

指定した IEqualityComparer<T> を使用して、指定した要素がシーケンスに含まれているかどうかを判断します。

Count<TSource>(IEnumerable<TSource>)

シーケンス内の要素数を返します。

Count<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

条件を満たす、指定されたシーケンス内の要素の数を表す数値を返します。

CountBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)

データ バインディングをサポートするジェネリック コレクションを提供します。

DefaultIfEmpty<TSource>(IEnumerable<TSource>)

指定したシーケンスの要素を返します。シーケンスが空の場合はシングルトン コレクションにある型パラメーターの既定値を返します。

DefaultIfEmpty<TSource>(IEnumerable<TSource>, TSource)

指定されたシーケンスの要素を返します。シーケンスが空の場合はシングルトン コレクションにある型パラメーターの既定値を返します。

Distinct<TSource>(IEnumerable<TSource>)

既定の等値比較子を使用して値を比較することにより、シーケンスから一意の要素を返します。

Distinct<TSource>(IEnumerable<TSource>, IEqualityComparer<TSource>)

指定された IEqualityComparer<T> を使用して値を比較することにより、シーケンスから一意の要素を返します。

DistinctBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

指定したキー セレクター関数に従って、シーケンスから個別の要素を返します。

DistinctBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)

指定したキー セレクター関数に従ってシーケンスから個別の要素を返し、指定した比較子を使用してキーを比較します。

ElementAt<TSource>(IEnumerable<TSource>, Index)

シーケンス内の指定されたインデックス位置にある要素を返します。

ElementAt<TSource>(IEnumerable<TSource>, Int32)

シーケンス内の指定されたインデックス位置にある要素を返します。

ElementAtOrDefault<TSource>(IEnumerable<TSource>, Index)

シーケンス内の指定したインデックス位置にある要素を返します。インデックスが範囲外の場合は既定値を返します。

ElementAtOrDefault<TSource>(IEnumerable<TSource>, Int32)

シーケンス内の指定したインデックス位置にある要素を返します。インデックスが範囲外の場合は既定値を返します。

Except<TSource>(IEnumerable<TSource>, IEnumerable<TSource>)

既定の等値比較子を使用して値を比較することにより、2 つのシーケンスの差集合を生成します。

Except<TSource>(IEnumerable<TSource>, IEnumerable<TSource>, IEqualityComparer<TSource>)

指定された IEqualityComparer<T> を使用して値を比較することにより、2 つのシーケンスの差集合を生成します。

ExceptBy<TSource,TKey>(IEnumerable<TSource>, IEnumerable<TKey>, Func<TSource,TKey>)

指定したキー セレクター関数に従って、2 つのシーケンスのセット差を生成します。

ExceptBy<TSource,TKey>(IEnumerable<TSource>, IEnumerable<TKey>, Func<TSource,TKey>, IEqualityComparer<TKey>)

指定したキー セレクター関数に従って、2 つのシーケンスのセット差を生成します。

First<TSource>(IEnumerable<TSource>)

シーケンスの最初の要素を返します。

First<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

指定された条件を満たす、シーケンスの最初の要素を返します。

FirstOrDefault<TSource>(IEnumerable<TSource>)

シーケンスの最初の要素を返します。シーケンスに要素が含まれていない場合は既定値を返します。

FirstOrDefault<TSource>(IEnumerable<TSource>, TSource)

シーケンスの最初の要素を返します。シーケンスに要素が含まれない場合は、指定した既定値を返します。

FirstOrDefault<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

条件を満たす、シーケンスの最初の要素を返します。このような要素が見つからない場合は既定値を返します。

FirstOrDefault<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>, TSource)

条件を満たすシーケンスの最初の要素、またはそのような要素が見つからない場合は、指定された既定値を返します。

GroupBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

指定されたキー セレクター関数に従ってシーケンスの要素をグループ化します。

GroupBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)

指定されたキー セレクター関数に従ってシーケンスの要素をグループ化し、指定された比較子を使用してキーを比較します。

GroupBy<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>)

指定されたキー セレクター関数に従ってシーケンスの要素をグループ化し、指定された関数を使用して各グループの要素を射影します。

GroupBy<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>, IEqualityComparer<TKey>)

キー セレクター関数に従ってシーケンスの要素をグループ化します。 キーの比較には、比較子を使用し、各グループの要素の射影には、指定された関数を使用します。

GroupBy<TSource,TKey,TResult>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TKey,IEnumerable<TSource>,TResult>)

指定されたキー セレクター関数に従ってシーケンスの要素をグループ化し、各グループとそのキーから結果値を作成します。

GroupBy<TSource,TKey,TResult>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TKey,IEnumerable<TSource>,TResult>, IEqualityComparer<TKey>)

指定されたキー セレクター関数に従ってシーケンスの要素をグループ化し、各グループとそのキーから結果値を作成します。 キーの比較には、指定された比較子を使用します。

GroupBy<TSource,TKey,TElement,TResult>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>, Func<TKey,IEnumerable<TElement>,TResult>)

指定されたキー セレクター関数に従ってシーケンスの要素をグループ化し、各グループとそのキーから結果値を作成します。 各グループの要素は、指定された関数を使用して射影されます。

GroupBy<TSource,TKey,TElement,TResult>(IEnumerable<TSource>, Func<TSource, TKey>, Func<TSource,TElement>, Func<TKey,IEnumerable<TElement>, TResult>, IEqualityComparer<TKey>)

指定されたキー セレクター関数に従ってシーケンスの要素をグループ化し、各グループとそのキーから結果値を作成します。 キー値の比較には、指定された比較子を使用し、各グループの要素の射影には、指定された関数を使用します。

GroupJoin<TOuter,TInner,TKey,TResult>(IEnumerable<TOuter>, IEnumerable<TInner>, Func<TOuter,TKey>, Func<TInner,TKey>, Func<TOuter,IEnumerable<TInner>, TResult>)

キーが等しいかどうかに基づいて 2 つのシーケンスの要素を相互に関連付け、その結果をグループ化します。 キーの比較には既定の等値比較子が使用されます。

GroupJoin<TOuter,TInner,TKey,TResult>(IEnumerable<TOuter>, IEnumerable<TInner>, Func<TOuter,TKey>, Func<TInner,TKey>, Func<TOuter,IEnumerable<TInner>, TResult>, IEqualityComparer<TKey>)

キーが等しいかどうかに基づいて 2 つのシーケンスの要素を相互に関連付け、その結果をグループ化します。 指定された IEqualityComparer<T> を使用してキーを比較します。

Index<TSource>(IEnumerable<TSource>)

データ バインディングをサポートするジェネリック コレクションを提供します。

Intersect<TSource>(IEnumerable<TSource>, IEnumerable<TSource>)

既定の等値比較子を使用して値を比較することにより、2 つのシーケンスの積集合を生成します。

Intersect<TSource>(IEnumerable<TSource>, IEnumerable<TSource>, IEqualityComparer<TSource>)

指定された IEqualityComparer<T> を使用して値を比較することにより、2 つのシーケンスの積集合を生成します。

IntersectBy<TSource,TKey>(IEnumerable<TSource>, IEnumerable<TKey>, Func<TSource,TKey>)

指定したキー セレクター関数に従って、2 つのシーケンスの集合積集合を生成します。

IntersectBy<TSource,TKey>(IEnumerable<TSource>, IEnumerable<TKey>, Func<TSource,TKey>, IEqualityComparer<TKey>)

指定したキー セレクター関数に従って、2 つのシーケンスの集合積集合を生成します。

Join<TOuter,TInner,TKey,TResult>(IEnumerable<TOuter>, IEnumerable<TInner>, Func<TOuter,TKey>, Func<TInner,TKey>, Func<TOuter,TInner,TResult>)

一致するキーに基づいて 2 つのシーケンスの要素を相互に関連付けます。 キーの比較には既定の等値比較子が使用されます。

Join<TOuter,TInner,TKey,TResult>(IEnumerable<TOuter>, IEnumerable<TInner>, Func<TOuter,TKey>, Func<TInner,TKey>, Func<TOuter,TInner,TResult>, IEqualityComparer<TKey>)

一致するキーに基づいて 2 つのシーケンスの要素を相互に関連付けます。 指定された IEqualityComparer<T> を使用してキーを比較します。

Last<TSource>(IEnumerable<TSource>)

シーケンスの最後の要素を返します。

Last<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

指定された条件を満たす、シーケンスの最後の要素を返します。

LastOrDefault<TSource>(IEnumerable<TSource>)

シーケンスの最後の要素を返します。シーケンスに要素が含まれていない場合は既定値を返します。

LastOrDefault<TSource>(IEnumerable<TSource>, TSource)

シーケンスの最後の要素を返します。シーケンスに要素が含まれない場合は、指定した既定値を返します。

LastOrDefault<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

条件を満たす、シーケンスの最後の要素を返します。このような要素が見つからない場合は既定値を返します。

LastOrDefault<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>, TSource)

条件を満たすシーケンスの最後の要素、またはそのような要素が見つからない場合は、指定された既定値を返します。

LongCount<TSource>(IEnumerable<TSource>)

シーケンス内の要素の合計数を表す Int64 を返します。

LongCount<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

シーケンス内で条件を満たす要素の数を表す Int64 を返します。

Max<TSource>(IEnumerable<TSource>)

ジェネリック シーケンスの最大値を返します。

Max<TSource>(IEnumerable<TSource>, IComparer<TSource>)

ジェネリック シーケンスの最大値を返します。

Max<TSource>(IEnumerable<TSource>, Func<TSource,Decimal>)

シーケンスの各要素に対して変換関数を呼び出し、Decimal の最大値を返します。

Max<TSource>(IEnumerable<TSource>, Func<TSource,Double>)

シーケンスの各要素に対して変換関数を呼び出し、Double の最大値を返します。

Max<TSource>(IEnumerable<TSource>, Func<TSource,Int32>)

シーケンスの各要素に対して変換関数を呼び出し、Int32 の最大値を返します。

Max<TSource>(IEnumerable<TSource>, Func<TSource,Int64>)

シーケンスの各要素に対して変換関数を呼び出し、Int64 の最大値を返します。

Max<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Decimal>>)

シーケンスの各要素に対して変換関数を呼び出し、null 許容の Decimal の最大値を返します。

Max<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Double>>)

シーケンスの各要素に対して変換関数を呼び出し、null 許容の Double の最大値を返します。

Max<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int32>>)

シーケンスの各要素に対して変換関数を呼び出し、null 許容の Int32 の最大値を返します。

Max<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int64>>)

シーケンスの各要素に対して変換関数を呼び出し、null 許容の Int64 の最大値を返します。

Max<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Single>>)

シーケンスの各要素に対して変換関数を呼び出し、null 許容の Single の最大値を返します。

Max<TSource>(IEnumerable<TSource>, Func<TSource,Single>)

シーケンスの各要素に対して変換関数を呼び出し、Single の最大値を返します。

Max<TSource,TResult>(IEnumerable<TSource>, Func<TSource,TResult>)

ジェネリック シーケンスの各要素に対して変換関数を呼び出し、結果の最大値を返します。

MaxBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

指定したキー セレクター関数に従って、ジェネリック シーケンスの最大値を返します。

MaxBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IComparer<TKey>)

指定したキー セレクター関数とキー比較子に従って、ジェネリック シーケンスの最大値を返します。

Min<TSource>(IEnumerable<TSource>)

ジェネリック シーケンスの最小値を返します。

Min<TSource>(IEnumerable<TSource>, IComparer<TSource>)

ジェネリック シーケンスの最小値を返します。

Min<TSource>(IEnumerable<TSource>, Func<TSource,Decimal>)

シーケンスの各要素に対して変換関数を呼び出し、Decimal の最小値を返します。

Min<TSource>(IEnumerable<TSource>, Func<TSource,Double>)

シーケンスの各要素に対して変換関数を呼び出し、Double の最小値を返します。

Min<TSource>(IEnumerable<TSource>, Func<TSource,Int32>)

シーケンスの各要素に対して変換関数を呼び出し、Int32 の最小値を返します。

Min<TSource>(IEnumerable<TSource>, Func<TSource,Int64>)

シーケンスの各要素に対して変換関数を呼び出し、Int64 の最小値を返します。

Min<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Decimal>>)

シーケンスの各要素に対して変換関数を呼び出し、null 許容の Decimal の最小値を返します。

Min<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Double>>)

シーケンスの各要素に対して変換関数を呼び出し、null 許容の Double の最小値を返します。

Min<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int32>>)

シーケンスの各要素に対して変換関数を呼び出し、null 許容の Int32 の最小値を返します。

Min<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int64>>)

シーケンスの各要素に対して変換関数を呼び出し、null 許容の Int64 の最小値を返します。

Min<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Single>>)

シーケンスの各要素に対して変換関数を呼び出し、null 許容の Single の最小値を返します。

Min<TSource>(IEnumerable<TSource>, Func<TSource,Single>)

シーケンスの各要素に対して変換関数を呼び出し、Single の最小値を返します。

Min<TSource,TResult>(IEnumerable<TSource>, Func<TSource,TResult>)

ジェネリック シーケンスの各要素に対して変換関数を呼び出し、結果の最小値を返します。

MinBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

指定したキー セレクター関数に従って、ジェネリック シーケンスの最小値を返します。

MinBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IComparer<TKey>)

指定したキー セレクター関数とキー比較子に従って、ジェネリック シーケンスの最小値を返します。

OfType<TResult>(IEnumerable)

指定された型に基づいて IEnumerable の要素をフィルター処理します。

Order<T>(IEnumerable<T>)

シーケンスの要素を昇順に並べ替えます。

Order<T>(IEnumerable<T>, IComparer<T>)

シーケンスの要素を昇順に並べ替えます。

OrderBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

シーケンスの要素をキーに従って昇順に並べ替えます。

OrderBy<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IComparer<TKey>)

指定された比較子を使用してシーケンスの要素を昇順に並べ替えます。

OrderByDescending<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

シーケンスの要素をキーに従って降順に並べ替えます。

OrderByDescending<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IComparer<TKey>)

指定された比較子を使用してシーケンスの要素を降順に並べ替えます。

OrderDescending<T>(IEnumerable<T>)

シーケンスの要素を降順に並べ替えます。

OrderDescending<T>(IEnumerable<T>, IComparer<T>)

シーケンスの要素を降順に並べ替えます。

Prepend<TSource>(IEnumerable<TSource>, TSource)

シーケンスの先頭に値を追加します。

Reverse<TSource>(IEnumerable<TSource>)

シーケンスの要素の順序を反転させます。

Select<TSource,TResult>(IEnumerable<TSource>, Func<TSource,TResult>)

シーケンスの各要素を新しいフォームに射影します。

Select<TSource,TResult>(IEnumerable<TSource>, Func<TSource,Int32,TResult>)

要素のインデックスを組み込むことにより、シーケンスの各要素を新しいフォームに射影します。

SelectMany<TSource,TResult>(IEnumerable<TSource>, Func<TSource,IEnumerable<TResult>>)

シーケンスの各要素を IEnumerable<T> に射影し、結果のシーケンスを 1 つのシーケンスに平坦化します。

SelectMany<TSource,TResult>(IEnumerable<TSource>, Func<TSource,Int32,IEnumerable<TResult>>)

シーケンスの各要素を IEnumerable<T> に射影し、結果のシーケンスを 1 つのシーケンスに平坦化します。 各ソース要素のインデックスは、その要素の射影されたフォームで使用されます。

SelectMany<TSource,TCollection,TResult>(IEnumerable<TSource>, Func<TSource,IEnumerable<TCollection>>, Func<TSource,TCollection,TResult>)

シーケンスの各要素を IEnumerable<T> に射影し、結果のシーケンスを 1 つのシーケンスに平坦化して、その各要素に対して結果のセレクター関数を呼び出します。

SelectMany<TSource,TCollection,TResult>(IEnumerable<TSource>, Func<TSource,Int32,IEnumerable<TCollection>>, Func<TSource,TCollection,TResult>)

シーケンスの各要素を IEnumerable<T> に射影し、結果のシーケンスを 1 つのシーケンスに平坦化して、その各要素に対して結果のセレクター関数を呼び出します。 各ソース要素のインデックスは、その要素の中間の射影されたフォームで使用されます。

SequenceEqual<TSource>(IEnumerable<TSource>, IEnumerable<TSource>)

要素の型に対して既定の等値比較子を使用して要素を比較することで、2 つのシーケンスが等しいかどうかを判断します。

SequenceEqual<TSource>(IEnumerable<TSource>, IEnumerable<TSource>, IEqualityComparer<TSource>)

指定された IEqualityComparer<T> を使用して要素を比較することで、2 つのシーケンスが等しいかどうかを判断します。

Single<TSource>(IEnumerable<TSource>)

シーケンスの唯一の要素を返し、シーケンス内の要素が 1 つだけでない場合は例外をスローします。

Single<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

指定された条件を満たす、シーケンスの唯一の要素を返し、そのような要素が複数存在する場合は例外をスローします。

SingleOrDefault<TSource>(IEnumerable<TSource>)

シーケンスの唯一の要素を返します。シーケンスが空の場合、既定値を返します。シーケンス内に要素が複数ある場合、このメソッドは例外をスローします。

SingleOrDefault<TSource>(IEnumerable<TSource>, TSource)

シーケンスの唯一の要素を返します。シーケンスが空の場合は、指定した既定値を返します。シーケンス内に複数の要素がある場合、このメソッドは例外をスローします。

SingleOrDefault<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

指定された条件を満たすシーケンスの唯一の要素、またはそのような要素がない場合は既定値を返します。このメソッドは、複数の要素が条件を満たす場合に例外をスローします。

SingleOrDefault<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>, TSource)

指定した条件を満たすシーケンスの唯一の要素、またはそのような要素が存在しない場合は、指定された既定値を返します。このメソッドは、複数の要素が条件を満たす場合に例外をスローします。

Skip<TSource>(IEnumerable<TSource>, Int32)

シーケンス内の指定された数の要素をバイパスし、残りの要素を返します。

SkipLast<TSource>(IEnumerable<TSource>, Int32)

source の要素と、省略されたソース コレクションの最後の count 要素を含む、列挙可能な新しいコレクションを返します。

SkipWhile<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

指定された条件が満たされる限り、シーケンスの要素をバイパスした後、残りの要素を返します。

SkipWhile<TSource>(IEnumerable<TSource>, Func<TSource,Int32,Boolean>)

指定された条件が満たされる限り、シーケンスの要素をバイパスした後、残りの要素を返します。 要素のインデックスは、述語関数のロジックで使用されます。

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Decimal>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する Decimal 値のシーケンスの合計を計算します。

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Double>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する Double 値のシーケンスの合計を計算します。

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Int32>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する Int32 値のシーケンスの合計を計算します。

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Int64>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する Int64 値のシーケンスの合計を計算します。

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Decimal>>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する null 許容の Decimal 値のシーケンスの合計を計算します。

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Double>>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する null 許容の Double 値のシーケンスの合計を計算します。

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int32>>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する null 許容の Int32 値のシーケンスの合計を計算します。

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Int64>>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する null 許容の Int64 値のシーケンスの合計を計算します。

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Nullable<Single>>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する null 許容の Single 値のシーケンスの合計を計算します。

Sum<TSource>(IEnumerable<TSource>, Func<TSource,Single>)

入力シーケンスの各要素に対して変換関数を呼び出して取得する Single 値のシーケンスの合計を計算します。

Take<TSource>(IEnumerable<TSource>, Int32)

シーケンスの先頭から、指定された数の連続する要素を返します。

Take<TSource>(IEnumerable<TSource>, Range)

シーケンスから指定した連続する要素の範囲を返します。

TakeLast<TSource>(IEnumerable<TSource>, Int32)

source の最後の count 要素を含む、列挙可能な新しいコレクションを返します。

TakeWhile<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

指定された条件が満たされる限り、シーケンスから要素を返します。

TakeWhile<TSource>(IEnumerable<TSource>, Func<TSource,Int32,Boolean>)

指定された条件が満たされる限り、シーケンスから要素を返します。 要素のインデックスは、述語関数のロジックで使用されます。

ToArray<TSource>(IEnumerable<TSource>)

IEnumerable<T> から配列を作成します。

ToDictionary<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

指定されたキー セレクター関数に従って、Dictionary<TKey,TValue> から IEnumerable<T> を作成します。

ToDictionary<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)

指定されたキー セレクター関数およびキーの比較子に従って、Dictionary<TKey,TValue> から IEnumerable<T> を作成します。

ToDictionary<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>)

指定されたキー セレクター関数および要素セレクター関数に従って、Dictionary<TKey,TValue> から IEnumerable<T> を作成します。

ToDictionary<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>, IEqualityComparer<TKey>)

指定されたキー セレクター関数、比較子、および要素セレクター関数に従って、Dictionary<TKey,TValue> から IEnumerable<T> を作成します。

ToHashSet<TSource>(IEnumerable<TSource>)

IEnumerable<T> から HashSet<T> を作成します。

ToHashSet<TSource>(IEnumerable<TSource>, IEqualityComparer<TSource>)

comparer を使用して IEnumerable<T>から HashSet<T> を作成し、キーを比較します。

ToList<TSource>(IEnumerable<TSource>)

IEnumerable<T> から List<T> を作成します。

ToLookup<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>)

指定されたキー セレクター関数に従って、Lookup<TKey,TElement> から IEnumerable<T> を作成します。

ToLookup<TSource,TKey>(IEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)

指定されたキー セレクター関数およびキーの比較子に従って、Lookup<TKey,TElement> から IEnumerable<T> を作成します。

ToLookup<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>)

指定されたキー セレクター関数および要素セレクター関数に従って、Lookup<TKey,TElement> から IEnumerable<T> を作成します。

ToLookup<TSource,TKey,TElement>(IEnumerable<TSource>, Func<TSource,TKey>, Func<TSource,TElement>, IEqualityComparer<TKey>)

指定されたキー セレクター関数、比較子、および要素セレクター関数に従って、Lookup<TKey,TElement> から IEnumerable<T> を作成します。

TryGetNonEnumeratedCount<TSource>(IEnumerable<TSource>, Int32)

列挙型を強制せずに、シーケンス内の要素の数の測定を試みます。

Union<TSource>(IEnumerable<TSource>, IEnumerable<TSource>)

既定の等値比較子を使用して、2 つのシーケンスの和集合を生成します。

Union<TSource>(IEnumerable<TSource>, IEnumerable<TSource>, IEqualityComparer<TSource>)

指定された IEqualityComparer<T> を使用して 2 つのシーケンスの和集合を生成します。

UnionBy<TSource,TKey>(IEnumerable<TSource>, IEnumerable<TSource>, Func<TSource,TKey>)

指定したキー セレクター関数に従って、2 つのシーケンスのセット和集合を生成します。

UnionBy<TSource,TKey>(IEnumerable<TSource>, IEnumerable<TSource>, Func<TSource,TKey>, IEqualityComparer<TKey>)

指定したキー セレクター関数に従って、2 つのシーケンスのセット和集合を生成します。

Where<TSource>(IEnumerable<TSource>, Func<TSource,Boolean>)

述語に基づいて値のシーケンスをフィルター処理します。

Where<TSource>(IEnumerable<TSource>, Func<TSource,Int32,Boolean>)

述語に基づいて値のシーケンスをフィルター処理します。 各要素のインデックスは、述語関数のロジックで使用されます。

Zip<TFirst,TSecond>(IEnumerable<TFirst>, IEnumerable<TSecond>)

指定された 2 つのシーケンスの要素を持つタプルのシーケンスを生成します。

Zip<TFirst,TSecond,TThird>(IEnumerable<TFirst>, IEnumerable<TSecond>, IEnumerable<TThird>)

指定した 3 つのシーケンスの要素を含むタプルのシーケンスを生成します。

Zip<TFirst,TSecond,TResult>(IEnumerable<TFirst>, IEnumerable<TSecond>, Func<TFirst,TSecond,TResult>)

2 つのシーケンスの対応する要素に対して、1 つの指定した関数を適用し、結果として 1 つのシーケンスを生成します。

AsParallel(IEnumerable)

クエリの並列化を有効にします。

AsParallel<TSource>(IEnumerable<TSource>)

クエリの並列化を有効にします。

AsQueryable(IEnumerable)

IEnumerableIQueryable に変換します。

AsQueryable<TElement>(IEnumerable<TElement>)

ジェネリックの IEnumerable<T> をジェネリックの IQueryable<T> に変換します。

Ancestors<T>(IEnumerable<T>)

ソース コレクション内のすべてのノードの先祖が格納された、要素のコレクションを返します。

Ancestors<T>(IEnumerable<T>, XName)

ソース コレクション内のすべてのノードの先祖が格納され、フィルター処理された要素のコレクションを返します。 一致する XName を持つ要素のみがコレクションに含められます。

DescendantNodes<T>(IEnumerable<T>)

ソース コレクション内のすべてのドキュメントおよび要素の子孫ノードのコレクションを返します。

Descendants<T>(IEnumerable<T>)

ソース コレクション内のすべての要素とドキュメントの子孫要素が格納された要素のコレクションを返します。

Descendants<T>(IEnumerable<T>, XName)

ソース コレクション内のすべての要素とドキュメントの子孫要素が格納され、フィルター処理された要素のコレクションを返します。 一致する XName を持つ要素のみがコレクションに含められます。

Elements<T>(IEnumerable<T>)

ソース コレクション内のすべての要素およびドキュメントの子要素のコレクションを返します。

Elements<T>(IEnumerable<T>, XName)

ソース コレクション内のすべての要素およびドキュメントの、フィルター処理された子要素のコレクションを返します。 一致する XName を持つ要素のみがコレクションに含められます。

InDocumentOrder<T>(IEnumerable<T>)

ソース コレクション内のすべてのノードがドキュメント順に並べ替えて格納された、ノードのコレクションを返します。

Nodes<T>(IEnumerable<T>)

ソース コレクション内のすべてのドキュメントおよび要素の子ノードのコレクションを返します。

Remove<T>(IEnumerable<T>)

ソース コレクション内の親ノードからすべてのノードを削除します。

適用対象

こちらもご覧ください