Exemplo n.º 1
0
void MachineModel::waitFor_qNotFull()
{
// while waiting maintain the temperatures
  while(qFull()) {
    manage(true);
  }
}
Exemplo n.º 2
0
void qEnqueue(Queue* q, int elem)
{
    if (!qFull(q)) {
        q->data[q->tail] = elem;
        q->tail = (q->tail + 1) % q->total;
    }
}