Search in sources :

Example 1 with Thead

use of uk.ac.ed.ph.jqtiplus.node.content.xhtml.table.Thead in project OpenOLAT by OpenOLAT.

the class AssessmentObjectComponentRenderer method renderTable.

public void renderTable(AssessmentRenderer renderer, StringOutput sb, AssessmentObjectComponent component, ResolvedAssessmentItem resolvedAssessmentItem, ItemSessionState itemSessionState, Table table, URLBuilder ubu, Translator translator) {
    renderStartHtmlTag(sb, component, resolvedAssessmentItem, table, null);
    table.getColgroups().forEach(colgroup -> renderColgroup(sb, component, resolvedAssessmentItem, colgroup));
    Thead thead = table.getThead();
    if (thead != null) {
        renderStartHtmlTag(sb, component, resolvedAssessmentItem, thead, null);
        thead.getTrs().forEach(tr -> renderTr(renderer, sb, component, resolvedAssessmentItem, itemSessionState, tr, ubu, translator));
        renderEndTag(sb, thead);
    }
    List<Tbody> tbodies = table.getTbodys();
    for (Tbody tbody : tbodies) {
        renderStartHtmlTag(sb, component, resolvedAssessmentItem, tbody, null);
        tbody.getTrs().forEach(tr -> renderTr(renderer, sb, component, resolvedAssessmentItem, itemSessionState, tr, ubu, translator));
        renderEndTag(sb, tbody);
    }
    Tfoot tfoot = table.getTfoot();
    if (tfoot != null) {
        renderStartHtmlTag(sb, component, resolvedAssessmentItem, tfoot, null);
        tfoot.getTrs().forEach(tr -> renderTr(renderer, sb, component, resolvedAssessmentItem, itemSessionState, tr, ubu, translator));
        renderEndTag(sb, tfoot);
    }
    renderEndTag(sb, table);
}
Also used : Thead(uk.ac.ed.ph.jqtiplus.node.content.xhtml.table.Thead) Tbody(uk.ac.ed.ph.jqtiplus.node.content.xhtml.table.Tbody) Tfoot(uk.ac.ed.ph.jqtiplus.node.content.xhtml.table.Tfoot)

Example 2 with Thead

use of uk.ac.ed.ph.jqtiplus.node.content.xhtml.table.Thead in project openolat by klemens.

the class AssessmentObjectComponentRenderer method renderTable.

public void renderTable(AssessmentRenderer renderer, StringOutput sb, AssessmentObjectComponent component, ResolvedAssessmentItem resolvedAssessmentItem, ItemSessionState itemSessionState, Table table, URLBuilder ubu, Translator translator) {
    renderStartHtmlTag(sb, component, resolvedAssessmentItem, table, null);
    table.getColgroups().forEach(colgroup -> renderColgroup(sb, component, resolvedAssessmentItem, colgroup));
    Thead thead = table.getThead();
    if (thead != null) {
        renderStartHtmlTag(sb, component, resolvedAssessmentItem, thead, null);
        thead.getTrs().forEach(tr -> renderTr(renderer, sb, component, resolvedAssessmentItem, itemSessionState, tr, ubu, translator));
        renderEndTag(sb, thead);
    }
    List<Tbody> tbodies = table.getTbodys();
    for (Tbody tbody : tbodies) {
        renderStartHtmlTag(sb, component, resolvedAssessmentItem, tbody, null);
        tbody.getTrs().forEach(tr -> renderTr(renderer, sb, component, resolvedAssessmentItem, itemSessionState, tr, ubu, translator));
        renderEndTag(sb, tbody);
    }
    Tfoot tfoot = table.getTfoot();
    if (tfoot != null) {
        renderStartHtmlTag(sb, component, resolvedAssessmentItem, tfoot, null);
        tfoot.getTrs().forEach(tr -> renderTr(renderer, sb, component, resolvedAssessmentItem, itemSessionState, tr, ubu, translator));
        renderEndTag(sb, tfoot);
    }
    renderEndTag(sb, table);
}
Also used : Thead(uk.ac.ed.ph.jqtiplus.node.content.xhtml.table.Thead) Tbody(uk.ac.ed.ph.jqtiplus.node.content.xhtml.table.Tbody) Tfoot(uk.ac.ed.ph.jqtiplus.node.content.xhtml.table.Tfoot)

Aggregations

Tbody (uk.ac.ed.ph.jqtiplus.node.content.xhtml.table.Tbody)2 Tfoot (uk.ac.ed.ph.jqtiplus.node.content.xhtml.table.Tfoot)2 Thead (uk.ac.ed.ph.jqtiplus.node.content.xhtml.table.Thead)2