import sys
# Modeling
from Modeling.CustomObject import CustomObject
class ClassE (CustomObject):
"""
ClassEs are objects ...
"""
__implements__ = CustomObject.__implements__
_e1=None
_toA=None
def entityName(self):
"Used by the modelization_tool to link this object to an entity"
return "E" # do not change
def __init__( self ):
pass
# Attributes
# =================== e1 ==========================
def getE1(self):
"Return the ClassE / e1 attribute value"
self.willRead()
return self._e1
def setE1(self,e1):
"Change the ClassE / e1 attribute value"
self.willChange()
self._e1 = e1
def validateE1(self, value):
"Edit this to enforce custom business logic"
if 0: # your custom bizlogic
raise Validation.Exception
return
# Relationships
def getToA(self):
"Return the toA relationship"
self.willRead()
return self._toA
def setToA(self,object):
"Set the toA relationship to many"
self.willChange()
self._toA=object
|