Back to index

salome-kernel  6.5.0
Functions | Variables
KERNEL_PY.PyInterp Namespace Reference

Functions

def DumpComponent
def DumpStudy

Variables

tuple orb = CORBA.ORB_init([''], CORBA.ORB_ID)
tuple lcc = LifeCycleCORBA(orb)
tuple sg = SALOMEGUI_Swig()
tuple naming_service = SALOME_NamingServicePy_i(orb)
tuple myStudyName = sg.getActiveStudyName()
tuple myStudyId = sg.getActiveStudyId()
tuple obj = naming_service.Resolve('myStudyManager')
tuple myStudyManager = obj._narrow(SALOMEDS.StudyManager)
tuple myStudy = myStudyManager.GetStudyByName(myStudyName)

Function Documentation

def KERNEL_PY.PyInterp.DumpComponent (   Study,
  SO,
  offset 
)

Definition at line 38 of file PyInterp.py.

00038 
00039 def DumpComponent(Study, SO, offset):
00040     it = Study.NewChildIterator(SO)
00041     Builder = Study.NewBuilder()
00042     while it.More():
00043         CSO = it.Value()
00044         it.Next()
00045         anAttr = Builder.FindOrCreateAttribute(CSO, "AttributeName")
00046         AtName = anAttr._narrow(SALOMEDS.AttributeName)
00047         t_name = AtName.Value()
00048         if t_name[0] == 1:
00049             ofs = 1
00050             a = ""
00051             while ofs <= offset:
00052                 a = a + "--"
00053                 ofs = ofs +1
00054             print a + ">" + CSO.GetID() + " " + t_name[1]
00055         t_RefSO = CSO.ReferencedObject()
00056         if t_RefSO[0] == 1:
00057             RefSO = t_RefSO[1]
00058             ofs = 1
00059             a = ""
00060             while ofs <= offset:
00061                 a = a + "  "
00062                 ofs = ofs +1
00063             print a + ">" + RefSO.GetID()
00064         DumpComponent(Study, CSO, offset+2)
00065 
00066     #--------------------------------------------------------------------------

Here is the caller graph for this function:

Definition at line 67 of file PyInterp.py.

00067 
00068 def DumpStudy(Study):
00069     itcomp = Study.NewComponentIterator()
00070     while itcomp.More():
00071         SC = itcomp.Value()
00072         itcomp.Next()
00073         name = SC.ComponentDataType()
00074         print "-> ComponentDataType is " + name
00075         DumpComponent(Study, SC, 1)
00076         
00077 
00078     #--------------------------------------------------------------------------
00079 
# initialise the ORB

Here is the call graph for this function:


Variable Documentation

Definition at line 83 of file PyInterp.py.

tuple KERNEL_PY.PyInterp.myStudy = myStudyManager.GetStudyByName(myStudyName)

Definition at line 103 of file PyInterp.py.

tuple KERNEL_PY.PyInterp.myStudyId = sg.getActiveStudyId()

Definition at line 95 of file PyInterp.py.

Definition at line 100 of file PyInterp.py.

tuple KERNEL_PY.PyInterp.myStudyName = sg.getActiveStudyName()

Definition at line 92 of file PyInterp.py.

Definition at line 89 of file PyInterp.py.

tuple KERNEL_PY.PyInterp.obj = naming_service.Resolve('myStudyManager')

Definition at line 99 of file PyInterp.py.

tuple KERNEL_PY.PyInterp.orb = CORBA.ORB_init([''], CORBA.ORB_ID)

Definition at line 80 of file PyInterp.py.

tuple KERNEL_PY.PyInterp.sg = SALOMEGUI_Swig()

Definition at line 86 of file PyInterp.py.