Refactor ProfilerSimple
authorOri Livneh <ori@wikimedia.org>
Tue, 31 Dec 2013 23:33:07 +0000 (15:33 -0800)
committerOri Livneh <ori@wikimedia.org>
Tue, 31 Dec 2013 23:55:03 +0000 (15:55 -0800)
commit38f267f402295b770d1ac14239fc576162e477ca
tree1faf5c3c323ab3181d9e2a7e71705a79bb941584
parenteb08b156c8853785190d8dbbfed1bdaee76b0905
Refactor ProfilerSimple

This patch refactors ProfilerSimple, moving the code that creates a new
profiling entry and the code that updates an existing entry to discrete
methods. This allows subclasses to supply a different implementation. It will
allow me to introduce a profiler class that uses RunningStat (introduced in
Ifedda276d) without breaking existing APIs and without having to duplicate lots
of code.

Change-Id: Ida7d7d0c1e2a98618b51246861e6af8ec3eb6320
includes/profiler/ProfilerSimple.php