org.activemath.studentmodel2.data
Class AssessmentModel

java.lang.Object
  extended by org.activemath.studentmodel2.data.AssessmentModel

public class AssessmentModel
extends Object

This class represents the assessment part of the new, simple student model.
It contains an AssessmentCluster which manages the assessments.


Field Summary
protected static Category log
           
 String version
          for XStream
 
Constructor Summary
AssessmentModel(String userId)
           
 
Method Summary
 Map<CognitiveProcess,Integer> getAssessmentMap(String conceptId)
          Get the mastery map for a concept.
 ConceptAssessment getConceptAssessment(String conceptId)
          Get the ConceptAssessment for a specific concept
 List<Evidence> getDirectEvidence(String conceptId)
          Get a list of relevant direct evidences for a concept
 List<Evidence> getIndirectEvidence(String conceptId)
          Get a list of relevant indirect evidences for a concept
 List<String> getLastExercises(String conceptId)
          Get the last exercises the user has done
 long getLastStoredTime()
           
 double getMastery()
           
 double getMastery(Collection<String> conceptIds)
          Get the (average) mastery for a set of concepts
 int getMastery(String conceptId)
          Get the mastery for a concept NB: This method is an absolute hotspot for the whole application!!
 int getMastery(String conceptId, CognitiveProcess cognitiveProcess, CompetencySystem targetCompetencySystem)
          Return mastery in a (translated) competency system
 Map<String,Integer> getMasteryComponents(String satelliteId)
          Returns a map of conceptId -> mastery value.
 List<String> getMisconceptions()
           
 String getUserId()
          Get the userId this model is for
 boolean hasMisconception(String misconception)
           
 void init()
          After-constructor initialisation.
 void removeMisconceptions(List<String> nonMisconceptions)
          Remove misconceptions that could be associated with this exerciseResult
 void setLastStoredTime(long value)
           
 void setMisconceptions(List<String> misconceptions)
           
 void tellMisconception(List<String> misconceptions)
          Add misconceptions the exercise system diagnosed for this user
 void updateAssessment(String conceptId, Collection<CognitiveProcess> processes)
          Update the mastery for a given concept/cogn. process combination.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

protected static Category log

version

public String version
for XStream

Constructor Detail

AssessmentModel

public AssessmentModel(String userId)
Method Detail

init

public void init()
After-constructor initialisation. Necessary because loading us through XStream somehow doesn't call us in a constructor.


setLastStoredTime

public void setLastStoredTime(long value)

getLastStoredTime

public long getLastStoredTime()

getMastery

public double getMastery()
Returns:
Average mastery over all concepts (and processes)

getMastery

public double getMastery(Collection<String> conceptIds)
Get the (average) mastery for a set of concepts

Parameters:
conceptIds -
Returns:
The average mastery for this set of concepts

getMastery

public int getMastery(String conceptId)
Get the mastery for a concept NB: This method is an absolute hotspot for the whole application!!

Parameters:
conceptId - - the mbaseId of the concept
Returns:
the mastery

getMastery

public int getMastery(String conceptId,
                      CognitiveProcess cognitiveProcess,
                      CompetencySystem targetCompetencySystem)
Return mastery in a (translated) competency system

Parameters:
conceptId -
cognitiveProcess -
competencySystem -
Returns:

getUserId

public String getUserId()
Get the userId this model is for

Returns:
the userId

getLastExercises

public List<String> getLastExercises(String conceptId)
Get the last exercises the user has done

Parameters:
conceptId - - the mbaseId of the concept
Returns:
A list of Exercises or null if none

getDirectEvidence

public List<Evidence> getDirectEvidence(String conceptId)
Get a list of relevant direct evidences for a concept

Parameters:
conceptId - - the mbaseId of the concept
Returns:
A list of Evidences

getIndirectEvidence

public List<Evidence> getIndirectEvidence(String conceptId)
Get a list of relevant indirect evidences for a concept

Parameters:
conceptId - - the mbaseId of the concept
Returns:
A list of Evidences

getMasteryComponents

public Map<String,Integer> getMasteryComponents(String satelliteId)
Returns a map of conceptId -> mastery value. These conceptIds are underlying the mastery assessment of the supplied satelliteId.

Returns:
a Map associating conceptIds to their corresponding mastery values.
See Also:
SatelliteHelper

tellMisconception

public void tellMisconception(List<String> misconceptions)
Add misconceptions the exercise system diagnosed for this user

Parameters:
misconceptions - - the list of misconceptions

getMisconceptions

public List<String> getMisconceptions()
Returns:
the misconceptions

setMisconceptions

public void setMisconceptions(List<String> misconceptions)
Parameters:
misconceptions - the misconceptions to set

removeMisconceptions

public void removeMisconceptions(List<String> nonMisconceptions)
Remove misconceptions that could be associated with this exerciseResult

Parameters:
nonMisconcetions - - a List of Misconceptions the user does not have

getConceptAssessment

public ConceptAssessment getConceptAssessment(String conceptId)
Get the ConceptAssessment for a specific concept

Parameters:
conceptId - - the mBaseId of the concept to get the assessment for
Returns:
The ConceptAssessment, on error return null

getAssessmentMap

public Map<CognitiveProcess,Integer> getAssessmentMap(String conceptId)
Get the mastery map for a concept.

Parameters:
conceptId - - the mbaseId of the concept
Returns:
A map with key: cognitive process and value: the mastery

updateAssessment

public void updateAssessment(String conceptId,
                             Collection<CognitiveProcess> processes)
Update the mastery for a given concept/cogn. process combination. (normally invoked upon availability of new evidence...)

Parameters:
conceptId - - the affected concept (mBaseID)
processes - - List of cognitive processes to be updated

hasMisconception

public boolean hasMisconception(String misconception)