ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilTestParticipantScoring Class Reference
+ Collaboration diagram for ilTestParticipantScoring:

Public Member Functions

 __construct ()
 ilTestParticipantScoring constructor. More...
 
 getActiveId ()
 
 setActiveId (int $activeId)
 
 getScoredPass ()
 
 setScoredPass (int $scoredPass)
 
 getAnsweredQuestions ()
 
 setAnsweredQuestions (int $answeredQuestions)
 
 getTotalQuestions ()
 
 setTotalQuestions (int $totalQuestions)
 
 getReachedPoints ()
 
 setReachedPoints (float $reachedPoints)
 
 getMaxPoints ()
 
 setMaxPoints (float $maxPoints)
 
 isPassed ()
 
 setPassed (bool $passed)
 
 getFinalMark ()
 
 setFinalMark (string $finalMark)
 
 getPercentResult ()
 

Protected Attributes

 $activeId
 
 $scoredPass
 
 $answeredQuestions
 
 $totalQuestions
 
 $reachedPoints
 
 $maxPoints
 
 $passed
 
 $finalMark
 

Detailed Description

Definition at line 13 of file class.ilTestParticipantScoring.php.

Constructor & Destructor Documentation

◆ __construct()

ilTestParticipantScoring::__construct ( )

ilTestParticipantScoring constructor.

Definition at line 58 of file class.ilTestParticipantScoring.php.

59  {
60  $this->activeId = 0;
61  $this->scoredPass = 0;
62  $this->answeredQuestions = 0;
63  $this->totalQuestions = 0;
64  $this->reachedPoints = 0.0;
65  $this->maxPoints = 0.0;
66  $this->passed = false;
67  $this->finalMark = '';
68  }

Member Function Documentation

◆ getActiveId()

ilTestParticipantScoring::getActiveId ( )
Returns
int

Definition at line 74 of file class.ilTestParticipantScoring.php.

References $activeId.

74  : int
75  {
76  return $this->activeId;
77  }

◆ getAnsweredQuestions()

ilTestParticipantScoring::getAnsweredQuestions ( )
Returns
int

Definition at line 106 of file class.ilTestParticipantScoring.php.

References $answeredQuestions.

106  : int
107  {
109  }

◆ getFinalMark()

ilTestParticipantScoring::getFinalMark ( )
Returns
string

Definition at line 186 of file class.ilTestParticipantScoring.php.

References $finalMark.

186  : string
187  {
188  return $this->finalMark;
189  }

◆ getMaxPoints()

ilTestParticipantScoring::getMaxPoints ( )
Returns
float

Definition at line 154 of file class.ilTestParticipantScoring.php.

References $maxPoints.

Referenced by getPercentResult().

154  : float
155  {
156  return $this->maxPoints;
157  }
+ Here is the caller graph for this function:

◆ getPercentResult()

ilTestParticipantScoring::getPercentResult ( )
Returns
int

Definition at line 202 of file class.ilTestParticipantScoring.php.

References getMaxPoints(), and getReachedPoints().

203  {
204  if ($this->getMaxPoints() > 0) {
205  return $this->getReachedPoints() / $this->getMaxPoints();
206  }
207 
208  return 0;
209  }
+ Here is the call graph for this function:

◆ getReachedPoints()

ilTestParticipantScoring::getReachedPoints ( )
Returns
float

Definition at line 138 of file class.ilTestParticipantScoring.php.

References $reachedPoints.

Referenced by getPercentResult().

138  : float
139  {
140  return $this->reachedPoints;
141  }
+ Here is the caller graph for this function:

◆ getScoredPass()

ilTestParticipantScoring::getScoredPass ( )
Returns
int

Definition at line 90 of file class.ilTestParticipantScoring.php.

References $scoredPass.

90  : int
91  {
92  return $this->scoredPass;
93  }

◆ getTotalQuestions()

ilTestParticipantScoring::getTotalQuestions ( )
Returns
int

Definition at line 122 of file class.ilTestParticipantScoring.php.

References $totalQuestions.

122  : int
123  {
124  return $this->totalQuestions;
125  }

◆ isPassed()

