Generating get_class/trim/strtoupper code [ci skip]