1 # Copyright (C) 2016-2021 CEA/DEN, EDF R&D
3 # This library is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU Lesser General Public
5 # License as published by the Free Software Foundation; either
6 # version 2.1 of the License, or (at your option) any later version.
8 # This library is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 # Lesser General Public License for more details.
13 # You should have received a copy of the GNU Lesser General Public
14 # License along with this library; if not, write to the Free Software
15 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
24 def __GenerateID(cls):
28 def __init__( self, controller ):
32 self._controller = controller
33 self._id = self.__GenerateID() # A unique ID for this class of object
38 def getController(self):
40 :returns: Controller -- This model's controller.
42 return self._controller
44 def setController(self, controller):
46 Sets the controller of this model.
48 :param controller: Controller -- The controller of the model.
51 self._controller = controller
53 def notifyChange( self, what="" ) :
55 Notifies the controller that this model's data has changed.
57 if self._controller != None:
58 self._controller.notify(self, what)
60 def updateTimeStamps (self, modifiesList):
61 raise NotImplementedError