Skip to content

Instantly share code, notes, and snippets.

@ssukhpinder
Created June 12, 2021 07:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ssukhpinder/48e89a9971e31f5c0527857229dbdd02 to your computer and use it in GitHub Desktop.
Save ssukhpinder/48e89a9971e31f5c0527857229dbdd02 to your computer and use it in GitHub Desktop.
public class Manager : ClaimApprover
{
public override void ApproveRequest(Claim claim)
{
if (claim.amount >= 100 && claim.amount <= 1000)
{
System.Console.WriteLine($"Claim reference {claim.Id} with amount {claim.amount} is approved by Manager");
}
else if (claimApprover != null)
{
claimApprover.ApproveRequest(claim);
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment