我需要在enum DaysOfTheWeek
过滤后的值中找到List<int> daysId
并返回过滤后的枚举
我的枚举:
[Flags]
public enum DaysOfTheWeek
{
Sunday = 1,
Monday = 2,
Tuesday = 4,
Wednesday = 8,
Thursday = 16,
Friday = 32,
Saturday = 64,
AllDays = 127,
}
-
var allValues = Enum.GetValues(typeof(DaysOfTheWeek));
我的整数列表:
List<int> daysId = new List<int> {1,3};