views:

605

answers:

3

One of the projects I'm working on involves a module that needs to allow end users to create what essentially equates to, their own "object classes," storing data structures / record types that they can design and modify at runtime. The users will also be able to customize the user interface considerably, but that is not so much the scope of this question.

The closest example to what we are striving to build with this functionality, that I've seen, would be something very akin to what InstantObjects provides at design time, except our system would provide it at runtime, and put the class design control in the hands of the end-user (who will generally be pretty technically sophisticated, obviously).

I recently came across this list of Object Persistence Frameworks for Delphi Win32: http://tdelphihobbyist.blogspot.com/2008/01/win32-object-persistence-frameworks.html

Any recommendations as to which of these might be the most conducive to the kind of runtime flexibility we are trying to create?

A: 

You can create some form of persistence using xml and then buil a form acordingly, we do this a lot for configurable filter windows for example

+3  A: 

There is currently ongoing discussion of this in the tiopf newsgroups. Tiopf is a open source object persistence framework. Currently it doesn't support user modifiable objects but it looks like someone will be adding this functionality shortly.

Main site: http://tiopf.sourceforge.net/ News groups: See http://tiopf.sourceforge.net/Support.shtml

See "tiOPF ad runtime modifications" thread in the support newsgroup.

SeanX
+2  A: 

JSON could be used to declare and modify user-defined data structures at runtime. There are two libraries for Delphi, SuperObject and lkJSON. With JSON, object hierarchies would be easy to build. The SuperObject demo sources include examples for many usage areas. SuperObject also contains iterator methods for a given JSON object structure. I use it for a Delphi client library which is able to exchange objects with Java using the ApacheMQ message broker.

mjustin