Example #1
0
        /// <summary>
        /// Adds a pool to the factory.
        /// </summary>
        /// <typeparam name="TPooled">The pooled item</typeparam>
        /// <param name="pool">The pool.</param>
        /// <param name="configuration">The configuration.</param>
        private void AddPool <TPooled>(PoolBaseOfT <TPooled> pool, PoolConfiguration configuration)
            where TPooled : class
        {
            PoolLookup <TPooled> .Init(pool);

            this.pools.Add(pool);
            pool.Initialize(configuration);
        }
Example #2
0
 public static void Init(PoolBaseOfT <TPooled> objectPool)
 {
     pool = objectPool;
 }