Function clingo_sys::clingo_control_solve [] [src]

pub unsafe extern "C" fn clingo_control_solve(
    control: *mut clingo_control_t,
    mode: clingo_solve_mode_bitset_t,
    assumptions: *const clingo_symbolic_literal_t,
    assumptions_size: usize,
    notify: clingo_solve_event_callback_t,
    data: *mut c_void,
    handle: *mut *mut clingo_solve_handle_t
) -> bool

Solve the currently @link ::clingo_control_ground grounded @endlink logic program enumerating its models.

See the @ref SolveHandle module for more information.

Parameters:

  • control the target
  • mode configures the search mode
  • assumptions array of assumptions to solve under
  • assumptions_size number of assumptions
  • notify the event handler to register
  • data the user data for the event handler
  • handle handle to the current search to enumerate models

Returns whether the call was successful; might set one of the following error codes: - ::clingo_error_bad_alloc - ::clingo_error_runtime if solving could not be started