public static ICollection <AbstractSearch> AddCustomSearchCriteria <T>(this ICollection <AbstractSearch> searchCriterias, Expression <Func <T, object> > property) { Type propertyType = null; string fullPropertyPath = GetPropertyPath(property, out propertyType); AbstractSearch searchCriteria = CreateSearchCriteria(propertyType, fullPropertyPath); if (searchCriteria != null) { searchCriterias.Add(searchCriteria); } return(searchCriterias); }