import sys
# Modeling
from Modeling.CustomObject import CustomObject
class ClassC (CustomObject):
"""
ClassCs are objects ...
"""
__implements__ = CustomObject.__implements__
def entityName(self):
"Used by the modelization_tool to link this object to an entity"
return "C" # do not change
def __init__( self,
c1 = '',
):
c1 = self.setC1(c1)
self._toA=None
self._toA1=None
# Attributes
# =================== c1 ==========================
def getC1(self):
"Return the ClassC / c1 attribute value"
if not hasattr(self,'_c1') :
self._c1 = None
return self._c1
def setC1(self,c1):
"Change the ClassC / c1 attribute value"
self.willChange()
self._c1 = c1
def validateC1(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"
return self._toA
def setToA(self,object):
"Set the toA relationship to many"
self.willChange()
self._toA=object
def getToA1(self):
"Return the toA1 relationship"
return self._toA1
def setToA1(self,object):
"Set the toA1 relationship to many"
self.willChange()
self._toA1=object
|