public double CalculateBonus(Personnel personnel)
        {
            double bonusRate = 0.0D;

            switch (personnel.PersonnelType)
            {
            case Personnel.PersonnelTypes.FullTime:
                bonusRate = 0.15D;
                break;

            // new
            case Personnel.PersonnelTypes.Temporary:
                bonusRate = 0.10D;
                break;

            default:
                break;
            }

            // processing here
            return(personnel.AnnualSalary * bonusRate);
        }
예제 #2
0
 public void GenerateTimeEntryReport(Personnel personnel)
 {
     // processing here
     emailSender.SendNotification($"{ReportName}: Report created.");
 }
 public double GetHourlyRate(Personnel personnel)
 {
     return(personnel.AnnualSalary / (40 * 52));
 }
 public DateTime GetPaySchedule(Personnel personnel)
 {
     return(personnel.PaySchedule);
 }
예제 #5
0
 public void PersistPersonnelUpdates(Personnel personnel)
 {
     logger.Log($"Personnel information updated.");
     // processing here
     emailSender.SendNotification("Personnel information updated.");
 }
예제 #6
0
 public void RegisterPersonnel(Personnel personnel)
 {
     logger.Log($"New personnel information created.");
     // processing here
     emailSender.SendNotification("New personnel information created.");
 }