single array or many single argument to call a constructor with params? I am seeing it more and more.

Which do you think works best and why?

This:

$config = array(
'param1'=&gt;'abc'
'param2'=&gt;'dfg'
);

new Class($config);


Or:

new Class('abc','dfg');
I'd always use the second version, since one could use type-hinting. The array style is less transparent.

At least the array style should read like this:

$config = array(
 Class::PARAM_1_INFO =&gt;'abc'
 Class::PARAM_1_SOMETHING =&gt;'dfg'
);


This way, Class is the single point, where the keys get defined.