Modernize private property declarations in src/network

This commit is contained in:
Dylan K. Taylor
2022-05-17 21:22:33 +01:00
parent cd016bedce
commit 6eac2ea7a5
31 changed files with 154 additions and 340 deletions

View File

@ -79,23 +79,16 @@ class ChunkCache implements ChunkListener{
}
}
/** @var World */
private $world;
/** @var Compressor */
private $compressor;
/** @var CompressBatchPromise[] */
private $caches = [];
private array $caches = [];
/** @var int */
private $hits = 0;
/** @var int */
private $misses = 0;
private int $hits = 0;
private int $misses = 0;
private function __construct(World $world, Compressor $compressor){
$this->world = $world;
$this->compressor = $compressor;
}
private function __construct(
private World $world,
private Compressor $compressor
){}
/**
* Requests asynchronous preparation of the chunk at the given coordinates.