Saturday, January 28, 2017

Java Coding - Few Basic Rules

1. Variables Passed by Value, Objects Passed by Reference

In Java, variable method arguments e.g. intString are passed by Value while the objects are passed by reference. Be mindful to it.

2. You can not create object of an abstract class directly

You need to extend this class and implement missing abstract methods (If any). Abstract class may not contain any abstract method if needed so.

3. Java does not support multiple inheritance

Though you can give a hand to it through a class implementing multiple interfaces e.g. class C implements A, B.

No comments:

Post a Comment

CDN | Clearing Cloudflare cache

In order to clear Cloudflare cache automatically via code, follow below steps: 1. Develop Custom TransportHandler Develop a custom Trans...