public RuntimeContext(IStorage storage, INetwork network, Git.ITrace trace, Git.IUtilities utilities, Git.IWhere where)
            : this()
        {
            if (storage is null)
            {
                throw new ArgumentNullException(nameof(storage));
            }
            if (network is null)
            {
                throw new ArgumentNullException(nameof(network));
            }
            if (trace is null)
            {
                throw new ArgumentNullException(nameof(trace));
            }
            if (utilities is null)
            {
                throw new ArgumentNullException(nameof(utilities));
            }
            if (where is null)
            {
                throw new ArgumentNullException(nameof(where));
            }

            _network   = network;
            _storage   = storage;
            _trace     = trace;
            _utilities = utilities;
            _where     = where;
        }
예제 #2
0
        public RuntimeContext(INetwork network, ISettings settings, IStorage storage, Git.ITrace trace, Git.IUtilities utilities, Git.IWhere where)
            : this()
        {
            if (network is null)
            {
                throw new ArgumentNullException(nameof(network));
            }
            if (settings is null)
            {
                throw new ArgumentNullException(nameof(settings));
            }
            if (storage is null)
            {
                throw new ArgumentNullException(nameof(storage));
            }
            if (trace is null)
            {
                throw new ArgumentNullException(nameof(trace));
            }
            if (utilities is null)
            {
                throw new ArgumentNullException(nameof(utilities));
            }
            if (where is null)
            {
                throw new ArgumentNullException(nameof(where));
            }

            SetService(network);
            SetService(settings);
            SetService(storage);
            SetService(trace);
            SetService(utilities);
            SetService(where);
        }