def count_lines(self):
        # type: () -> LineCounts
        """Count the lines in the matched files.

        Returns:
            `~LineCounts`: A named tuple containing line counts.

        Example:
            >>> import fs
            >>> fs.open_fs('~/projects').glob('**/*.py').count_lines()
            LineCounts(lines=5767102, non_blank=4915110)

        """

        lines = 0
        non_blank = 0
        for path, info in self._make_iter():
            if info.is_file:
                for line in self.fs.open(path, "rb"):
                    lines += 1
                    if line.rstrip():
                        non_blank += 1
        return LineCounts(lines=lines, non_blank=non_blank)
Count the lines in the matched files.

        Returns:
            `~LineCounts`: A named tuple containing line counts.

        Example:
            >>> import fs
            >>> fs.open_fs('~/projects').glob('**/*.py').count_lines()
            LineCounts(lines=5767102, non_blank=4915110)