5 ms·
The intro sold the book to me but I'm a bit reluctant to buy it because of the fact that it uses Ruby. I've just started working with Java (straight from Univer
by hacksonx 10y ago
The intro sold the book to me but I'm a bit reluctant to buy it because of the fact that it uses Ruby. I've just started working with Java (straight from University last year) and I've come to realise that in comparison to other OO languages which have evolved their syntax (C# & Python) Java hasn't. I doubt it'll help me with Java. I've already invested in a few books and test engines, mainly for my Oracle certifications.
- diggan 10y agoAfter touching most mainstream languages, I conclude that many of the languages have different syntax and stuff, but the principles are mostly the same. So without having read this book, if it teaches you OOP via ruby, you should be able to apply it in Java as well, but maybe with different syntax but the outcome would be the same
- phillmv 10y agoIunno, what's unique to ruby? I can only think of module mixins. Everything else (blocks, anonymous functions, syntax sugar) can be roughly approximated (i.e. generics), since I strongly doubt the book would use any of the metaprogramming features.
- superswordfish 10y agoOne objection I can think of is that Ruby is dynamically typed. Something that is elegant in Ruby might be a horror in Java.
- tln 10y agoRuby uses messages for methods, allowing cheap delegation; classes can be extended (monkey patched) after definition. I doubt Ruby OOP code would avoid using all metaprogramming, at the very least attr_accessor!
- titanomachy 10y agoTo me, metaprogramming means writing new macros/templates, not just using the "standard" ones.
- ryanbrunner 10y agoHaving taken Sandi's in-person course (which sounds like it covers a lot of the same territory as this book), the vast majority of it would be perfectly applicable to Javascript. Ruby lets you get away with some neat tricks, like dynamically loading classes by name to avoid ugly switch statements, or the occasional bit of monkey patching, but it's not the focus at all and it's easy to see how you could accomplish it in a more "traditional" way.
- rm_-rf_slash 10y agoI can't see how that's a problem. I don't know of a single language that is easier to understand at a glance than ruby. Unless you're doing configuration, Ruby syntax is as simple as it gets.
- bdcravens 10y agoHaven't bought it yet, but Sandi's writing and speaking style is very principles driven.
- marcosdumay 10y agoThe best thing you can do to master the Java-only world is to peek outside of it. (And that is true for almost every X-only world, whatever the X value.)
- noahc 10y agoI took a class with Sandi, where this material was covered. I paired with one developer who did mostly Java and he seemed to get a lot of the class even though he hadn't really programmed in Ruby. Might be worth reconsidering,FWIW.
- mercer 10y agoI found "Practical Object-Oriented Design in Ruby" to be immensely valuable, even though I don't really use Ruby much. I imagine it's the same for this book.
- wasd 10y agoHey Hacksonx, If you're planning a career as Java developer, I highly recommend this book. Sandi is a great writer and Ruby is just a tool to communicate a message. You'll gain a lot of insight about how to write great Java by reading any of her books or articles.