public function getInt($min = 0, $max = 2147483647) { /** @noinspection TypeUnsafeComparisonInspection */ if ($min == $max) { return $min; } else { $ar = unpack('l', $this->getByte(4)); return $min + abs($ar[1]) % ($max - $min + 1); } }