in reply to Most Efficient

This is more a design question than programming one. Important fact here is the relation of 'param' to class Temp.

If 'param' is a natural part of class Temp, that second (aggregation) example is much better. Value of 'param' can now be used by all methods of object 'Temp'. This scenario is usualy used in container-element relation, like relation between object 'User' and object 'Address'. Address is a natural part of user description.

If 'param' is just a parameter that influence execution of method test(), and test is the only method that is influenced by param, that the first example is better. For example if you have method auth() in object User, this method could have parameter '$password' that should be compared to password stored in object User and returns true or false value. There is no need for $password parameter to be used by other methods but auth().