File tree Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Original file line number Diff line number Diff line change @@ -184,6 +184,28 @@ public function getTotalOptscoreMinPublic(): float
184
184
return $ this ->totaloptscore_min_public ;
185
185
}
186
186
187
+ public function getTotalOptscore (bool $ restricted ): float
188
+ {
189
+ if ($ this ->contest ->getOptScoreOrder () == 'asc ' ) return $ restricted
190
+ ? $ this ->getTotalOptscoreMinRestricted ()
191
+ : $ this ->getTotalOptscoreMinPublic ();
192
+ else return $ restricted
193
+ ? $ this ->getTotalOptscoreMaxRestricted ()
194
+ : $ this ->getTotalOptscoreMaxPublic ();
195
+ }
196
+
197
+ public function getTotalOptscoreRestricted (): float
198
+ {
199
+ if ($ this ->contest ->getOptScoreOrder () == 'asc ' ) return $ this ->getTotalOptscoreMinRestricted ();
200
+ else return $ this ->getTotalOptscoreMaxRestricted ();
201
+ }
202
+
203
+ public function getTotalOptscorePublic (): float
204
+ {
205
+ if ($ this ->contest ->getOptScoreOrder () == 'asc ' ) return $ this ->getTotalOptscoreMinPublic ();
206
+ else return $ this ->getTotalOptscoreMaxPublic ();
207
+ }
208
+
187
209
public function setContest (?Contest $ contest = null ): RankCache
188
210
{
189
211
$ this ->contest = $ contest ;
You can’t perform that action at this time.
0 commit comments