Add utility methods used by the call stats code.

Change-Id: If000c0638af8b50654f2a3637e9a780759710502