def pmtrLibParser(usrStr): """convert lib names into user strings >>> pmtrLibParser('g') 'genPmtrObjs' """ parsed = drawer.acronymExpand(usrStr, pmtrLibNames) if parsed == None: raise ValueError, 'bad parameter library provided: %s' % usrStr return parsed
def tmTypeParser(typeName): """utility functions for parsing user strings of texture namess >>> tmTypeParser('lv') 'LiteralVertical' """ parsed = drawer.acronymExpand(typeName, tmNames) if parsed == None: pass return parsed
def pmtrLibParser(usrStr): """convert lib names into user strings >>> pmtrLibParser('g') 'genPmtrObjs' """ parsed = drawer.acronymExpand(usrStr, pmtrLibNames) if parsed == None: raise ValueError('bad parameter library provided: %s' % usrStr) return parsed
def outputExportFormatParser(typeName): """ does not raise an error if no match: returns string as none >>> outputExportFormatParser('af') 'audioFile' >>> outputExportFormatParser('ts') 'textSpace' """ parsed = drawer.acronymExpand(typeName, outputExportFormatNames) if parsed == None: pass return parsed
def orcTypeParser(typeName): """utility functions for parsing user paramter strings into proper parameter names. accepts short names and long names, regardless of case does not raise an error if no match: returns string unmodified """ return drawer.acronymExpand(typeName, orcNames) # may be none