+ #for time, code, msg in timer.log_entries:
+ #t.appendChild(doc.createTextNode("\t\t"))
+ #l = doc.createElement('log')
+ #l.setAttribute("time", str(time))
+ #l.setAttribute("code", str(code))
+ #l.appendChild(doc.createTextNode(msg))
+ #t.appendChild(l)
+ #t.appendChild(doc.createTextNode("\n"))
+
+ #root_element.appendChild(t)
+ #t = doc.createTextNode("\n")
+ #root_element.appendChild(t)
+
+
+ #file = open(self.Filename, "w")
+ #doc.writexml(file)
+ #file.write("\n")
+ #file.close()
+
+ list = []
+
+ list.append('<?xml version="1.0" ?>\n')
+ list.append('<timers>\n')
+
+ for timer in self.timer_list + self.processed_timers:
+ list.append('<timer')
+ list.append(' begin="' + str(int(timer.begin)) + '"')
+ list.append(' end="' + str(int(timer.end)) + '"')
+ list.append(' serviceref="' + str(timer.service_ref) + '"')
+ list.append(' repeated="' + str(int(timer.repeated)) + '"')
+ list.append(' name="' + str(self.strToXML(timer.name)) + '"')
+ list.append(' description="' + str(self.strToXML(timer.description)) + '"')
+ list.append(' eit="' + str(timer.eit) + '"')
+ list.append(' disabled="' + str(int(timer.disabled)) + '"')
+ list.append('>\n')
+
+ for time, code, msg in timer.log_entries:
+ list.append('<log')
+ list.append(' code="' + str(code) + '"')
+ list.append(' time="' + str(time) + '"')
+ list.append('>')
+ list.append(str(msg))
+ list.append('</log>\n')
+
+
+ list.append('</timer>\n')
+
+ list.append('</timers>\n')