VCS Interface classes
Matthew Woehlke
mw_triad at users.sourceforge.net
Thu May 3 19:09:04 UTC 2007
Jakob Petsovits wrote:
> Btw, I had a short look on how MonoDevelop do their VCS stuff.
> As one could expect, they are working with abstract classes instead of
> interfaces, so they add a lot of default code into their template classes.
> [snip]
> Specific stuff that could be interesting for us:
>
> - Instead of edit() and unedit(), they've got RequestFileWritePermission() and
> NotifyFileChanged() which is called on saving the file.
Naming. Also, we already talked about how to be notified on write. So
we're the same, here.
> - Overall, they've got a good amount of Can*(localPath) methods:
> CanAdd(), CanUpdate(), CanCommit(), CanRemove(), CanRevert(),
> CanLock() and CanUnlock().
That, I think, is exactly what we are trying to /avoid/ by defining
multiple sets of optional interfaces. This way, you get this information
by asking 'do you implement IFoo?'.
> - Move and Delete actions get an additional "bool force" parameter.
> I think that one would come in handy for us as well, probably as an enum
> instead of a bool.
What would "force" do? Is it needed for some reason?
> - Their DiffInfo class is a structure consisting of string fileName and
> string content, where content is an actual unified diff, if I read that
> correctly.
Check out the latest version of diff(). :-)
> - Their Revision class contains a DateTime as only "revision name", and also
> stores author and commit message as well as the Repository it belongs to, and
> (optionally) a changedFiles array, the latter one consisting of string path,
> commit action (enum with Add, Delete, Replace, Modify, Other) and
> string actionDescription (??).
Yes, we need a method to get the list of files, if supported. Andreas
and I were talking about this, it should be in there soon.
--
Matthew
Disadvantage: Bad Puns [-5]
You constantly utter puns so egregious as to cause mental distress to
anyone hearing them. This can, however, be used to distract enemies.
More information about the KDevelop-devel
mailing list