1. drmaa2_jarray_get_job_template(3)
  2. DRMAA2
  3. drmaa2_jarray_get_job_template(3)

NAME

drmaa2_jarray_get_job_template - drmaa2_jarray_get_job_template(3), Returns a jtemplate of the jarray.

SYNOPSIS

#include "drmaa2.h"

drmaa2_jtemplate drmaa2_jarray_get_job_template(const drmaa2_jarray jarray)

DESCRIPTION

Creates a newly allocated job template, which was used for submitting the job. After closing the job session which was used for submitting the job, the job template is not available anymore. The job template needs to be freed from the calling function.

RETURN VALUES

Return a newly allocated drmaa2_jtemplate or NULL in case of an error.

EXAMPLE

/* ... array job id stems from a previous drmaa2_jarray_get_id() call ... */
drmaa2_jarray ja = drmaa2_jsession_get_job_array(js, id);

if (ja != NULL) {
  drmaa2_jtemplate template = drmaa2_jarray_get_job_template(ja);

  if (template != NULL) {
     /* ... do something with the template ... */

     /* finally free the job template */
     drmaa2_jtemplate_free(&template);         
  }

  drmaa2_jarray_free(&ja);
}

SEE ALSO

drmaa2_jarray_free(3), drmaa2_jarray_get_session_name(3), drmaa2_jarray_get_jobs(3), drmaa2_jarray_get_id(3), drmaa2_jsession_get_session_names(3), drmaa2_jsession_get_session_name(3), drmaa2_jsession_get_contact(3), drmaa2_jsession_get_job_array(3), drmaa2_jsession_run_job(3), drmaa2_jsession_run_bulk_jobs(3), drmaa2_jsession_wait_any_started(3), drmaa2_jsession_wait_any_terminated(3), drmaa2_open_jsession(3)

AUTHOR

Copyright Univa Corporation 2013

  1. Univa Corporation
  2. October 2013
  3. drmaa2_jarray_get_job_template(3)