ilTestParticipantScoring::isPassed ( )
Returns
bool

Definition at line 170 of file class.ilTestParticipantScoring.php.

References $passed.

170  : bool
171  {
172  return $this->passed;
173  }

◆ setActiveId()

ilTestParticipantScoring::setActiveId ( int  $activeId)
Parameters
int$activeId

Definition at line 82 of file class.ilTestParticipantScoring.php.

References $activeId.

83  {
84  $this->activeId = $activeId;
85  }

◆ setAnsweredQuestions()

ilTestParticipantScoring::setAnsweredQuestions ( int  $answeredQuestions)
Parameters
int$answeredQuestions

Definition at line 114 of file class.ilTestParticipantScoring.php.

References $answeredQuestions.

115  {
116  $this->answeredQuestions = $answeredQuestions;
117  }

◆ setFinalMark()

ilTestParticipantScoring::setFinalMark ( string  $finalMark)
Parameters
string$finalMark

Definition at line 194 of file class.ilTestParticipantScoring.php.

References $finalMark.

195  {
196  $this->finalMark = $finalMark;
197  }

◆ setMaxPoints()

ilTestParticipantScoring::setMaxPoints ( float  $maxPoints)
Parameters
float$maxPoints

Definition at line 162 of file class.ilTestParticipantScoring.php.

References $maxPoints.

163  {
164  $this->maxPoints = $maxPoints;
165  }

◆ setPassed()

ilTestParticipantScoring::setPassed ( bool  $passed)
Parameters
bool$passed

Definition at line 178 of file class.ilTestParticipantScoring.php.

References $passed.

179  {
180  $this->passed = $passed;
181  }

◆ setReachedPoints()

ilTestParticipantScoring::setReachedPoints ( float  $reachedPoints)
Parameters
float$reachedPoints

Definition at line 146 of file class.ilTestParticipantScoring.php.

References $reachedPoints.

147  {
148  $this->reachedPoints = $reachedPoints;
149  }

◆ setScoredPass()

ilTestParticipantScoring::setScoredPass ( int  $scoredPass)
Parameters
int$scoredPass

Definition at line 98 of file class.ilTestParticipantScoring.php.

References $scoredPass.

99  {
100  $this->scoredPass = $scoredPass;
101  }

◆ setTotalQuestions()

ilTestParticipantScoring::setTotalQuestions ( int  $totalQuestions)
Parameters
int$totalQuestions

Definition at line 130 of file class.ilTestParticipantScoring.php.

References $totalQuestions.

131  {
132  $this->totalQuestions = $totalQuestions;
133  }

Field Documentation

◆ $activeId

ilTestParticipantScoring::$activeId
protected

Definition at line 18 of file class.ilTestParticipantScoring.php.

Referenced by getActiveId(), and setActiveId().

◆ $answeredQuestions

ilTestParticipantScoring::$answeredQuestions
protected

◆ $finalMark

ilTestParticipantScoring::$finalMark
protected

Definition at line 53 of file class.ilTestParticipantScoring.php.

Referenced by getFinalMark(), and setFinalMark().

◆ $maxPoints

ilTestParticipantScoring::$maxPoints
protected

Definition at line 43 of file class.ilTestParticipantScoring.php.

Referenced by getMaxPoints(), and setMaxPoints().

◆ $passed

ilTestParticipantScoring::$passed
protected

Definition at line 48 of file class.ilTestParticipantScoring.php.

Referenced by isPassed(), and setPassed().

◆ $reachedPoints

ilTestParticipantScoring::$reachedPoints
protected

Definition at line 38 of file class.ilTestParticipantScoring.php.

Referenced by getReachedPoints(), and setReachedPoints().

◆ $scoredPass

ilTestParticipantScoring::$scoredPass
protected

Definition at line 23 of file class.ilTestParticipantScoring.php.

Referenced by getScoredPass(), and setScoredPass().

◆ $totalQuestions

ilTestParticipantScoring::$totalQuestions
protected

Definition at line 33 of file class.ilTestParticipantScoring.php.

Referenced by getTotalQuestions(), and setTotalQuestions().


The documentation for this class was generated from the following file: