Esempio n. 1
0
        internal Service(Namespace @namespace, ServiceAddress addr, ServiceBehaviour behaviour, ServiceConfiguration configuration)
        {
            if (configuration == null)
            {
                throw new ArgumentNullException(nameof(configuration));
            }

            _behaviour     = behaviour ?? throw new ArgumentNullException(nameof(behaviour));
            _addr          = addr;
            _configuration = configuration;
            _namespace     = @namespace ?? throw new ArgumentNullException(nameof(@namespace));
        }
Esempio n. 2
0
        internal Service(Node node, Broker broker, ServiceAddress addr, ServiceBehaviour behaviour, ServiceConfiguration configuration)
        {
            if (configuration == null)
            {
                throw new ArgumentNullException(nameof(configuration));
            }

            _node          = node ?? throw new ArgumentNullException(nameof(node));
            _broker        = broker ?? throw new ArgumentNullException(nameof(broker));
            _behaviour     = behaviour ?? throw new ArgumentNullException(nameof(behaviour));
            _addr          = addr;
            _configuration = configuration;
        }