Don't generate wrapper methods if is not necessary: thanks to
Florian Brosch.