Icon

This is the documentation for an older version of Qube. The latest version of the documentation can be found here: Qube

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Current »

Like the qb_jobcmp() function, this is a comparison function similar to that used in the Perl "sort" routine.
@items = sort { $a <=> $b } @items;
This comparison function is given 2 hosts, "a" and "b" relative to a single job. Although this is not as critical a function as the qb_jobcmp function, the qb_hostcmp comparison function allows the developer to sort the hosts compared to a job based upon which host the job prefers.
This function is to return 1 if $hosta is greater in priority than $hostb, 0 if the hosts are equal and -1 if $hostb's priority is greater than $hosta.

  • No labels