code: public final MaxSATResult search(final MaxSATHandler handler) {
      this.handler = handler;
      if (handler != null)
        handler.startedSolving();
      final MaxSATResult result = search();
      if (handler != null)
        handler.finishedSolving();
      this.handler = null;
      return result;
    }
docs: The main MaxSAT solving method.
  @param handler a MaxSAT handler
  @return the result of the solving process
  @throws IllegalArgumentException if the configuration was not valid