now supports class methods