source: mauRepo/CedaMolesModel/trunk/ceda_moles_model/ea_model/iso_19136_gml/geometryprimitives/circlebycenterpoint.py @ 8457

Subversion URL: http://proj.badc.rl.ac.uk/svn/ndg/mauRepo/CedaMolesModel/trunk/ceda_moles_model/ea_model/iso_19136_gml/geometryprimitives/circlebycenterpoint.py@8457
Revision 8457, 3.2 KB checked in by mnagni, 7 years ago (diff)

Corrected an error in the generation of the classes "synchronize" method.

  • Property svn:mime-type set to text/plain
RevLine 
[8397]1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21from ea_model.iso_19136_gml.geometryprimitives.arcbycenterpoint import  ArcByCenterPoint
22from ascore.utils import has_value, collectionProofHash
23
24'''
[8457]25Created on 10-Jul-2012 14:15:14
[8397]26
27@author: mnagni
28'''
29
30class CircleByCenterPoint(ArcByCenterPoint):
31        '''
32                Represents a data entity defined in a UML diagram and supposed to
33                be persisted in a relational database.
34 
35                This class has been genererated automatically using the Apache Velocity project.
36        '''
37        '''
38                Please note that any access to the inner attributes should be done using
39                the given get/set methods and NOT accessing them directly.
40        '''
41        def __init__(self):
42                self._arcbycenterpoint = ArcByCenterPoint()     
43
[8437]44                self.startAngle = None
[8397]45                self.radius = None
[8457]46                self.curve = None
[8437]47                self.numDerivativesAtEnd = None
[8397]48                self.interpolation = None
49                self.numDerivativesAtStart = None
50                self.numDerivativeInterior = None
51                self.endAngle = None
52                self.controlPoint = None
53                super(CircleByCenterPoint, self).__init__()
54        @property
[8437]55        def startAngle(self):   
56                return self._arcbycenterpoint.startAngle
57
58        @startAngle.setter
59        def startAngle(self, value):   
60                        self._arcbycenterpoint.startAngle = value
61        @property
[8397]62        def radius(self):       
63                return self._arcbycenterpoint.radius
64
65        @radius.setter
66        def radius(self, value):       
67                        self._arcbycenterpoint.radius = value
68        @property
[8457]69        def curve(self):       
70                return self._arcbycenterpoint.curve
71
72        @curve.setter
73        def curve(self, value):
74                        self._arcbycenterpoint.curve = value
75        @property
[8437]76        def numDerivativesAtEnd(self): 
77                return self._arcbycenterpoint.numDerivativesAtEnd
[8397]78
[8437]79        @numDerivativesAtEnd.setter
80        def numDerivativesAtEnd(self, value):   
81                        self._arcbycenterpoint.numDerivativesAtEnd = value
[8397]82        @property
83        def interpolation(self):       
84                return self._arcbycenterpoint.interpolation
85
86        @interpolation.setter
87        def interpolation(self, value):
88                        self._arcbycenterpoint.interpolation = value
89        @property
90        def numDerivativesAtStart(self):       
91                return self._arcbycenterpoint.numDerivativesAtStart
92
93        @numDerivativesAtStart.setter
94        def numDerivativesAtStart(self, value):
95                        self._arcbycenterpoint.numDerivativesAtStart = value
96        @property
97        def numDerivativeInterior(self):       
98                return self._arcbycenterpoint.numDerivativeInterior
99
100        @numDerivativeInterior.setter
101        def numDerivativeInterior(self, value):
102                        self._arcbycenterpoint.numDerivativeInterior = value
103        @property
104        def endAngle(self):     
105                return self._arcbycenterpoint.endAngle
106
107        @endAngle.setter
108        def endAngle(self, value):     
109                        self._arcbycenterpoint.endAngle = value
110        @property
111        def controlPoint(self):
112                return self._arcbycenterpoint.controlPoint
113
114        @controlPoint.setter
115        def controlPoint(self, value): 
116                        self._arcbycenterpoint.controlPoint = value
117
118        def synchronize(self):
119                pass
120
121        def __key(self):
[8457]122                return (self.startAngle, self.radius, self.curve, self.numDerivativesAtEnd, self.interpolation, self.numDerivativesAtStart, self.numDerivativeInterior, self.endAngle, self.controlPoint)
[8397]123
124        def __eq__(self, y):
125                if type(self) != type(y):
126                        return False
127                '''
128                Cannot compare classes which do not define a "__key" attribute
129                '''
130                if hasattr(self, '_%s__key' % (type(self).__name__)) and hasattr(y, '_%s__key' % (type(y).__name__)):
131                        return self.__key() == y.__key()
132                return id(self) == id(y)
133
134        def __hash__(self):
135                return collectionProofHash(self.__key())
Note: See TracBrowser for help on using the repository browser.