本文整理匯總了Python中suds.client.Client.put方法的典型用法代碼示例。如果您正苦於以下問題:Python Client.put方法的具體用法?Python Client.put怎麽用?Python Client.put使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類suds.client.Client
的用法示例。
在下文中一共展示了Client.put方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: open
# 需要導入模塊: from suds.client import Client [as 別名]
# 或者: from suds.client.Client import put [as 別名]
inv.visitId = "43"
inv.title = "billInvestigationtitle"
inv.type = itype
inv.id = service.create(sessionId, inv)
dtype = factory.create("datasetType")
dtype.facility = facility
dtype.name = "billDatasetType"
dtype.id = service.create(sessionId, dtype)
dataset = factory.create("dataset")
dataset.investigation = inv
dataset.name = "billDatasetname"
dataset.type = dtype
dataset.id = service.create(sessionId, dataset)
dformat = factory.create("datafileFormat")
dformat.facility = facility
dformat.name = "billDatafileformat"
dformat.version = "4.3.0"
dformat.id = service.create(sessionId, dformat)
f = open("a.b", "w")
wibbles = ""
for i in range(100000):
wibbles += str(i) + " wibble "
f.write(wibbles)
f.close()
f = open("a.b")
print "file bill before", service.search(sessionId, "Datafile [name = 'bill']")
dfid = client.put(sessionId, f, "bill", dataset.id, dformat.id, "Description")
f.close()
print "file bill after", service.search(sessionId, "Datafile [name = 'bill']")