protected PaySession(PaySystem paySystem, PayConnectionParameters cParams) { if (paySystem == null || cParams == null) { throw new PaymentException(StringConsts.ARGUMENT_ERROR + this.GetType().Name + ".ctor(paySystem is not null and cParams is not null)"); } m_PaySystem = paySystem; m_Name = cParams.Name; m_User = cParams.User; lock (m_PaySystem.m_Sessions) m_PaySystem.m_Sessions.Add(this); }
protected abstract PaySession DoStartSession(PayConnectionParameters cParams = null);
/// <summary> /// Starts new pay session of system-specific type /// </summary> public PaySession StartSession(PayConnectionParameters cParams = null) { return(DoStartSession(cParams)); }