//custom constructor private Notification(NotificationType type, TradeMatch tradeMatch) { if (tradeMatch == null) { throw new ArgumentNullException("tradeSummary"); } Type = type; TradeMatch = tradeMatch; DateTime = DateTime.Now; }
public static Notification TradeSummaryCompleted(TradeMatch tradeMatch) { return(new Notification(NotificationType.TradeSummaryCompleted, tradeMatch)); }
public static Notification TradeSummaryIsPaid(TradeMatch tradeMatch) { return(new Notification(NotificationType.PaymentCompleted, tradeMatch)); }