def read_byte_as_integer(bytelen)
      unless bit_pointer % 8 == 0
        raise BinaryException.new("Bit pointer must be pointing start of byte. " +
                                  "But now pointing #{bit_pointer}.")
      end
      if self.length - bit_pointer/8 < bytelen
        raise BinaryException.new("Rest of self length(#{self.length - bit_pointer/8}byte) " + 
                                  "is shorter than specified byte length(#{bytelen}byte).")
      end
      response = 0
      bytelen.times do |i|
        response = response << 8
        response += to_i(bit_pointer/8 + i)
      end
      bit_pointer_inc(bytelen * 8)
      return response
    end
def read_byte_as_integer(bytelen)
      unless bit_pointer % 8 == 0
        raise BinaryException.new("Bit pointer must be pointing start of byte. " +
                                  "But now pointing #{bit_pointer}.")
      end
      if self.length - bit_pointer/8 < bytelen
        raise BinaryException.new("Rest of self length(#{self.length - bit_pointer/8}byte) " + 
                                  "is shorter than specified byte length(#{bytelen}byte).")
      end
      response = 0
      bytelen.times do |i|
        response = response << 8
        response += to_i(bit_pointer/8 + i)
      end
      bit_pointer_inc(bytelen * 8)
      return response
    end
Read specified length of bytes and return as Integer instance.
 Bit pointer proceed for that length.