Here are the examples of the csharp api System.Collections.Generic.IEnumerable.Contains(UnitFamily) taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.
1 Examples
19
Source : DBEntryUnit.cs
with GNU General Public License v3.0
from akaAgar
with GNU General Public License v3.0
from akaAgar
internal bool IsValidForFamilyCountryAndPeriod(UnitFamily family, Country[] countries, Decade decade)
{
// Unit does not belong to the required family
if (!Families.Contains(family)) return false;
foreach (Country country in countries)
{
if (!Operators.ContainsKey(country)) continue;
if ((Operators[country][0] <= decade) && (Operators[country][1] >= decade))
return true; // Found one operator operating the unit during the required decade
}
return false;
}