Commented constructor
This commit is contained in:
		
							parent
							
								
									cb07a36597
								
							
						
					
					
						commit
						b579b33ae1
					
				@ -72,6 +72,18 @@ namespace eu.railduction.netcore.dll.ManagedPool
 | 
				
			|||||||
            Task.Run(() => createNewObjects(min));
 | 
					            Task.Run(() => createNewObjects(min));
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        /// <summary>
 | 
				
			||||||
 | 
					        /// Creates a managed pool<para/>
 | 
				
			||||||
 | 
					        /// Will automatically spawn <paramref name="min"/> items<para/>
 | 
				
			||||||
 | 
					        /// Will check health of items with method <paramref name="healthChecker"/>
 | 
				
			||||||
 | 
					        /// </summary>
 | 
				
			||||||
 | 
					        /// <param name="min">The minimum amount of items in the pool</param>
 | 
				
			||||||
 | 
					        /// <param name="max">The maximum amount of items in the pool</param>
 | 
				
			||||||
 | 
					        /// <param name="batch">Amount if items being spawned at a time if needed</param>
 | 
				
			||||||
 | 
					        /// <param name="increaseBuffer">If less items are in the pool than the <paramref name="increaseBuffer"/>, it will spawn <paramref name="batch"/>-amount</param>
 | 
				
			||||||
 | 
					        /// <param name="decreaseBuffer">If more items are in the pool than the <paramref name="decreaseBuffer"/>, it will delete/kill the overflowing items</param>
 | 
				
			||||||
 | 
					        /// <param name="creator">Method to handle item-spawning (needs to return the item-type)</param>
 | 
				
			||||||
 | 
					        /// <param name="destructor">Method to handle item-deleting/killing (needs to take the item-type as parameter)</param>
 | 
				
			||||||
        /// <param name="healthChecker">Method to handle item-health-checking (useful for unstable items)
 | 
					        /// <param name="healthChecker">Method to handle item-health-checking (useful for unstable items)
 | 
				
			||||||
        /// <para/>While running the health-check, the Thread will be blocked!</param>
 | 
					        /// <para/>While running the health-check, the Thread will be blocked!</param>
 | 
				
			||||||
        public Pool(int min, int max, int batch, int increaseBuffer, int decreaseBuffer, Func<T> creator, Action<T> destructor, Func<T, bool> healthChecker)
 | 
					        public Pool(int min, int max, int batch, int increaseBuffer, int decreaseBuffer, Func<T> creator, Action<T> destructor, Func<T, bool> healthChecker)
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user