saveobj
- :
b =saveobj(a)¶ Class method run on an object just before
savewrites it.A class that defines
saveobjgets the chance to replace the object a with the version b that should actually go to the file: typically a copy with transient fields dropped, or with derived fields filled in so that the saved form is complete. Such a class normally also definesloadobjto undo the transformation. A minimal method that strips a cache field:function b = saveobj (a) b = a; b.cache = []; endfunction