Example #1
0
        public IUnitOfWork GetUnitOfWork()
        {
            var connection = _args.ConnectionString ?? ConfigurationManager.ConnectionStrings[_args.ConnectionName].ConnectionString;

            Affirm.NotNullOrEmpty(connection, "Connection string can not be null or empty!");

            return(GetUnitOfWork(connection));
        }
Example #2
0
        public PackageProcessor(ISourceSchema schema, ILog log, ISqlBuilder sqlBuilder, IFileService fileService, IAppArgs args)
        {
            Affirm.ArgumentNotNull(schema, "schema");
            Affirm.ArgumentNotNull(log, "log");
            Affirm.ArgumentNotNull(sqlBuilder, "sqlBuilder");
            Affirm.ArgumentNotNull(fileService, "fileService");
            Affirm.ArgumentNotNull(args, "args");

            _schema      = schema;
            _sqlBuilder  = sqlBuilder;
            _fileService = fileService;
            _log         = log;
            _args        = args;
        }
Example #3
0
        public IUnitOfWork GetUnitOfWork(string source)
        {
            Affirm.NotNullOrEmpty(source, "source");

            return(new UnitOfWork(source));
        }
Example #4
0
        public UnitOfWorkFactory(IAppArgs args)
        {
            Affirm.ArgumentNotNull(args, "args");

            _args = args;
        }