This function retrieves the solution of a completed batch request from a Cluster Manager. The solution is returned as a JSON solution string. For this call to succeed, the status of the batch request must be COMPLETED. Please refer to the Batch Status Codes section for further details.
A non-zero return value indicates that a problem occurred while querying the batch solution. Refer to the Error Code table for a list of possible return values. Details on the error can be obtained by calling GRBgeterrormsg.
batch: The batch to query.
jsonsolP: The location in which the pointer to the newly created JSON string should be placed.
On Windows, the string returned in
buffP is allocated in a
different heap from the calling program. You must call
to free it.
/* print JSON solution into string */ error = GRBgetbatchjsonsolution(batch, &jsonsol); if (error) goto QUIT; printf("JSON solution: %s\n", jsonsol);