In reply to ChChee:
Yes… “this” refers to class my_env.
The ‘this’ keyword is used to refer to class properties, parameters and methods of the current instance.
when class object is created, new() will be called and one_env will assign ‘this’. This process is irrespective of calling get_env() method.
get_env() is only used to get the class handle. calling this function doesn’t change value of ‘one_env’.