本文整理匯總了Python中OrangeGbl.xstr方法的典型用法代碼示例。如果您正苦於以下問題:Python OrangeGbl.xstr方法的具體用法?Python OrangeGbl.xstr怎麽用?Python OrangeGbl.xstr使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類OrangeGbl
的用法示例。
在下文中一共展示了OrangeGbl.xstr方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: ParseGooglePlacesMain
# 需要導入模塊: import OrangeGbl [as 別名]
# 或者: from OrangeGbl import xstr [as 別名]
def ParseGooglePlacesMain(Asset, AAsset):
if gL.trace: gL.log(gL.DEBUG)
try:
gL.cMySql.execute("Select * from QAddress where Asset = %s", ([Asset]))
row = gL.cMySql.fetchone()
if not row:
gL.log(gL.ERROR, "asset:" + str(Asset))
return False
country = row['Country']
assettype = row['AssetType']
source = row['Source']
starturl = row['StartUrl']
asseturl = row['AssetUrl']
name = row['name']
address = row['address']
addrstreet = row['addrstreet']
addrcity = row['addrcity']
addrzip = row['addrzip']
addrcounty = row['addrcounty']
gAsset = gL.ParseGooglePlaces(Asset, assettype, name, gL.xstr(addrstreet), gL.xstr(addrzip), gL.xstr(addrcity), gL.xstr(country), gL.xstr(address), AAsset )
return gAsset
except Exception as err:
gL.log(gL.ERROR, "asset:" + str(Asset))
gL.log(gL.ERROR, err)
return False