public RequestBuilder Handler(string file, string provider, int fileNumber) { ObjectAdapter adapter = FileAdapter.Csv(file); IEnumerable <ValidationRecordCsv> records = adapter.Records <ValidationRecordCsv>(true); if (records.Any(r => !r.IsValid)) { return(new BadRequstBuilder(file, records.Where(r => !r.IsValid))); } return(new ValidationRequestBuilder(file, records.Where(r => r.IsValid), provider, fileNumber, 10000)); }