citySearcher.py

import logging

# returns corresponding tempAbbr, tempStdCountryName, tempGEO for given countryName
def citySearcher(cityName, citySearcherDic):
cityName = cityName.upper()
if cityName in citySearcherDic.keys():
tempAbbr, tempStdCountryName, tempGEO = citySearcherDic[cityName]

else:
tempAbbr = ""
tempStdCountryName = ""
tempGEO = ""
logging.info("No corresponding info (Abbr, stdCntryName, GEO) was found for city: " + cityName)
return tempAbbr, tempStdCountryName, tempGEO
上一篇:idea运行springMVC的helloworld刷新maven后报404


下一篇:关于近期CentOS 6.X系列各大开源镜像站Yum源失效404问题解决