void TxSummary::processGltx(const Gltx& gltx) { Employee employee; findEmployee(gltx.employeeId(), employee); EmployeeInfo& info = findEmployeeInfo(employee); // Voided transactions just get counted if (!gltx.isActive()) { info.voidTxCnt++; return; } // Further processing based on type switch (gltx.dataType()) { case DataObject::INVOICE: processInvoice(info, gltx); break; case DataObject::RETURN: processReturn(info, gltx); break; case DataObject::PAYOUT: processPayout(info, gltx); break; case DataObject::RECEIPT: processPayment(info, gltx); break; case DataObject::WITHDRAW: processWithdraw(info, gltx); break; case DataObject::NOSALE: processNosale(info, gltx); break; case DataObject::TEND_ADJUST: processTenderAdjust(info, gltx); break; default: processOther(info, gltx); } }
Local void lookahead(struct LOC_processLine *LINK) { Char STR2[256]; Char STR3[256]; while (bind_left[(long)nextNote(LINK->voice)]) sprintf(LINK->note + strlen(LINK->note), " %s", processOther(STR2, getMusicWord(STR3, LINK->voice), LINK)); }
Static void processLine(voice_index voice_, short bar_no) { struct LOC_processLine V; paragraph_index par_line; Char STR1[256]; V.voice = voice_; *V.pretex = '\0'; V.no_chords = false; V.no_uptext = false; par_line = musicLineNo(V.voice); V.nmulti = 0; V.ngrace = 0; line_no = orig_line_no[par_line-1]; do { getMusicWord(V.note, V.voice); if (*V.note == '\0') return; /* if debugMode then writeln(voice,' ',note); */ switch (thisNote(V.voice)) { case rword: if (*multi_bar_rest != '\0') { if (uptextOnRests()) addUptext(V.voice, &V.no_uptext, V.pretex); } else { V.l = pos1(multi_group, V.note); if (V.l > 0) scan1(V.note, V.l + 1, &V.nmulti); if (V.nmulti > 0) { V.in_group = true; V.nmulti--; } if (uptextOnRests()) addUptext(V.voice, &V.no_uptext, V.pretex); if (!(isPause(V.note) || V.in_group)) /*0.63: allow rests in xtuples*/ resetDuration(V.voice, durationCode(V.note)); } break; case abcdefg: processUsual(&V); break; case barword: if (V.voice == nvoices) { if (endOfBar(V.voice, bar_no)) strcpy(repeat_sign, V.note); else writeRepeat(V.note); } sprintf(STR1, "%c", barsym); if (strcmp(V.note, STR1)) *V.note = '\0'; V.no_chords = false; break; case FirstOnly: if (V.voice != nvoices) *V.note = '\0'; else strcpy(V.note, processOther(STR1, V.note, &V)); break; default: strcpy(V.note, processOther(STR1, V.note, &V)); break; } output(V.note, &V); } while (!endOfBar(V.voice, bar_no)); if (!V.no_chords) skipChordBar(V.voice); }