|
Last change
on this file since 1341 was 1337, checked in by garnier, 15 years ago |
|
tag geant4.9.4 beta 1 + modifs locales
|
-
Property svn:executable
set to
*
|
|
File size:
496 bytes
|
| Line | |
|---|
| 1 | #!/usr/bin/python
|
|---|
| 2 | # ==================================================================
|
|---|
| 3 | # python script for Geant4Py test
|
|---|
| 4 | #
|
|---|
| 5 | #
|
|---|
| 6 | # ==================================================================
|
|---|
| 7 | import test12
|
|---|
| 8 |
|
|---|
| 9 | a= test12.AClass()
|
|---|
| 10 | a.ival=10
|
|---|
| 11 |
|
|---|
| 12 | b= test12.AClass()
|
|---|
| 13 | b.ival=20
|
|---|
| 14 |
|
|---|
| 15 | c= test12.AClass()
|
|---|
| 16 | c.ival=30
|
|---|
| 17 |
|
|---|
| 18 | v= test12.AVector()
|
|---|
| 19 | v[:]= [a, b, c]
|
|---|
| 20 |
|
|---|
| 21 | print "*** size of vector= ", len(v)
|
|---|
| 22 | x=v[0]
|
|---|
| 23 |
|
|---|
| 24 | print ""
|
|---|
| 25 | print "*** a vs v[0]"
|
|---|
| 26 | a.Print()
|
|---|
| 27 | x.Print()
|
|---|
| 28 |
|
|---|
| 29 | print ""
|
|---|
| 30 | print "*** dump vector..."
|
|---|
| 31 | test12.PrintVector(v)
|
|---|
| 32 |
|
|---|
| 33 |
|
|---|
| 34 |
|
|---|
| 35 |
|
|---|
| 36 |
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.