code: def query(cls, query, maxresult=-1, catcherrors=True, normalize=True):
          
          return cls._QueryWrapper()(query, maxresult, catcherrors, normalize)
docs: Run a prolog query and return a generator.
          If the query is a yes/no question, returns {} for yes, and nothing for no.
          Otherwise returns a generator of dicts with variables as keys.
  
          >>> prolog = Prolog()
          >>> prolog.assertz("father(michael,john)")
          >>> prolog.assertz("father(michael,gina)")
          >>> bool(list(prolog.query("father(michael,john)")))
          True
          >>> bool(list(prolog.query("father(michael,olivia)")))
          False
          >>> print sorted(prolog.query("father(michael,X)"))
          [{'X': 'gina'}, {'X': 'john'}]