Beispiel #1
0
 /**
  * Main program.
  *
  * @param array $args Command-line arguments.
  * @return integer Zero on succes; non-zero on failure.
  */
 public static function main($args)
 {
     printf("Demonstration program number 6.\n");
     $status = 0;
     BinaryHeap::main($args);
     LeftistHeap::main($args);
     BinomialQueue::main($args);
     Deap::main($args);
     return $status;
 }
Beispiel #2
0
        return new Deap_Iterator($this);
    }
    /**
     * Compares this deap with the specified comparable object.
     * This method is not implemented.
     *
     * @param object IComparable $arg
     * The comparable object with which to compare this deap.
     */
    protected function compareTo(IComparable $arg)
    {
        throw new MethodNotImplementedException();
    }
    /**
     * Main program.
     *
     * @param array $args Command-line arguments.
     * @return integer Zero on success; non-zero on failure.
     */
    public static function main($args)
    {
        printf("Deap main program.\n");
        $status = 0;
        $queue = new Deap(57);
        AbstractDoubleEndedPriorityQueue::test($queue);
        return $status;
    }
}
if (realpath($argv[0]) == realpath(__FILE__)) {
    exit(Deap::main(array_slice($argv, 1)));
}