Info

Diese Frage ist geschlossen. Öffnen Sie sie erneut, um sie zu bearbeiten oder zu beantworten.

Handling Member Objects in loadobj() that no longer exist

2 Ansichten (letzte 30 Tage)
Joseph Burgel
Joseph Burgel am 13 Okt. 2011
Geschlossen: MATLAB Answer Bot am 20 Aug. 2021
I've got a situation where ObjA had a property of type ObjB. ObjA was then saved to a file. Then, ObjB was moved to +PackageA.ObjB. Before the loadobj() method of ObjA fires, it tries to instantiate ObjB but can't find the class definition for it because it was moved and is now PackageA.ObjB. How would I handle backward compatibility for objects that no longer exist? Do I just live with the warning:
Warning: Error loading an object of class 'ObjB': Its class cannot be found.
Do I need to still maintain a definition for ObjB? - probably I'm guessing eh?
Thanks,

Antworten (0)

Diese Frage ist geschlossen.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by