14 *******************************************************************************
16 * Simple example (identical to C++ Properties.opts) which illustrated *
17 * the basic job-properties and theinr C++/Python intercommunication *
19 *******************************************************************************
23 __author__ =
"Vanya BELYAEV ibelyaev@physics.syr.edu"
34 SUCCESS = gaudimodule.SUCCESS
41 """the configurtaion of the job"""
45 gaudi = gaudimodule.AppMgr()
48 gaudi.config(files=[
"../options/Common.opts"])
52 gaudi.TopAlg = [
"PropertyAlg"]
55 gaudi.TopAlg += [
"PropertyAlg",
"PropertyProxy"]
58 gaudi.TopAlg.remove(
"PropertyAlg")
62 msgSvc = gaudi.service(
"MessageSvc")
63 msgSvc.OutputLevel = 3
67 gaudi.HistogramPersistency =
"NONE"
71 alg = gaudi.algorithm(
"PropertyAlg")
77 alg.String =
"hundred one"
80 alg.IntArray = [1, 2, 3, 5]
81 alg.DoubleArray = [-11.0, 2.0, 3.3, 0.4e-03]
82 alg.StringArray = [
"one",
"two",
"four"]
83 alg.BoolArray = [
False,
True,
False]
88 alg.PString =
"hundred one"
91 alg.PIntArray = [1, 2, 3, 5]
92 alg.PDoubleArray = [1.1, 2.0, 3.3]
93 alg.PStringArray = [
"one",
"two",
"four"]
94 alg.PBoolArray = [
True,
False,
True,
False]
96 proxy = gaudi.algorithm(
"PropertyProxy")
97 proxy.String =
"This is set by the proxy"
99 msgSvc.setDebug = [
"EventLoopMgr"]
100 msgSvc.setVerbose = [
"MsgTest"]
110 if "__main__" == __name__:
111 print(__doc__, __author__)
113 gaudi = gaudimodule.AppMgr()
117 alg = gaudi.algorithm(
"PropertyAlg")
119 props = alg.properties()
120 print(
"Properties of %s " % alg.name())
123 print(
"Python: Name/Value: '%s' / '%s' " % (p, v))