コード例 #1
0
        /// <summary>
        /// Add Configuration Adaptor
        /// </summary>
        /// <param name="adaptor">Adaptor</param>
        public void Add(IConfigurationAdaptor adaptor)
        {
            Contract.Requires(null != adaptor);

            lock (this.adaptorLock)
            {
                this.orderedAdaptors.Add(new ConfigurationAdaptorOrder(adaptor, this.orderedAdaptors.Count));
            }
        }
コード例 #2
0
 /// <summary>
 /// Initializes a new instance of the ConfigurationAdaptorOrder class
 /// </summary>
 /// <param name="adaptor">Adaptor</param>
 /// <param name="order">Order</param>
 public ConfigurationAdaptorOrder(IConfigurationAdaptor adaptor, int order)
 {
     if (null == adaptor)
     {
         throw new ArgumentNullException("adaptor");
     }
     else if (0 > order)
     {
         throw new ArgumentOutOfRangeException("order");
     }
     else
     {
         this.adaptor = adaptor;
         this.order   = order;
     }
 }