Absorb pocketmine/classloader into the core code

the only use for this class is to facilitate random runtime plugin loading, and it's not complete even for that purpose.

Since nothing but PM uses pocketmine/classloader anyway, it doesn't make sense to have it outside the core. As with LogPthreads, it's just adding more maintenance work.
This commit is contained in:
Dylan K. Taylor
2023-05-22 22:52:43 +01:00
parent d2c34615f5
commit 4aba9d9725
9 changed files with 199 additions and 60 deletions

View File

@ -28,6 +28,7 @@ use pmmp\thread\ThreadSafeArray;
use pocketmine\snooze\SleeperHandler;
use pocketmine\snooze\SleeperNotifier;
use pocketmine\thread\log\ThreadSafeLogger;
use pocketmine\thread\ThreadSafeClassLoader;
use pocketmine\utils\Utils;
use function array_keys;
use function array_map;
@ -70,7 +71,7 @@ class AsyncPool{
public function __construct(
protected int $size,
private int $workerMemoryLimit,
private \ClassLoader $classLoader,
private ThreadSafeClassLoader $classLoader,
private ThreadSafeLogger $logger,
private SleeperHandler $eventLoop
){}