Live data from Hacker News

Ask HN: Why not Java?

news.ycombinator.com

111–112 of 112 posts

Re: Ask HN: Why not Java?

#111
post #54

It's just that Java is very verbose, and actually I found it particularly horrible for data driven applications (by this I mean apps whose behavior is determined by data/config files, not "Big Data" - I have no experience with the latter). For complex data types you always need to create complex class hierarchies. In other languages you could just write webInfo = {url: "bla.bla", title: "bla die blub", links: ["link1…

Gson solves that problem by parsing Json to objects or untyped hashmaps. It's OK to mix a mini language into your program.

ImmutableMap.Builder gives you almost syntax-free hash map creation.

You can use constructors in a loop or Lists.transfrom for data-driven construction. Not exactly like JavaScript, but gets close.

Re: Ask HN: Why not Java?

#112
post #23
post #16

Earlier quoted context omitted.

Well, for starters the whole idea of programming in XML. That and gems such as http://static.springsource.org/spring/docs/2.5.x/api/org/spr... or http://static.springsource.org/spring/docs/2.5.x/api/org/spr... Of course I can't a priori prove that Spring is garbage, much like I can't a priori prove that it's better to be healthy and rich than to be poor and sick. It is a judgement call, but a judgement call that I be…

You can ditch the xml almost entirely in spring 3, which I've been using for 2 years now. All you need is 50-100 boilerplate lines and the rest is annotations. I agree that 2.x was xml hell, but it is worlds better now.

Hello, and I am Ruby!

http://www.youtube.com/watch?v=PQbuyKUaKFo

Post reply on HN