Is this method signature is correct or not

Is this method signature is correct according to todos, it’s confusing.

yeah same problem here, how are you supposed to clone this ?

Yes, signature is correct you can use type casting. To type cast interface to interface implemented class and vice versa.

you mean like (implementedObjectName)InterfaceObject

but what is the use of this object. we can’t use it…it’s an object for an interface

but still youll need fileinfo to construct right ? do we make a new constructor in implementation class ?

It is not an object for an interface. Object is of type SourceFileVersionArrayListImpl and interface provides reference for this object.
This object cloning is done for copying functionality.

See there are multiple approaches to solve this cloning problem google it.
one is using copy constructor
second in using cloneable interface.
I recommend you to use cloneable interface.

Actually now i am getting this use ver to create new object for sourcefilearraylistimpl class and then pass fileinfo as an argument and return ver that’s it in my sence.

thanks i think i got it

this should help

This signature is completely fine, it’s a part of module 4 in this you new to return new object of SourceFileVsersionArrayListImpl

Don’t modify the name of the function else your tests will fail.

yes sir this issue is resolved

Awesome, please mark anyone of the above comments as solution. Which you think helped you in solving this query

Closing this topic as your issue is resolved by the mentor. If it is still not resolved, Kindly un-mark the accepted solution or create a new topic and post this question as a reference link in the description of the new topic.