Пример #1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="NetSuiteServicePoolManager"/> class.
        /// </summary>
        /// <param name="factoryMethod">The factory method to be invoked when generating ServiceManagers for the current pool.</param>
        public NetSuiteServicePoolManager(Func <IServiceManager> factoryMethod)
        {
            ServiceConfiguration = new NetSuiteServiceConfiguration();
            Credentials          = new List <NetSuiteCredential>(1);

            _factoryMethod = factoryMethod;
        }
Пример #2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="NetSuiteServiceManager"/> class.
        /// </summary>
        /// <param name="service">The service proxy object.</param>
        /// <param name="logger">The logger to be used by the Service Manager.</param>
        public NetSuiteServiceManager(INetSuiteService service, ILogger logger)
        {
            ServiceProxy  = service;
            Configuration = new NetSuiteServiceConfiguration();

            if (logger != null)
            {
                _log = logger;
            }
            else
            {
                _log = new NullLogger();
            }
        }