Graphics/UMLDiagramBuilder.py

changeset 2031
c36c2eb62a75
child 2033
4b99609f6a87
equal deleted inserted replaced
2030:db11a2fe9bbc 2031:c36c2eb62a75
1 # -*- coding: utf-8 -*-
2
3 # Copyright (c) 2012 Detlev Offenbach <detlev@die-offenbachs.de>
4 #
5
6 """
7 Module implementing the UML diagram builder base class.
8 """
9
10 from PyQt4.QtCore import QObject
11
12
13 class UMLDiagramBuilder(QObject):
14 """
15 Class implementing the UML diagram builder base class.
16 """
17 def __init__(self, dialog, view, project):
18 """
19 Constructor
20
21 @param dialog reference to the UML dialog (UMLDialog)
22 @param view reference to the view object (UMLGraphicsView)
23 @param project reference to the project object (Project)
24 """
25 super().__init__(dialog)
26
27 self.umlView = view
28 self.scene = self.umlView.scene()
29 self.project = project
30
31 def buildDiagram(self):
32 """
33 Public method to build the diagram.
34
35 This class must be implemented in subclasses.
36 """
37 raise NotImplementedError(
38 "Method 'buildDiagram' must be implemented in subclasses.")
39
40 def parsePersistenceData(self, data):
41 """
42 Public method to parse persisted data.
43
44 @param dat persisted data to be parsed (string)
45 """
46 return

eric ide

mercurial