コード例 #1
0
        public SessionsFactory(IDbConnectionsFactory dbConnectionsFactory)
        {
            if (dbConnectionsFactory == null)
            {
                throw new ArgumentNullException(nameof(dbConnectionsFactory));
            }

            _dbConnectionsFactory = dbConnectionsFactory;
        }
        protected BaseDbQuery(IDbConnectionsFactory connectionsFactory, IOptions <SqlExecutionOptions> executionOptions)
        {
            if (connectionsFactory == null)
            {
                throw new ArgumentNullException(nameof(connectionsFactory));
            }
            if (executionOptions == null)
            {
                throw new ArgumentNullException(nameof(executionOptions));
            }

            ConnectionsFactory  = connectionsFactory;
            SqlExecutionOptions = executionOptions.Value;
        }