Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ IsProperSubsetOf()

bool System.Collections.Immutable.ImmutableSortedSet< T >.IsProperSubsetOf ( IEnumerable< T > other)
inline

Implements System.Collections.Immutable.IImmutableSet< T >.

Definition at line 1159 of file ImmutableSortedSet.cs.

1160 {
1161 Requires.NotNull(other, "other");
1162 if (IsEmpty)
1163 {
1164 return other.Any();
1165 }
1167 if (Count >= sortedSet.Count)
1168 {
1169 return false;
1170 }
1171 int num = 0;
1172 bool flag = false;
1173 foreach (T item in sortedSet)
1174 {
1175 if (Contains(item))
1176 {
1177 num++;
1178 }
1179 else
1180 {
1181 flag = true;
1182 }
1183 if (num == Count && flag)
1184 {
1185 return true;
1186 }
1187 }
1188 return false;
1189 }

References System.Collections.Immutable.ImmutableSortedSet< T >.Contains(), System.Collections.Immutable.ImmutableSortedSet< T >.Count, System.Collections.Generic.Dictionary< TKey, TValue >.Count, System.Collections.Immutable.ImmutableSortedSet< T >.IsEmpty, System.item, System.Collections.Immutable.ImmutableSortedSet< T >.KeyComparer, and System.other.