Search in sources :

Example 1 with StudentSearchDocument

use of teammates.storage.search.StudentSearchDocument in project teammates by TEAMMATES.

the class StudentsDb method putDocuments.

/**
 * Batch creates or updates search documents for the given students.
 */
public void putDocuments(List<StudentAttributes> students) {
    List<SearchDocument> studentDocuments = new ArrayList<>();
    for (StudentAttributes student : students) {
        studentDocuments.add(new StudentSearchDocument(student));
    }
    putDocuments(Const.SearchIndex.STUDENT, studentDocuments);
}
Also used : ArrayList(java.util.ArrayList) StudentSearchDocument(teammates.storage.search.StudentSearchDocument) StudentAttributes(teammates.common.datatransfer.attributes.StudentAttributes) SearchDocument(teammates.storage.search.SearchDocument) StudentSearchDocument(teammates.storage.search.StudentSearchDocument)

Aggregations

ArrayList (java.util.ArrayList)1 StudentAttributes (teammates.common.datatransfer.attributes.StudentAttributes)1 SearchDocument (teammates.storage.search.SearchDocument)1 StudentSearchDocument (teammates.storage.search.StudentSearchDocument)1