public class ContentVisitor<X extends ContentBuilder> extends java.lang.Object implements PartVisitor<X>, Contexed
PartVisitor
to generate a view of the current state of the response against a partModifier and Type | Class and Description |
---|---|
class |
ContentVisitor.NoAnswer |
Modifier and Type | Field and Description |
---|---|
protected static java.lang.String |
ANSWER_COL |
protected CompleteVisitor |
complete_viz |
protected HasQuestionsVisitor |
has_question_viz |
protected static java.lang.String |
QUESTION_COL |
protected ResponseManager.Response<?> |
response |
protected SessionService |
sess |
Constructor and Description |
---|
ContentVisitor(X cb,
SessionService sess,
ResponseManager.Response<?> response) |
Modifier and Type | Method and Description |
---|---|
AppContext |
getContext() |
protected Logger |
getLogger() |
<C extends ContentBuilder> |
visitPage(C builder,
PageManager.Page p) |
X |
visitPage(PageManager.Page p) |
X |
visitQuestion(QuestionManager.Question q) |
void |
visitQuestion(Table<java.lang.String,QuestionManager.Question> t,
QuestionManager.Question q) |
<C extends ContentBuilder> |
visitSection(C builder,
java.util.Map<java.lang.String,java.lang.String> errors,
SectionManager.Section s) |
X |
visitSection(SectionManager.Section s) |
protected static final java.lang.String ANSWER_COL
protected static final java.lang.String QUESTION_COL
protected final SessionService sess
protected final ResponseManager.Response<?> response
protected final CompleteVisitor complete_viz
protected final HasQuestionsVisitor has_question_viz
public ContentVisitor(X cb, SessionService sess, ResponseManager.Response<?> response)
public <C extends ContentBuilder> C visitPage(C builder, PageManager.Page p) throws java.lang.Exception
java.lang.Exception
public <C extends ContentBuilder> C visitSection(C builder, java.util.Map<java.lang.String,java.lang.String> errors, SectionManager.Section s) throws java.lang.Exception
java.lang.Exception
public void visitQuestion(Table<java.lang.String,QuestionManager.Question> t, QuestionManager.Question q) throws java.lang.Exception
java.lang.Exception
public final X visitPage(PageManager.Page p)
visitPage
in interface PartVisitor<X extends ContentBuilder>
protected final Logger getLogger()
public final X visitSection(SectionManager.Section s)
visitSection
in interface PartVisitor<X extends ContentBuilder>
public final X visitQuestion(QuestionManager.Question q)
visitQuestion
in interface PartVisitor<X extends ContentBuilder>
public AppContext getContext()
getContext
in interface Contexed