25 public function __construct(
26 private string $displayName,
27 private string $entity,
28 private int $timeInNS,
29 private int $percentOfTotal,
32 public function getDisplayName() :
string{
return $this->displayName; }
34 public function getEntity() :
string{
return $this->entity; }
36 public function getTimeInNS() :
int{
return $this->timeInNS; }
38 public function getPercentOfTotal() :
int{
return $this->percentOfTotal; }
40 public static function read(ByteBufferReader $in) :
self{
41 $displayName = CommonTypes::getString($in);
42 $entity = CommonTypes::getString($in);
43 $timeInNS = LE::readUnsignedLong($in);
44 $percentOfTotal = Byte::readUnsigned($in);
54 public function write(ByteBufferWriter $out) :
void{
55 CommonTypes::putString($out, $this->displayName);
56 CommonTypes::putString($out, $this->entity);
57 LE::writeUnsignedLong($out, $this->timeInNS);
58 Byte::writeUnsigned($out, $this->percentOfTotal);