Моя идея будет такой:
Код: Выделить всё
public class PositiveInt : IReadOnlySet
{
public bool Contains(Int32 n){
return n > 0;
}
}
public class CraEmployeeNames:IReadOnlySet
{
public bool Contains(String n){
return !String.IsNullOrWhiteSpace(n) && n.StartsWith("Cra");
}
}
Подробнее здесь: https://stackoverflow.com/questions/236 ... -interface
Мобильная версия