12.4.12.2 Initiating a query from C
All Application Manual Name SummaryHelp

  • Documentation
    • Reference manual
      • Foreign Language Interface
        • The Foreign Include File
          • Calling Prolog from C
            • Initiating a query from C
              • PL_open_query()
              • PL_next_solution()
              • PL_cut_query()
              • PL_close_query()
              • PL_current_query()
              • PL_query_engine()
              • PL_query_arguments()
              • PL_set_query_data()
              • PL_query_data()
              • PL_call_predicate()
              • PL_call()
    • Packages
Availability:C-language interface function
term_t PL_query_arguments(qid_t qid)
Return a term_t handle to the first argument of the main goal of the query qid. This allows for enumerating a query and acting on the binding of one of the arguments without additional context. Note that the returned term_t is not the same handle that was used in PL_open_query() to pass the arguments. The content of the returned vector, however, is the same.