Automatic Balance Tester - Page 6
Forum Index > TL Mafia |
Xatalos
Finland9673 Posts
| ||
Blazinghand
![]()
United States25550 Posts
| ||
Xatalos
Finland9673 Posts
| ||
Blazinghand
![]()
United States25550 Posts
| ||
gonzaw
Uruguay4911 Posts
The problem is that (I assume) he doesn't know Python and needs to learn it, but he does know Java. He also already has the logic written in Java. I checked his code, and the only thing he needs to do is basically keep a "Balance" object in session while the user works on it, and that's it (or if he goes with JEE keep a Balance object in some scope). The only thing he would need to do is create the HTML, set up the server, create a servlet/controller, and add actions that correspond to the actions from the UI he already made. That's it, he only does that and he has everything else done. I think getting to know a little bit of the Java backend ecosystem is worth it just for that "the web app is already made" feeling. Also, checked your code... .....ahh, the "implement everything from 'equals' to 'hashcode' to 'toString' just to have a minimal class" problems of Java. And to think that in Scala you could use just 3 lines: case class Role(name: String, balanceValue: Double, team: Int) extends Ordered[Role] { def compare(that: Role) = if (this.team == that.team) (this.balanceValue - that.balanceValue) else (this.team - that.team) } | ||
Promethelax
Canada7089 Posts
| ||
gonzaw
Uruguay4911 Posts
![]() EDIT: If that effect was "have an aneurism" of course | ||
Promethelax
Canada7089 Posts
| ||
Xatalos
Finland9673 Posts
On March 07 2014 11:56 gonzaw wrote: Python can work. The problem is that (I assume) he doesn't know Python and needs to learn it, but he does know Java. He also already has the logic written in Java. I checked his code, and the only thing he needs to do is basically keep a "Balance" object in session while the user works on it, and that's it (or if he goes with JEE keep a Balance object in some scope). The only thing he would need to do is create the HTML, set up the server, create a servlet/controller, and add actions that correspond to the actions from the UI he already made. That's it, he only does that and he has everything else done. I think getting to know a little bit of the Java backend ecosystem is worth it just for that "the web app is already made" feeling. Also, checked your code... .....ahh, the "implement everything from 'equals' to 'hashcode' to 'toString' just to have a minimal class" problems of Java. And to think that in Scala you could use just 3 lines: Heh. To be fair I used Eclipse's "Insert Code" for many of the more mundane methods such as getters, setters, constructors etc. so it wasn't that annoying. Yeah, I don't really know Python. I guess it wouldn't be that hard to learn it, but naturally I would prefer to use the current logic if possible ![]() Thanks for all the advice! I'll probably start with the project sometime relatively soon, probably before summer. Not sure how large it'll become but at least getting the current balance tester to work as a web app seems feasible. | ||
| ||