Example #1
0
void AgendaUI::queryMeetingByTitle(void) {
	cout << "[query meeting] [title]" << endl;
	cout << "[query meeting] ";
	string title;
	cin >> title;
	Meeting *m;
	if(agendaService_.meetingQuery(title).empty())
		m=NULL;
	else
		m = &(agendaService_.meetingQuery(title).front());
	cout << endl;
	cout << setw(10) << "sponsor";
	cout << setw(15) << "participator";
	cout << setw(20) << "start time";
	cout << setw(20) << "end time" << endl;
	if (m == NULL) {
		cout << "Agenda@" << currentUser_->getName() << " : # ";
		return;
	}
	cout << setw(10) << m->getSponsor();
	cout << setw(15) << m->getParticipator();
	cout << setw(20) << Date::dateToString(m->getStartDate());
	cout << setw(20) << Date::dateToString(m->getEndDate());
	cout << endl << endl;
	cout << "Agenda@" << currentUser_->getName() << " : # ";
}
bool fuc(const Meeting& meeting) {
if (meeting.getParticipator() == "Bill")
return true;
return false;
}