Shouldn't we use __PACKAGE__ rather than ref($this) ?