On Thursday 15 April 2010 21:33:45 P Zoltan wrote: > Then getting the model is currently not possible. Not a big problem, can > be fixed with the interfaces. Yes, I will add it to the IDocument interface today. Patches will follow, soon.
> Now I'm thinking how hook up the simulator. > > The debugController might be useful for running PIC programs. It might be > usef for circuits, too, but I don't know which one is the better solution: > implement the IDebugSesstion interface or subclass the Core and add > SimulatorController type member, where the documents can register > themselves. It's not obvious. I thought about implementing some kdevelop interface, too. IDebugSessions sound promising, also the ILaunch* interfaces could be interesting. > For simulation we need: > - the actual simulator, for different document types I'd suggest different simulator plugins that are loaded for different mime types (of the document). So the simulator does nothing like: if (document.type() == "foo") { //bar } but there is an abstract factory and you ask it to create a simulator for a document with mime-type circuit. > - a way to register new component models for a simulator class/document > type, in order to be loaded from plugins > - the models for the compoennts New models can also be provided by plugins. We should have a basic ComponentModelPlugin interace and the simulator just uses the PluginController to retreive a List of plugins that provide a model for component X. > So one way to do this might be: > create an ISimulatorController. It contains a list of registered component > types and the factories associated with them, and also a list of document > types and document simulator factories. > When a new document is created, it creates a new document simulator with > the document type (great, now we will again have document.type()), and > attaches the simulator to the document model. Then the document simulator > on each model change can rebuild the structure formed by the models. Also, > when a given time elapses, the document simulator runs a step in > simulation. I don't think a SimulatorController will be necessary. At least no new interface might be needed for that. I'm not sure, but we might be able to implement some existing interface to act as a SimulatorController. I haven't thought much about that part, yet. bye then julian ------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev _______________________________________________ Ktechlab-devel mailing list Ktechlab-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/ktechlab-devel