Revision d518fe54
Von Christian Ehringfeld vor fast 9 Jahren hinzugefügt
samples/example/main.cpp | ||
---|---|---|
e->create(groupPtr, true, true);
|
||
}
|
||
|
||
/** ---------------------------------
|
||
* FIND Pupil
|
||
* ---------------------------------
|
||
*/
|
||
QSharedPointer<Entity> pupilFindPtr = e->findById(22, QString("Pupil*"));
|
||
QSharedPointer<Pupil> pupilPtr = pupilFindPtr.objectCast<Pupil>();
|
||
qDebug() << "Pupil:" << pupilPtr->toString();
|
||
qDebug() << "GroupSize:" << pupilPtr->getGroups().size();
|
||
|
||
|
||
/** ---------------------------------
|
||
* FIND Group
|
||
* ---------------------------------
|
||
... | ... | |
qDebug() << "FoundMainTeacherGroupSize:" <<
|
||
foundMainTeacher->getMaintainedGroups().size();
|
||
|
||
qDebug() << "-----------------------------";
|
||
QSharedPointer<Pupil> foundPupil = e->findById<Pupil *>
|
||
(13).objectCast<Pupil>();
|
||
qDebug() << "FoundPupil:" << foundPupil->toString();
|
||
qDebug() << "FoundPupilGroupSize:" <<
|
||
foundPupil->getGroups().size();
|
||
|
||
qDebug() << "-----------------------------";
|
||
|
||
qDebug() << "Duration:" << t.elapsed();
|
Auch abrufbar als: Unified diff
update