Extending the IProjectFileManager interface
Andras Mantia
amantia at kde.org
Tue Jul 3 19:10:57 UTC 2007
On Tuesday 03 July 2007, Andreas Pakulat wrote:
> On 03.07.07 21:10:05, Andras Mantia wrote:
> > we are discussing here with Jens the need of storing certain
> > information for each file inside the project. One case in Quanta
> > would be storing information about uploads (to the web server):
> > when the file was last uploaded, should it be uploaded or not at
> > all, should it be uploaded without asking the user for
> > confirmation.
>
> Such information should be included in the ProjectItem's.
Exactly what Alexander wrote on IRC. Good point!
> > Our idea was to store such information in the project
> > configuration file (the "local" one if such exists now, not the one
> > that is shared between users).
>
> Yes, thats what the projectmanager does when importing the file.
BTW, I couldn't find how to access the local file. It seems to be
commented out now.
> > 1) Extend IProjectFileManager with the needed methods (probably
> > something like writeProperty(ProjectItem*, key, value) and
> > readProperty(ProjectItem*, key) ).
>
> Why would this be needed? Those extra informations can be stored by
> the projectmanager via obtaining the project configuration and write
> to it the information you need to store. I don't see why this would
> be needed.
We want to avoid having all plugins accessing directly the config file
and doing the same thing. Also Quanta might want to store information
how I told, but maybe QMake or CMake project wants to store some
information in other form. Still this would be transparent to the
plugin that writes or read the properites.
> Of course this means duplicating such things among the various
> project managers. So the question I'm really asking: Can you give me
> some use-cases which wouldn't be easily possible without such (or
> similar, like Alex said) API?
I gave the use case for which we need right now: the upload plugin. And
I want to avoid config file manipulation directly from the plugin.
Andras
--
Quanta Plus developer - http://quanta.kdewebdev.org
K Desktop Environment - http://www.kde.org
More information about the KDevelop-devel
mailing list