aspose file tools*
The moose likes Features new in Java 8 and the fly likes Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Features new in Java 8
Bookmark ""Java 8 New Features" - is Java changing?" Watch ""Java 8 New Features" - is Java changing?" New topic
Author

"Java 8 New Features" - is Java changing?

Bret Waldow
Ranch Hand

Joined: Aug 04, 2000
Posts: 59
Hello,

Given your overview, do you think that Java is becoming a different language, in the sense that the new paradigms are "taking over" and evolution of the earlier approach will fade, or are the new features enhancements but not real shifts?

Of course the language is used to express the directions it has been used for all along - it's good at them, and that's why solutions that are written in Java are written in Java. But in the course of adapting to express new uses that are coming into being (say functional programming vs Object Oriented programming), do you think the language might actually be driven in a new direction?

There might be other distinctions you see - what do you see with your perspective?

Cheers,
Bret
Sean Corfield
Ranch Hand

Joined: Feb 09, 2011
Posts: 267
    
    5

I can't speak for Richard but I think Java is becoming more of a multi-paradigm language over time - which is to be expected of a general purpose language and it's in line with the approach that both C++ and Scala have taken (although incorporating very different things).

As someone who programs in Clojure for a living, I'm very happy to see support for Functional Programming idioms in Java 8. I pretty much parted company with Java the language around Java 5. I considered pretty much everything added in that release to be a mistake, glomming on complexity, and losing the earlier simplicity of the language (and that's coming from someone who spent a decade writing C++ and was an active member of X3J16, the ANSI C++ Standards Committee, for most of that time!).

Java 8 finally brings both increased expressiveness and some important simplifications. Lambdas, streams, and functional interfaces all combine to reduce the amount of code you need to write while increasing the work you can do easily and safely. It's a huge step forward for Java, in my opinion.

I would like to have seen immutable collections added - perhaps we'll get those in Java 9? - although there are several third party alternatives. I would also like to see "functional wrappers" for some of the existing libraries so that you can program without null pointers and without loops (although streams and map / flatMap / collect / reduce already help there).

I blogged my thoughts about Java 8 back in June.
Richard Reese
author
Ranch Hand

Joined: Jul 13, 2011
Posts: 84
    
    5

Bret,

I think Java is definitely changing but it’s like most languages in that it doesn’t necessarily force you to use specific techniques. For example, you can write a non-object oriented program in C++ and still call it C++. The new Java provides you with more options to solve problems. Whether you use them is another story.

I think the answer to your question is that it all depends on who uses it and their ability and motivation for using new features. The new version of Java simply gives you many more new options than it had before.

Richard Reese
Java 8 New Features: A Practical Heads-Up Guide
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: "Java 8 New Features" - is Java changing?