I need the clone method for Rectangle in Android.
Android has Rect instead of Rectangle. But it doesn' t have clone()
method.
Is there any method equivalent with clone()
Rect
has a copy constructor Rect(Rect)
that you can use for cloning:
Rect duplicatedRect = new Rect(originalRect);