code: def analyse(file, length=None):
      
      if isinstance(file, bytes):
          file = io.BytesIO(file)
  
      io_check(file)
      int_check(length or sys.maxsize)
  
      return analyse2(file, length)
docs: Analyse application layer packets.
  
      Keyword arguments:
          * file -- bytes or file-like object, packet to be analysed
          * length -- int, length of the analysing packet
  
      Returns:
          * Analysis -- an Analysis object from `pcapkit.analyser`