org.problets.tutor.problemsequencer
Class AbstractProblemSequencer

java.lang.Object
  extended by org.problets.tutor.problemsequencer.AbstractProblemSequencer
Direct Known Subclasses:
AutoProblemSequencer, CompetenceProblemSequencerLimited, IntegratedProblemSequencer, PredefinedProblemSequencer

public abstract class AbstractProblemSequencer
extends java.lang.Object

Serves as the base class for the various problem sequencers

Author:
Amruth Kumar

Field Summary
static java.lang.String PREDEFINED_FILE_EXT
           
static java.lang.String PREDEFINED_FILE_INDEX
           
static java.lang.String TEMPLATE_FILE
           
 
Constructor Summary
AbstractProblemSequencer(java.lang.String inTopic, java.util.Vector conceptsVector, java.util.Vector inLearningObjectives)
          conceptsVector is a vector of fully qualified learning objectives, ideally generated by querying KnowledgeModel.getDesiredLeafVector() AutoProblemSequencer: generates all the templates for only the concepts in conceptsVector.
 
Method Summary
abstract  Template getNextTemplate()
          Abstract method to return the next template, to be redefined by all subclasses
static AbstractProblemSequencer getProblemSequencer(java.lang.String topic, java.lang.String inSequenceType, KnowledgeModel correctKM, StudentModel student)
          Returns the appropriate derived class object based on user's preference
abstract  java.lang.String getStatus()
          Returns the status of the problem sequencer, including the number of problems that remain to be solved and the number of concepts that remain to be learned, if applicable
abstract  boolean isSequenceDone()
          Abstract method to return whether all the necessary problems have been generated - to be redefined by all subclasses
static java.util.Vector loadTemplates(java.lang.String path, java.lang.String fileName, java.util.Vector conceptsVector)
           
 java.util.Vector loadTemplates(java.lang.String topicName, java.util.Vector conceptsVector)
          conceptsVector is a vector of fully qualified learning objectives, ideally generated by querying KnowledgeModel.getDesiredLeafVector()
static void main(java.lang.String[] args)
           
 Template preProcess(Template inTemplate)
          1) Produces a clone of the parameter template before returning it.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TEMPLATE_FILE

public static final java.lang.String TEMPLATE_FILE
See Also:
Constant Field Values

PREDEFINED_FILE_EXT

public static final java.lang.String PREDEFINED_FILE_EXT
See Also:
Constant Field Values

PREDEFINED_FILE_INDEX

public static final java.lang.String PREDEFINED_FILE_INDEX
See Also:
Constant Field Values
Constructor Detail

AbstractProblemSequencer

public AbstractProblemSequencer(java.lang.String inTopic,
                                java.util.Vector conceptsVector,
                                java.util.Vector inLearningObjectives)
conceptsVector is a vector of fully qualified learning objectives, ideally generated by querying KnowledgeModel.getDesiredLeafVector() AutoProblemSequencer: generates all the templates for only the concepts in conceptsVector. If a start template number is provided, make sure it is the number of a template for a concept in the conceptsVector. Otherwise, it ignores the template number and starts from the first template. PredefinedProblemSequencer: uses predefined templates that apply to the concepts in the conceptsVector only CompetenceProblemSequencer: Generates problems for competence on only the concepts in the conceptsVector, whether it is one or many. HOWEVER, correctConcepts and studentLearningObjectives MUST be of the same size.

Method Detail

getProblemSequencer

public static AbstractProblemSequencer getProblemSequencer(java.lang.String topic,
                                                           java.lang.String inSequenceType,
                                                           KnowledgeModel correctKM,
                                                           StudentModel student)
Returns the appropriate derived class object based on user's preference


getNextTemplate

public abstract Template getNextTemplate()
Abstract method to return the next template, to be redefined by all subclasses


isSequenceDone

public abstract boolean isSequenceDone()
Abstract method to return whether all the necessary problems have been generated - to be redefined by all subclasses


getStatus

public abstract java.lang.String getStatus()
Returns the status of the problem sequencer, including the number of problems that remain to be solved and the number of concepts that remain to be learned, if applicable


loadTemplates

public java.util.Vector loadTemplates(java.lang.String topicName,
                                      java.util.Vector conceptsVector)
conceptsVector is a vector of fully qualified learning objectives, ideally generated by querying KnowledgeModel.getDesiredLeafVector()


loadTemplates

public static java.util.Vector loadTemplates(java.lang.String path,
                                             java.lang.String fileName,
                                             java.util.Vector conceptsVector)

preProcess

public Template preProcess(Template inTemplate)
1) Produces a clone of the parameter template before returning it. Although this method just creates a clone, left it in place for possible future needs - since it is called by all the derived classes


main

public static void main(java.lang.String[] args)