Package de.hsh.graja.transform
Class GradingSchemeCommentHelper
java.lang.Object
de.hsh.graja.transform.GradingSchemeCommentHelper
This class creates a grid of the following form
+---------------------------+---------------------------+ | Title | Result | +-+-------------------------+-------------------------+-+ | | Description | | | +---------------------------------------------------+ | | | Feedback (currently not used) | | | +---------------------------------------------------+ | | | Calculation rule | | leftbar| +-------------------------+-------------------------+ |rightbar + | | Title Subaspect | Result Subaspect | | + +----+ +-+-----------------------+-----------------------+-+ +----+ | | | Description, Feedback, Calculation rule | | | | | | further subaspects | | | | | | | | | | +-+-----------------------+-----------------------+-+ | | | Title Subaspect | Result Subaspect | | | +-+-----------------------+-----------------------+-+ | | | | ... | | | | | | | | | | | | | | | +-+-+-----------------------------------------------+-+-+
Every title/result row (or subtitle/subresult) defines a node of the grading scheme tree.
A node is represented by the class GradingSchemeCommentHelper.GshNode
.
In the result or subresult cells icons can be rendered that allow folding and expanding the tree interactively.
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic Sequence
createBasicNullificationExplanation
(String title, String descriptionHtml, String internalDescriptionHtml, FontWeightAndStyle fwas) static Content
createCompositeNullificationComment
(boolean isSubmissionResult, String composeOp, List<Content> operands, FontWeightAndStyle fwas) createInnerNode
(String title, int level, String function, Number weight, Content nullifyExplanation, Number scoreAchievedAfterWeightingAndNullification, Number scoreAchievedAfterWeighting, Number rawScoreAchieved, Number scoreMax, String descriptionHtml, String internalDescriptionHtml, boolean useJavascript, List<GradingSchemeCommentHelper.GshNode> children) createLeaf
(String title, Number weight, Content nullifyExplanation, Number scoreAchievedAfterWeightingAndNullification, Number scoreAchievedAfterWeighting, Number rawScoreAchieved, Number scoreMax, String grade, Boolean gradeIsCorrect, Boolean gradeIsFaulty, String descriptionHtml, String internalDescriptionHtml, boolean useJavascript, Anchor href) static FontWeightAndStyle
getContentFontWeightAndStyle
(boolean isLeaf) static Content
transformGradingSchemeIntoSequenceComment
(GradingSchemeCommentHelper.GshNode theComments, boolean useJavascript)
-
Field Details
-
CONTENT_FWAS_LEAVES
-
CONTENT_FWAS_INNER_NODES
-
-
Constructor Details
-
GradingSchemeCommentHelper
public GradingSchemeCommentHelper()
-
-
Method Details
-
getContentFontWeightAndStyle
-
createInnerNode
public static GradingSchemeCommentHelper.GshNode createInnerNode(String title, int level, String function, Number weight, Content nullifyExplanation, Number scoreAchievedAfterWeightingAndNullification, Number scoreAchievedAfterWeighting, Number rawScoreAchieved, Number scoreMax, String descriptionHtml, String internalDescriptionHtml, boolean useJavascript, List<GradingSchemeCommentHelper.GshNode> children) -
createLeaf
public static GradingSchemeCommentHelper.GshNode createLeaf(String title, Number weight, Content nullifyExplanation, Number scoreAchievedAfterWeightingAndNullification, Number scoreAchievedAfterWeighting, Number rawScoreAchieved, Number scoreMax, String grade, Boolean gradeIsCorrect, Boolean gradeIsFaulty, String descriptionHtml, String internalDescriptionHtml, boolean useJavascript, Anchor href) -
createBasicNullificationExplanation
public static Sequence createBasicNullificationExplanation(String title, String descriptionHtml, String internalDescriptionHtml, FontWeightAndStyle fwas) -
createCompositeNullificationComment
public static Content createCompositeNullificationComment(boolean isSubmissionResult, String composeOp, List<Content> operands, FontWeightAndStyle fwas) -
transformGradingSchemeIntoSequenceComment
public static Content transformGradingSchemeIntoSequenceComment(GradingSchemeCommentHelper.GshNode theComments, boolean useJavascript)
-