361 |
clazz = classification.Classification() |
clazz = classification.Classification() |
362 |
|
|
363 |
try: |
try: |
364 |
|
self.__classification = clazz |
365 |
clazz._set_layer(self) |
clazz._set_layer(self) |
366 |
|
|
367 |
# only change things after a successful call |
# only change things after a successful call |
368 |
if old_class is not None: |
if old_class is not None: |
369 |
old_class._set_layer(None) |
old_class._set_layer(None) |
|
self.__classification = clazz |
|
370 |
except ValueError: |
except ValueError: |
371 |
|
self.__classification = old_class |
372 |
raise ValueError |
raise ValueError |
373 |
|
|
374 |
# we don't need this since a message will be sent |
# we don't need this since a message will be sent |