src/MySQLReplication/BinaryDataReader/BinaryDataReader.php
public function readIntBeBySize($size)
    {
        if ($size === self::UNSIGNED_CHAR_LENGTH) {
            return $this->readInt8();
        }
        if ($size === self::UNSIGNED_SHORT_LENGTH) {
            return $this->readInt16Be();
        }
        if ($size === self::UNSIGNED_INT24_LENGTH) {
            return $this->readInt24Be();
        }
        if ($size === self::UNSIGNED_INT32_LENGTH) {
            return $this->readInt32Be();
        }
        if ($size === self::UNSIGNED_INT40_LENGTH) {
            return $this->readInt40Be();
        }

        throw new BinaryDataReaderException('$size ' . $size . ' not handled');
    }
public function readIntBeBySize($size)
    {
        if ($size === self::UNSIGNED_CHAR_LENGTH) {
            return $this->readInt8();
        }
        if ($size === self::UNSIGNED_SHORT_LENGTH) {
            return $this->readInt16Be();
        }
        if ($size === self::UNSIGNED_INT24_LENGTH) {
            return $this->readInt24Be();
        }
        if ($size === self::UNSIGNED_INT32_LENGTH) {
            return $this->readInt32Be();
        }
        if ($size === self::UNSIGNED_INT40_LENGTH) {
            return $this->readInt40Be();
        }

        throw new BinaryDataReaderException('$size ' . $size . ' not handled');
    }
public function readIntBeBySize ( $ size ) { if ( $ size === self :: UNSIGNED_CHAR_LENGTH ) { return $ this -> readInt8 ( ) ; } if ( $ size === self :: UNSIGNED_SHORT_LENGTH ) { return $ this -> readInt16Be ( ) ; } if ( $ size === self :: UNSIGNED_INT24_LENGTH ) { return $ this -> readInt24Be ( ) ; } if ( $ size === self :: UNSIGNED_INT32_LENGTH ) { return $ this -> readInt32Be ( ) ; } if ( $ size === self :: UNSIGNED_INT40_LENGTH ) { return $ this -> readInt40Be ( ) ; } throw new BinaryDataReaderException ( '$size ' . $ size . ' not handled' ) ; }
Read a big endian integer values based on byte number
@param int $size
@return int
@throws BinaryDataReaderException
Read a big endian integer values based on byte number