private RedeemerOchestrator(IRedeemer redeemer) { RegisteredRedeemers = new List <IRedeemer>() { redeemer }; }
public RedeemerOchestrator With(IRedeemer redeemer) { if (RegisteredRedeemers.Any(x => x.RedemptionType == redeemer.RedemptionType)) { throw new Exception("This type of redemption has already been registered"); } RegisteredRedeemers.Add(redeemer); return(this); }
public static RedeemerOchestrator CreateWith(IRedeemer redeemer) { return(new RedeemerOchestrator(redeemer)); }