Add OOPHelper with one static function for object casting.
Sanity checks.