Пример #1
0
 public void RegistClassType(string className, IPoolableFactory factory)
 {
     if (this.m_data.ContainsKey(className))
     {
         throw new ClassExistsException(className);
     }
     this.m_data.Add(className, factory);
 }
Пример #2
0
        public PoolExpander(List <Poolable <T> > pooledObjects, int expandAmount, int instantiatedPerFrame, IPoolableFactory <T> poolableFactory)
        {
            Assert.IsNotNull(pooledObjects);
            Assert.IsTrue(expandAmount > 0);
            Assert.IsTrue(instantiatedPerFrame > 0);
            Assert.IsNotNull(poolableFactory);

            this.pooledObjects        = pooledObjects;
            this.expandAmount         = expandAmount;
            this.instantiatedPerFrame = instantiatedPerFrame;
            this.poolableFactory      = poolableFactory;
        }
Пример #3
0
		public void RegistClassType(string className, IPoolableFactory factory)
		{
			if (this.m_data.ContainsKey(className))
				throw new ClassExistsException(className);
			this.m_data.Add(className, factory);
		}