Search in sources :

Example 6 with QTIExportFormatterCSVType3

use of org.olat.ims.qti.export.QTIExportFormatterCSVType3 in project openolat by klemens.

the class IQSURVCourseNode method archiveNodeData.

@Override
public boolean archiveNodeData(Locale locale, ICourse course, ArchiveOptions options, ZipOutputStream exportStream, String charset) {
    QTIExportManager qem = QTIExportManager.getInstance();
    String repositorySoftKey = (String) getModuleConfiguration().get(IQEditController.CONFIG_KEY_REPOSITORY_SOFTKEY);
    RepositoryEntry re = RepositoryManager.getInstance().lookupRepositoryEntryBySoftkey(repositorySoftKey, true);
    QTIExportFormatter qef = new QTIExportFormatterCSVType3(locale, null, "\t", "\"", "\r\n", false);
    try {
        return qem.selectAndExportResults(qef, course.getResourceableId(), getShortTitle(), getIdent(), re, exportStream, locale, ".xls");
    } catch (IOException e) {
        log.error("", e);
        return false;
    }
}
Also used : QTIExportManager(org.olat.ims.qti.export.QTIExportManager) QTIExportFormatterCSVType3(org.olat.ims.qti.export.QTIExportFormatterCSVType3) RepositoryEntry(org.olat.repository.RepositoryEntry) IOException(java.io.IOException) QTIExportFormatter(org.olat.ims.qti.export.QTIExportFormatter)

Aggregations

QTIExportFormatter (org.olat.ims.qti.export.QTIExportFormatter)6 QTIExportFormatterCSVType3 (org.olat.ims.qti.export.QTIExportFormatterCSVType3)6 QTIExportFormatterCSVType1 (org.olat.ims.qti.export.QTIExportFormatterCSVType1)4 QTIExportManager (org.olat.ims.qti.export.QTIExportManager)4 QTIItemObject (org.olat.ims.qti.export.helper.QTIItemObject)4 QTIObjectTreeBuilder (org.olat.ims.qti.export.helper.QTIObjectTreeBuilder)4 IOException (java.io.IOException)2 Date (java.util.Date)2 Group (org.olat.basesecurity.Group)2 OLATRuntimeException (org.olat.core.logging.OLATRuntimeException)2 CourseNode (org.olat.course.nodes.CourseNode)2 IQSELFCourseNode (org.olat.course.nodes.IQSELFCourseNode)2 IQTESTCourseNode (org.olat.course.nodes.IQTESTCourseNode)2 QTIResult (org.olat.ims.qti.QTIResult)2 QTIResultManager (org.olat.ims.qti.QTIResultManager)2 QTIExportItemFormatConfig (org.olat.ims.qti.export.QTIExportItemFormatConfig)2 RepositoryEntry (org.olat.repository.RepositoryEntry)2 UserManager (org.olat.user.UserManager)2