Exemple #1
0
 private static void PrintEmployee(Employee employee, FormatDimensions formatDimensions)
 {
     Console.WriteLine(formatDimensions.ToFormatString(),
         employee.FullName,
         employee.Position,
         employee.SeparationDateToString);
 }
Exemple #2
0
        private static void PrintResult(IEnumerable<Employee> employees)
        {
            var formatDimensions = new FormatDimensions(employees);

            PrintHeader(formatDimensions);
            foreach (var employee in employees)
            {
                PrintEmployee(employee, formatDimensions);
            }
        }
Exemple #3
0
 private static void PrintHeader(FormatDimensions formatDimensions)
 {
     Console.WriteLine(formatDimensions.ToFormatString(), "Name", "Position", "Separation Date");
     Console.WriteLine(String.Empty.PadRight(formatDimensions.TotalWidth(), '-'));
 }