Closed crccw closed 9 years ago
Comments from the review on Reviewable.io
vjudge-v2/CFJudger.cpp, line 118 [r1] (raw file):
Comments from the review on Reviewable.io
vjudge-v2/CFJudger.cpp, line 118 [r1] (raw file): I have tried that, will have problems in constructor since it will send message through socket..
The way CF handling gyms is extremely similar to common contests, the only difference is that gyms have a separate url, so there's really no need creating another class and simply copying the code...
Comments from the review on Reviewable.io
vjudge-v2/CFJudger.cpp, line 118 [r1] (raw file): You can modify the code move send socket part to a separate function called "sendInitialHandShakeMessage" or shorter version, make OJ string a protected variable that can be override. You should probably add that function to virtualjudger base class and change every other one. Then make diverged code in CFJudger to functions, and just override them. After you done that, the subclass should be really small.
Comments from the review on Reviewable.io
vjudge-v2/CFGymJudger.cpp, line 26 [r2] (raw file): Let's split the function so there's no need to copy the common part.
vjudge-v2/VirtualJudger.h, line 27 [r2] (raw file): Let's make it private and call this in VirtualJudger::run
Comments from the review on Reviewable.io
vjudge-v2/CFGymJudger.cpp, line 26 [r2] (raw file): Done.
vjudge-v2/VirtualJudger.h, line 27 [r2] (raw file): Done.
Comments from the review on Reviewable.io
vjudge-v2/ACdreamJudger.h, line 18 [r5] (raw file): private
vjudge-v2/CFGymJudger.cpp, line 26 [r5] (raw file): So I believe this one can be removed.
vjudge-v2/CFJudger.cpp, line 291 [r5] (raw file): getVerdictUrl
vjudge-v2/Logger.h, line 41 [r5] (raw file): I believe this is a mistake
vjudge-v2/VirtualJudger.h, line 41 [r5] (raw file): Update docstring
Comments from the review on Reviewable.io
vjudge-v2/ACdreamJudger.h, line 18 [r5] (raw file): Done.
vjudge-v2/CFGymJudger.cpp, line 26 [r5] (raw file): post field is different
vjudge-v2/CFJudger.cpp, line 291 [r5] (raw file): Done.
vjudge-v2/Logger.h, line 41 [r5] (raw file): Done.
vjudge-v2/VirtualJudger.h, line 41 [r5] (raw file): Done.
Comments from the review on Reviewable.io
vjudge-v2/CFGymJudger.cpp, line 26 [r5] (raw file): Would it fail if I pass contest as part of the contest? I don't think it will.
Even if it fails, we can add a function like "processMoreParams"
vjudge-v2/CFGymJudger.cpp, line 33 [r6] (raw file): " + contest + "
vjudge-v2/VirtualJudger.h, line 41 [r5] (raw file): Just say "Send handshake message to dispatcher"
vjudge-v2/VirtualJudger.h, line 45 [r6] (raw file): remote (my fault, facepalm
Comments from the review on Reviewable.io
vjudge-v2/CFGymJudger.cpp, line 26 [r5] (raw file): Done.
vjudge-v2/CFGymJudger.cpp, line 33 [r6] (raw file): Done.
vjudge-v2/VirtualJudger.h, line 41 [r5] (raw file): Done.
vjudge-v2/VirtualJudger.h, line 45 [r6] (raw file): Done.
Comments from the review on Reviewable.io
vjudge-v2/CFJudger.cpp, line 168 [r7] (raw file): No need (string)
It's so similar to regular CF contests so I just modified the CF Vjudger :)