News for hackers. Stuff that matters.
Re:Takes: Java web framework without static methods or annot... by Xorlev on Monday June 24, 2019 @04:03PM (#20267835)
Not trying to knock the work, but why is no static methods a selling point? How does one do utility classes instead? And do you eschew static factory methods entirely?
Re:Takes: Java web framework without static methods or annot... by vbezhenar on Monday June 24, 2019 @04:05PM (#20267856)
Yegor has quite orthodox view on Java development. You might want to read his blog to get better understanding on his position. While I don't agree with many of his points, it's a very interesting and refreshing perspective that is useful to learn IMO.
Re:Takes: Java web framework without static methods or annot... by saagarjha on Monday June 24, 2019 @04:07PM (#20267872)
Unorthodox?
Re:Takes: Java web framework without static methods or annot... by jayd16 on Monday June 24, 2019 @05:06PM (#20268480)
I think orthodox works here as its a more strict reading of the "everything is an object" dogma.
Re:Takes: Java web framework without static methods or annot... by Jach on Monday June 24, 2019 @05:28PM (#20268703)
"Native"? "At home"? "Happy Commoner in the Kingdom of Nouns[0]"? Or stockholm syndrome... I kind of get on "no static methods! 'util' and 'helper' are smells!" bends myself from time to time in order to make designs clearer and unit testing somewhat saner (because the even more sane approach of writing or refactoring to smaller pure functions and keeping them that way is too much to ask for sometimes) but it's all just because I spend too much time working in an insane language with a broken idea of what OOP is. Still, I appreciate write-ups like the author's, and at least he's right about immutability being good in general.

[0] http://steve-yegge.blogspot.com/2006/03/execution-in-kingdom...

Re:Takes: Java web framework without static methods or annot... by Xorlev on Monday June 24, 2019 @04:07PM (#20267873)
I didn't know the context, so thanks! I'll take a look. :)
Re:Takes: Java web framework without static methods or annot... by flukus on Monday June 24, 2019 @09:58PM (#20270521)
Because static methods/variables/things are hard to test code with because they're hard to replace. IME getting rid of static is the wrong solution though, the difficulty is only because of a limitation of current languages, unit test frameworks and build systems. If you can inject your substitutes at compile time (which I think you should be able to do at the test link step with java) then static isn't a problem.

There's also the issue of people seeing OO as the goal not the tool, which I think might be the case here too.

Re:Takes: Java web framework without static methods or annot... by LoSboccacc on Monday June 24, 2019 @04:18PM (#20267984)
and don't like 3/4 of the library within have static methods?

that's just adding sequential coupling for no good reason

Re:Takes: Java web framework without static methods or annot... by killface on Monday June 24, 2019 @06:09PM (#20269030)
i'm going to guess this was an exercise to try to do this, not to be effective as a tool :)
Re:Takes: Java web framework without static methods or annot... by yegor256a on Tuesday June 25, 2019 @12:44AM (#20271255)
You can see how many products already use this framework. So, yes, it was an exercise at the beginning. Now it's a fully functioning web framework.
Re:Takes: Java web framework without static methods or annot... by bassman9000 on Tuesday June 25, 2019 @12:04AM (#20271089)
Interfaces with defaults.
Re:Takes: Java web framework without static methods or annot... by exabrial on Tuesday June 25, 2019 @12:11AM (#20271109)
Testing.