ScheduleGroup::ListPtr ScheduleGroup::find(Yb::Session &session, const Yb::Expression &filter, const Yb::Expression &order_by) { ScheduleGroup::ListPtr lst(new ScheduleGroup::List()); Yb::ObjectList rows; session.load_collection(rows, Yb::Expression(_T("T_SCHEDULE_GROUP")), filter, order_by); if (rows.size()) { Yb::ObjectList::iterator it = rows.begin(), end = rows.end(); for (; it != end; ++it) lst->push_back(ScheduleGroup(*it)); } return lst; }
User::ListPtr User::find(Yb::Session &session, const Yb::Expression &filter, const Yb::Expression &order_by) { User::ListPtr lst(new User::List()); Yb::ObjectList rows; session.load_collection(rows, Yb::Expression(_T("T_USER")), filter, order_by); if (rows.size()) { Yb::ObjectList::iterator it = rows.begin(), end = rows.end(); for (; it != end; ++it) lst->push_back(User(*it)); } return lst; }