make getf* generic to support objects and hash-tables