4 # |
4 # |
5 |
5 |
6 """ |
6 """ |
7 Module implementing an UML like class item. |
7 Module implementing an UML like class item. |
8 """ |
8 """ |
|
9 |
|
10 from __future__ import unicode_literals # __IGNORE_WARNING__ |
9 |
11 |
10 from PyQt4.QtGui import QFont, QGraphicsSimpleTextItem, QStyle |
12 from PyQt4.QtGui import QFont, QGraphicsSimpleTextItem, QStyle |
11 |
13 |
12 from .UMLItem import UMLModel, UMLItem |
14 from .UMLItem import UMLModel, UMLItem |
13 |
15 |
26 @param methods list of method names of the class |
28 @param methods list of method names of the class |
27 (list of strings) |
29 (list of strings) |
28 @param attributes list of attribute names of the class |
30 @param attributes list of attribute names of the class |
29 (list of strings) |
31 (list of strings) |
30 """ |
32 """ |
31 super().__init__(name) |
33 super(ClassModel, self).__init__(name) |
32 |
34 |
33 self.methods = methods |
35 self.methods = methods |
34 self.attributes = attributes |
36 self.attributes = attributes |
35 |
37 |
36 def addMethod(self, method): |
38 def addMethod(self, method): |