And move the IsValidObject to the .cpp file

Signed-off-by: Stefan Marr <git@stefan-marr.de>