class_docstr: A feed-style parser of email.
class_docstr_tok: ["A","feed-style","parser","of","email","."]
docstr: Parse all remaining data and return the root message object.
docstr_tok: ["Parse","all","remaining","data","and","return","the","root","message","object","."]
code: def close(self):
      """Parse all remaining data and return the root message object."""
      self._input.close()
      self._call_parse()
      root = self._pop_message()
      assert not self._msgstack
      # Look for final set of defects
      if (
          root.get_content_maintype() == "multipart"
          and not root.is_multipart()
          and not self._headersonly
      ):
          defect = errors.MultipartInvariantViolationDefect()
          self.policy.handle_defect(root, defect)
      return root
  
imports: import re
  from email import errors
  from email._policybase import compat32
  from collections import deque
  from io import StringIO
label_desc: Use image node_id 5 for calling the FeedParser obj's underlying member method code with example usage: obj.close() and returns: root