From b579b33ae16a58e311a75967e2f5e735a9fc9bca Mon Sep 17 00:00:00 2001 From: Railz Date: Fri, 1 Mar 2019 09:36:24 +0100 Subject: [PATCH] Commented constructor --- ManagedPool/Pool_T_.cs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/ManagedPool/Pool_T_.cs b/ManagedPool/Pool_T_.cs index d26e248..6dab2f6 100644 --- a/ManagedPool/Pool_T_.cs +++ b/ManagedPool/Pool_T_.cs @@ -72,6 +72,18 @@ namespace eu.railduction.netcore.dll.ManagedPool Task.Run(() => createNewObjects(min)); } + /// + /// Creates a managed pool + /// Will automatically spawn items + /// Will check health of items with method + /// + /// The minimum amount of items in the pool + /// The maximum amount of items in the pool + /// Amount if items being spawned at a time if needed + /// If less items are in the pool than the , it will spawn -amount + /// If more items are in the pool than the , it will delete/kill the overflowing items + /// Method to handle item-spawning (needs to return the item-type) + /// Method to handle item-deleting/killing (needs to take the item-type as parameter) /// Method to handle item-health-checking (useful for unstable items) /// While running the health-check, the Thread will be blocked! public Pool(int min, int max, int batch, int increaseBuffer, int decreaseBuffer, Func creator, Action destructor, Func healthChecker)