34 def initialize(self): |
34 def initialize(self): |
35 """ |
35 """ |
36 Public method to initialize the object. |
36 Public method to initialize the object. |
37 """ |
37 """ |
38 return |
38 return |
|
39 |
|
40 def buildErrorMessage(self, msg): |
|
41 """ |
|
42 Public method to build an error string to be included in the scene. |
|
43 |
|
44 @param msg error message |
|
45 @type str |
|
46 @return prepared error string |
|
47 @rtype str |
|
48 """ |
|
49 return ( |
|
50 "<font color='{0}'>".format( |
|
51 self.umlView.getDrawingColors()[0].name()) + |
|
52 msg + |
|
53 "</font>" |
|
54 ) |
39 |
55 |
40 def buildDiagram(self): |
56 def buildDiagram(self): |
41 """ |
57 """ |
42 Public method to build the diagram. |
58 Public method to build the diagram. |
43 |
59 |
77 |
93 |
78 @return dictionary containing data to be persisted |
94 @return dictionary containing data to be persisted |
79 @rtype dict |
95 @rtype dict |
80 """ |
96 """ |
81 return {} |
97 return {} |
|
98 |
|
99 def fromDict(self, version, data): |
|
100 """ |
|
101 Public method to populate the class with data persisted by 'toDict()'. |
|
102 |
|
103 @param version version of the data |
|
104 @type str |
|
105 @param data dictionary containing the persisted data |
|
106 @type dict |
|
107 @return tuple containing a flag indicating success and an info |
|
108 message in case the diagram belongs to a different project |
|
109 @rtype tuple of (bool, str) |
|
110 """ |
|
111 return True, "" |