add native method class optimized for typed class