[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: OOP and load/save
From: |
John W. Eaton |
Subject: |
Re: OOP and load/save |
Date: |
Thu, 23 Apr 2009 13:02:22 -0400 |
On 23-Apr-2009, Judd Storrs wrote:
| I don't know anything about the interpreter's internals, but it occurs to me
| that another approach would be to always read in objects from files as
| structs always and then attempt to do whatever class(obj,name) does. That
| way if the class() call fails, the struct is already there?
Doing that requires special knowledge about the way an octave_class
object is defined and breaks the model of having the object load
itself. At the point where enough information has been read from the
file to know that there is a problem, an octave_class object has
already been constructed, not an octave_map (struct) object. Yes, we
could have a special case for class objects, but I don't think that's
a good solution. We can probably do better than that, but as I said,
I think it will require some fairly substantial changes. Doing it
cleanly and consistently for all objects may require breaking backward
compatibility for objects defined in C++ classes. Not all of these
are part of Octave itself (for example, the fixed class in Octave
Forge).
jwe
- Re: OOP and load/save, (continued)
- Re: OOP and load/save, John W. Eaton, 2009/04/23
- Re: OOP and load/save, Robert T. Short, 2009/04/23
- Re: OOP and load/save, Judd Storrs, 2009/04/23
- Re: OOP and load/save, Judd Storrs, 2009/04/23
- Re: OOP and load/save, John W. Eaton, 2009/04/23
- Re: OOP and load/save, Judd Storrs, 2009/04/23
- Re: OOP and load/save, John W. Eaton, 2009/04/23
- Re: OOP and load/save, Judd Storrs, 2009/04/23
- Re: OOP and load/save, Robert T. Short, 2009/04/23
- Re: OOP and load/save, Judd Storrs, 2009/04/23
- Re: OOP and load/save,
John W. Eaton <=
- Re: OOP and load/save, Robert T. Short, 2009/04/23
- Re: OOP and load/save, John W. Eaton, 2009/04/23
- Re: OOP and load/save, Robert T. Short, 2009/04/23
- Re: OOP and load/save, Judd Storrs, 2009/04/23
- Re: OOP and load/save, Robert T. Short, 2009/04/23
- Re: OOP and load/save, Judd Storrs, 2009/04/24
- Re: OOP and load/save, Robert T. Short, 2009/04/24
- Re: OOP and load/save, John W. Eaton, 2009/04/24
- Re: OOP and load/save, Robert T. Short, 2009/04/24
- Re: OOP and load/save, Judd Storrs, 2009/04/24