Dec 31, 2015

The Ten (10) Productive Features in Java 8 You Should Know

Lambdas are the most talked about feature Java 8. But that’s just one feature. Java 8 has a lot of new features - some are powerful new classes and idioms, while others are just killer features that should have been there from the day one. I wanted to go over ten new features which I consider them as Killer Productive Features that definitely every Java programmer should know about them.

Jan 31, 2013

Android Tools Installation

Development Tools Setup

Android Tools Intallation
Before anything, we first and foremost have to setup the development environment in which we are going to start developing our Android apps. I am going to use Eclipse IDE as my development environment of choice. For those that are familiar with Java, Eclipse should probably be familiar to them. We also need the Android SDK which contained all the utilities required for applications development, as well as the tools for debugging, testing etc. There is also  sample codes and documentations.

Jan 17, 2013

Introduction To Android

What Android is all about? 


Introduction To Android
Android is the world's most popular mobile platform developed by Google in conjunction with Open Handset Alliance, a consortium of 86 hardware, software, and telecommunication companies committed to promoting open standards for mobile devices. Android, Inc. was founded in Palo Alto, California, in October 2003 by Andy Rubin, Rich Miner, Nick Sears, and Chris white. Android Inc was later acquired by Google on August 17, 2005, making it a wholly owned subsidiary of Google.

Dec 4, 2012

Java Generics and PECS Rule

Java Generics and PECS Rule
The fad behind the Arrays and the generic Collections is defined by this two important scenarios: Arrays are covariant(Widening their reference) while Collections are invariants(Narrowing their reference). When it comes to input parameters it becomes clear that these two containers differ largely and requires extra careful approach. for instance if a class of Foo is a subtype of another class Foobar then the array of type Foo[] is a subtype of Foobar[].

Nov 8, 2012

Java 7 Overview: Multi-Catch Support

Java 7, also known as Project Coin also improved Java's exception handling with the introduction of Muti-Catch Exception and Final Rethrow supports. With Multi-catch you will now be able to catch multiple exceptions in single block contrary to Java 6 or earlier where this isn't possible. In the previous posts, I used a multicatch feature in the Cryptography examples. Despite the fact that in the previous code, the method encrypt_data() throws an exception.

Nov 6, 2012

Java 7 Overview: Automatic Resource Management

Java 7 support Automatic Resources Management through the try-with-resources statement. A resource is an object that must be closed after the program is finished with it. The try statement could declare one or more resources, where it ensures that each resource is closed at the end of the statement. Any object that implements java.lang.AutoCloseable, which includes all objects which implement, can be used as a resource in this regard.

Nov 2, 2012

Java 7 Overview: String in Switch Support

jdk 7Prior to Java 7, Switch statements work either with primitive types or enumerated data types. Java 7 introduced ability to Switch on String type.
The issue worth mentioning about switch statement when used with a String type is, it uses equals() method to compare the expression pass to it, with each value in the case statement, which made it case-sensitive and will throw a NullPointerException if the expression is null.
As a result, checking for null parameter and converting the string to lower