int _print_job_time_used(job_info_t * job, int width, bool right, char* suffix) { if (job == NULL) /* Print the Header instead */ _print_str("TIME", width, right, true); else _print_secs(job_time_used(job), width, right, false); if (suffix) printf("%s", suffix); return SLURM_SUCCESS; }
int _print_step_time_used(job_step_info_t * step, int width, bool right, char* suffix) { if (step == NULL) /* Print the Header instead */ _print_str("TIME", width, right, true); else { long delta_t = step->run_time; _print_secs(delta_t, width, right, false); } if (suffix) printf("%s", suffix); return SLURM_SUCCESS; }
int _print_step_time_limit(job_step_info_t * step, int width, bool right, char* suffix) { if (step == NULL) /* Print the Header instead */ _print_str("LIMIT", width, false, true); else if (step->time_limit == INFINITE) _print_str("UNLIMITED", width, right, true); else _print_secs(step->time_limit * 60, width, right, false); if (suffix) printf("%s", suffix); return SLURM_SUCCESS; }
int _print_job_time_limit(job_info_t * job, int width, bool right, char* suffix) { if (job == NULL) /* Print the Header instead */ _print_str("TIMELIMIT", width, right, true); else if (job->time_limit == INFINITE) _print_str("UNLIMITED", width, right, true); else if (job->time_limit == NO_VAL) _print_str("NOT_SET", width, right, true); else _print_secs((job->time_limit*60), width, right, false); if (suffix) printf("%s", suffix); return SLURM_SUCCESS; }
int _print_time(sinfo_data_t * sinfo_data, int width, bool right_justify, char *suffix) { if (sinfo_data) { if (sinfo_data->part_info == NULL) _print_str("n/a", width, right_justify, true); else if (sinfo_data->part_info->max_time == INFINITE) _print_str("infinite", width, right_justify, true); else _print_secs((sinfo_data->part_info->max_time * 60L), width, right_justify, true); } else _print_str("TIMELIMIT", width, right_justify, true); if (suffix) printf("%s", suffix); return SLURM_SUCCESS; }
int _print_default_time(sinfo_data_t * sinfo_data, int width, bool right_justify, char *suffix) { if (sinfo_data) { if ((sinfo_data->part_info == NULL) || (sinfo_data->part_info->default_time == NO_VAL)) _print_str("n/a", width, right_justify, true); else if (sinfo_data->part_info->default_time == INFINITE) _print_str("infinite", width, right_justify, true); else _print_secs((sinfo_data->part_info->default_time * 60L), width, right_justify, true); } else _print_str("DEFAULTTIME", width, right_justify, true); if (suffix) printf("%s", suffix); return SLURM_SUCCESS; }