The below program demonstrates how to clone an object. In the below program x1,x2 are two objects of class TestClone1 which implements cloneable.The x1 object is clone and assigned to x2 object. Run It Now!
The below program demonstrates how to create a static inner class and access it. The below program has class LifePolicy which defines a Static Inner class LifeBenefit which extends class Benefit. Run It Now!
The below program demonstrates how to create non-static inner class in java. In the below program, class LifeBenefit is a innerclass to class LifePolicy . Run It Now!
The below program demonstrates how to create nested inner class in java. In the below example , Class Inner is defined within Class Outer and can access Class Outer's datafield. Run It Now!
The below program demonstrates how to use Final Modifier in java.
The below program defines a final variables in Class Final1 named ( i, a, j) and assigns the value to them. Run It Now!
This example demonstrates prototype in java.prototype Specify the kinds of objects to create using a prototypical instance, and create new objects by copying this prototype. Run It Now!
this example demonstrates Chain of Responsibility in java.It avoids attaching the sender of a request to its receiver, giving this way other objects the possibility of handling the request too.
- The Run It Now!
This example demonstrates Roman Numeral Converter in java.The classical example fot the interpreter pattern is the one of interpreting the roman numerals. Run It Now!