PocketMine-MP 5.33.2 git-919492bdcad8510eb6606439eb77e1c604f1d1ea
Loading...
Searching...
No Matches
pocketmine\data\runtime\RuntimeDataWriter Class Reference
+ Inheritance diagram for pocketmine\data\runtime\RuntimeDataWriter:
+ Collaboration diagram for pocketmine\data\runtime\RuntimeDataWriter:

Public Member Functions

 __construct (private int $maxBits)
 
 bool (bool &$value)
 
 boundedIntAuto (int $min, int $max, int &$value)
 
 enum (\UnitEnum &$case)
 
 enumSet (array &$set, array $allCases)
 
 facingExcept (Facing &$facing, Facing $except)
 
 getOffset ()
 
 getValue ()
 
 horizontalAxis (Axis &$axis)
 
 int (int $bits, int &$value)
 
 wallConnections (array &$connections)
 
 writeInt (int $bits, int $value)
 

Protected Member Functions

 writeBool (bool $value)
 

Detailed Description

Definition at line 32 of file RuntimeDataWriter.php.

Constructor & Destructor Documentation

◆ __construct()

pocketmine\data\runtime\RuntimeDataWriter::__construct ( private int $maxBits)

Definition at line 36 of file RuntimeDataWriter.php.

Member Function Documentation

◆ bool()

pocketmine\data\runtime\RuntimeDataWriter::bool ( bool & $value)

◆ boundedIntAuto()

pocketmine\data\runtime\RuntimeDataWriter::boundedIntAuto ( int $min,
int $max,
int & $value )

Same as boundedInt() but automatically calculates the required number of bits from the range. The range bounds must be constant.

Implements pocketmine\data\runtime\RuntimeDataDescriber.

Definition at line 64 of file RuntimeDataWriter.php.

◆ enum()

pocketmine\data\runtime\RuntimeDataWriter::enum ( \UnitEnum & $case)

@phpstan-template T of \UnitEnum @phpstan-param T &$case @phpstan-param-out T $case

Implements pocketmine\data\runtime\RuntimeDataDescriber.

Definition at line 106 of file RuntimeDataWriter.php.

◆ enumSet()

pocketmine\data\runtime\RuntimeDataWriter::enumSet ( array & $set,
array $allCases )
Parameters
\UnitEnum[]&$set
\UnitEnum[]$allCases

@phpstan-template T of \UnitEnum @phpstan-param array<int, T> &$set @phpstan-param array<int, T> $allCases

Implements pocketmine\data\runtime\RuntimeDataDescriber.

Definition at line 111 of file RuntimeDataWriter.php.

◆ facingExcept()

pocketmine\data\runtime\RuntimeDataWriter::facingExcept ( Facing & $facing,
Facing $except )

◆ getOffset()

pocketmine\data\runtime\RuntimeDataWriter::getOffset ( )

Definition at line 119 of file RuntimeDataWriter.php.

◆ getValue()

pocketmine\data\runtime\RuntimeDataWriter::getValue ( )

Definition at line 117 of file RuntimeDataWriter.php.

◆ horizontalAxis()

pocketmine\data\runtime\RuntimeDataWriter::horizontalAxis ( Axis & $axis)

◆ int()

pocketmine\data\runtime\RuntimeDataWriter::int ( int $bits,
int & $value )

◆ wallConnections()

pocketmine\data\runtime\RuntimeDataWriter::wallConnections ( array & $connections)
Parameters
WallConnectionType[]$connections@phpstan-param array<value-of<Facing::NORTH|Facing::EAST|Facing::SOUTH|Facing::WEST>, WallConnectionType> $connections

Implements pocketmine\data\runtime\RuntimeDataDescriber.

Definition at line 92 of file RuntimeDataWriter.php.

◆ writeBool()

pocketmine\data\runtime\RuntimeDataWriter::writeBool ( bool $value)
protected

Definition at line 68 of file RuntimeDataWriter.php.

◆ writeInt()

pocketmine\data\runtime\RuntimeDataWriter::writeInt ( int $bits,
int $value )

Definition at line 40 of file RuntimeDataWriter.php.


The documentation for this class was generated from the following file: