/[thuban]/branches/WIP-pyshapelib-bramz/Thuban/Model/classification.py
ViewVC logotype

Diff of /branches/WIP-pyshapelib-bramz/Thuban/Model/classification.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1908 by jonathan, Wed Jul 16 13:22:20 2003 UTC revision 1909 by bh, Fri Oct 31 18:16:34 2003 UTC
# Line 126  class Classification(Publisher): Line 126  class Classification(Publisher):
126    
127          group -- group that the value maps to.          group -- group that the value maps to.
128          """          """
   
129          assert isinstance(group, ClassGroupDefault)          assert isinstance(group, ClassGroupDefault)
130          if len(self.__groups) > 0:          if len(self.__groups) > 0:
131              self.__groups[0] = group              self.__groups[0] = group
132          else:          else:
133              self.__groups.append(group)              self.__groups.append(group)
134            self.__SendNotification()
135    
136      def GetDefaultGroup(self):      def GetDefaultGroup(self):
137          """Return the default group."""          """Return the default group."""
# Line 151  class Classification(Publisher): Line 151  class Classification(Publisher):
151          self.__SendNotification()          self.__SendNotification()
152    
153      def RemoveGroup(self, index):      def RemoveGroup(self, index):
154          return self.__groups.pop(index + 1)          """Remove the classification group with the given index"""
155            self.__groups.pop(index + 1)
156            self.__SendNotification()
157    
158      def ReplaceGroup(self, index, group):      def ReplaceGroup(self, index, group):
159          assert isinstance(group, ClassGroup)          assert isinstance(group, ClassGroup)

Legend:
Removed from v.1908  
changed lines
  Added in v.1909

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26