Commits

Marcin Kasperski committed 38b42d6

Problematic example provided by Tim Cook (mlhim). Saved to verify whether
there is a problem and possibly convert to unittest (nice feature-rich
mindmap among the others)

Comments (0)

Files changed (3)

examples/miscellaneous/README.txt

+This directory contains code snippets used to test some functionality
+or verify problem, but generally not intended to be used as examples
+or demonstrations.

examples/miscellaneous/mlhim/openEHR-EHR-OBSERVATION.apgar.v1.xmind

Binary file added.

examples/miscellaneous/mlhim/xmindparse.py

+from mekk.xmind import XMindDocument
+
+xmind = XMindDocument.open("openEHR-EHR-OBSERVATION.apgar.v1.xmind")
+
+ccd_sheet = xmind.get_first_sheet()
+
+ccd = ccd_sheet.get_root_topic()
+print "CCD Title:       ", ccd.get_title()
+print "CCD Template Id: ", ccd.get_correlation_id()
+# here we need to compare the id to know which CCD template is being used.
+
+for cl in ccd.get_subtopics():  #current level
+    if cl.get_title() == 'definition':
+        x = True
+        while x:
+            nl = cl.get_suptopics() # next level generator
+            for cl in nl:
+                print cl.get_title()
+                if cl is None:
+                    x = False
+            
+