A bit of a weird question but I was wondering anyone could help...
In C++, I could do something like this
class MyOtherClass
{
private:
If the type is a reference type (which is the case for classes), then you will copy the reference, not the object itself.
In opposition to reference type, you have value types. Values types are basically basic types : int
, double
, etc,
In your case, that means that you will work with the same objects, whether you access it from the class, or from the outer calling method. It's because you are targeting the referenced object.