clone() is a method in the Java programming language for object duplication.
Typically it calls the clone() method of its superclass to obtain the copy, etc.
However, Object.clone() throws a CloneNotSupportedException unless the object is an instance of a class that implements the marker interface Cloneable.
Most interfaces and abstract classes in Java do not specify a public clone() method.
As a result, often the clone() method can only be used if the actual class of an object is known, which is contrary to the abstraction principle of using the most generic type possible.
Actual implementations of List like ArrayList and LinkedList all generally have clone() methods themselves, but it is inconvenient and bad abstraction to carry around the actual class type of an object.
These methods are not always adequate when the concrete type of the cloned object is not known in advance.
With complex object graphs, deep copying can also become problematic when recursive references exist.
If the purpose of a specific clone() implementation is not fully understood by consumers, it may unintentionally break the "single object, multiple references" paradigm.
Another alternative method is actually making the idea formal : creating a copy constructor that takes an instance.