Exemplo n.º 1
0
def getMaskMakerRunNamesFromSession(sessiondata):
	mquery = appiondata.ApMaskMakerRunData(session=sessiondata)
	results = mquery.query()

	if not results:
		return []
	masknames = map((lambda x:x['name']),results)
	return masknames
Exemplo n.º 2
0
def getMaskParamsByRunName(name,sessiondata):
	maskRq=appiondata.ApMaskMakerRunData()
	maskRq['name']=name
	maskRq['session']=sessiondata
	# get corresponding makeMaskParams entry
	result = maskRq.query()
	if len(result) > 0:
		return result[0],result[0]['params']
	else:
		return None,None
Exemplo n.º 3
0
def createMaskMakerRun(sessiondata,path,name,paramdata):
	if path is None:
		savepath = None
	else:
		savepath = os.path.normpath(path)
	maskRdata=appiondata.ApMaskMakerRunData()
	maskRdata['session'] = sessiondata
	if savepath is not None:
		maskRdata['path']= appiondata.ApPathData(path=os.path.abspath(savepath))
	maskRdata['name']=name
	maskRdata['params']=paramdata

	return maskRdata
Exemplo n.º 4
0
def getMaskMakerRunDataById(id):
	mquery = appiondata.ApMaskMakerRunData(DEF_id=id)
	results = mquery.query()
	return results