Java SE7 Features

-Binary literals, (using prefix 0b or oB)
-Underscores in numeric literals
-string in switch statements
-type inference for Generic instance creation
Map<String, List<String>> myMap = new HashMap<String, List<String>>();
In Java SE 7, you can substitute the parameterized type of the constructor with an empty set of type parameters (<>):
Map<String, List<String>> myMap = new HashMap<>();
-Caching Multiple exception
-Rethrowing exception with improved type checking
-try with resources statements
try(FileInputStream input = new FileInputStream(“file.txt”)) close automatically input stream, using AutoClosable interface
using multiple resources
try( FileInputStream input = new FileInputStream(“file.txt”);
BufferedInputStream bufferedInput = new BufferedInputStream(input)
) {}





About Lekshmana Perumal M

Proud be an Indian, passion to teaching & learn, love mathematics, enjoy with family & friends, job to code. Care about child education, Indian culture
This entry was posted in JAVA, technology, Uncategorized and tagged , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s