9 |
9 |
10 from E5Gui.E5Application import e5App |
10 from E5Gui.E5Application import e5App |
11 |
11 |
12 from .Config import sessionFileFormatVersion |
12 from .Config import sessionFileFormatVersion |
13 from .XMLStreamReaderBase import XMLStreamReaderBase |
13 from .XMLStreamReaderBase import XMLStreamReaderBase |
|
14 |
14 |
15 |
15 class SessionReader(XMLStreamReaderBase): |
16 class SessionReader(XMLStreamReaderBase): |
16 """ |
17 """ |
17 Class for reading an XML session file. |
18 Class for reading an XML session file. |
18 """ |
19 """ |
45 if editor is not None: |
46 if editor is not None: |
46 editor.clearBookmarks() |
47 editor.clearBookmarks() |
47 self.dbs.getBreakPointModel().deleteAll() |
48 self.dbs.getBreakPointModel().deleteAll() |
48 self.dbs.getWatchPointModel().deleteAll() |
49 self.dbs.getWatchPointModel().deleteAll() |
49 |
50 |
50 def readXML(self, quiet = False): |
51 def readXML(self, quiet=False): |
51 """ |
52 """ |
52 Public method to read and parse the XML document. |
53 Public method to read and parse the XML document. |
53 |
54 |
54 @param quiet flag indicating quiet operations. |
55 @param quiet flag indicating quiet operations. |
55 If this flag is true, no errors are reported. |
56 If this flag is true, no errors are reported. |
201 weSpecialCond = "" |
202 weSpecialCond = "" |
202 |
203 |
203 while not self.atEnd(): |
204 while not self.atEnd(): |
204 self.readNext() |
205 self.readNext() |
205 if self.isEndElement() and self.name() == "Watchexpression": |
206 if self.isEndElement() and self.name() == "Watchexpression": |
206 self.dbs.getWatchPointModel().addWatchPoint(weCond, |
207 self.dbs.getWatchPointModel().addWatchPoint(weCond, |
207 (weTemp, weEnabled, weCount, weSpecialCond)) |
208 (weTemp, weEnabled, weCount, weSpecialCond)) |
208 break |
209 break |
209 |
210 |
210 if self.isStartElement(): |
211 if self.isStartElement(): |
211 if self.name() == "Condition": |
212 if self.name() == "Condition": |