标签:
{}
.
How a class is initialized in java
class is initialized in Java when an instance of class is created using either new operator or using reflection using
class.forName(). A class is also said to be initialized when a static method of Class is invoked or a static filed is assigned
How to make a copy of an entire Java object with its state
Make that class implement Cloneable interface and call clone() method on its object.clone() method is defined in Object class which is the parent of all java class by default.
Java Method:
In java when you pass a primitive type to a method it is pass by value
when you pass an object of any type to a method it is passed as reference
标签:
原文地址:http://www.cnblogs.com/morningdew/p/5618525.html