ImmutableSortedSet<T>.IsSubsetOf(IEnumerable<T>) 方法

定义

确定当前不可变排序集是否为指定集合的子集。Determines whether the current immutable sorted set is a subset of a specified collection.

public:
 virtual bool IsSubsetOf(System::Collections::Generic::IEnumerable<T> ^ other);
public bool IsSubsetOf (System.Collections.Generic.IEnumerable<T> other);
abstract member IsSubsetOf : seq<'T> -> bool
override this.IsSubsetOf : seq<'T> -> bool
Public Function IsSubsetOf (other As IEnumerable(Of T)) As Boolean

参数

other
IEnumerable<T>

要与当前集进行比较的集合。The collection to compare to the current set.

返回

如果当前集是 true 的子集,则为 other;否则为 falsetrue if the current set is a subset of other; otherwise, false.

实现

注解

空集是其他任何集(包括另一个空集)的子集。An empty set is a subset of any other set, including another empty set. 因此,如果当前集为空,则此方法返回 true (即使 other 集合也为空)。Therefore, this method returns true if the current set is empty, even if the other collection is also empty.

System.object NuGet 包System.Collections.Immutable NuGet package

关于不可变集合以及如何安装About immutable collections and how to install

适用于