28 private float $amount,
29 private int $operation,
31 private bool $serializable
34 public function getId() : string{ return $this->id; }
36 public function getName() : string{ return $this->name; }
38 public function getAmount() : float{ return $this->amount; }
40 public function getOperation() : int{ return $this->operation; }
42 public function getOperand() : int{ return $this->operand; }
44 public function isSerializable() : bool{ return $this->serializable; }
46 public static function read(PacketSerializer $in) : self{
47 $id = $in->getString();
48 $name = $in->getString();
49 $amount = $in->getLFloat();
50 $operation = $in->getLInt();
51 $operand = $in->getLInt();
52 $serializable = $in->getBool();
54 return new self($id, $name, $amount, $operation, $operand, $serializable);
57 public function write(PacketSerializer $out) : void{
58 $out->putString($this->id);
59 $out->putString($this->name);
60 $out->putLFloat($this->amount);
61 $out->putLInt($this->operation);
62 $out->putLInt($this->operand);
63 $out->putBool($this->serializable);