Hello,
Currently I am working on groups in Nautilus, and I am actually reimplementing them because I could not just fix them (There are a lot of bugs which make them almost unusable in practice), it is too complicated for nothing. Doing this I somehow have to use RPackage announcements and I am a little bit confused by their name. When you remove a package, an announcement RPackageUnregistered is raised, but I do not know if there is a difference with RPackageRemoved (which by the way does not exist, but I was expecting a name like that). What is this registration thing ? There is no RPackageRegistered but there is RPackageCreated. So I am confused. Does someone know if I should create an announcement RPackageRemoved or rename RPackageCreated into RPackageRegistered ? It does not seem consistent and so it is confusing. Or can someone explain to me the notion of registration for the RPackages ? Thanks, Franck |
2015-07-18 15:48 GMT+02:00 Franck Warlouzet <[hidden email]>:
I don't know. I would rename RPackageCreated to RPackageRegistered. nicolai
|
In reply to this post by Franck Warlouzet
Hi Franck,
Le 18/07/2015 15:48, Franck Warlouzet a écrit : > Hello, > > Currently I am working on groups in Nautilus, and I am actually > reimplementing them because I could not just fix them (There are a lot > of bugs which make them almost unusable in practice), it is too > complicated for nothing. Doing this I somehow have to use RPackage > announcements and I am a little bit confused by their name. > When you remove a package, an announcement RPackageUnregistered is > raised, but I do not know if there is a difference with RPackageRemoved > (which by the way does not exist, but I was expecting a name like that). > What is this registration thing ? There is no RPackageRegistered but > there is RPackageCreated. > > So I am confused. Does someone know if I should create an announcement > RPackageRemoved or rename RPackageCreated into RPackageRegistered ? It > does not seem consistent and so it is confusing. Or can someone explain > to me the notion of registration for the RPackages ? I'd say that, at the moment, the RPackage code is a bit half-way through a complete handling of all those aspects; some decisions about packages are left outside the RPackage code, in Monticello in particular. So objects tracking packages changes should also have a look into the Monticello related announcements which are (digging through the AltBrowser code)... MCWorkingCopyCreated, MCWorkingCopyModified, MCWorkingCopyDeleted, in addition to RPackageCreated, RPackageUnregistered. For example, AltBrowser, for its package categories and browsing environments (aka groups), tracks all of them. I haven't checked, but I suspect that only Monticello can really delete a package (by unloading it) and that RPackageOrganizer will react to it by unregistering the package. Another possibility is the removal of a system category. So renaming RPackageUnregistered as RPackageRemoved requires significant changes in RPackageOrganizer, for which I'd say beware: this is a very good way of confirming that Pharo5 is alpha software ;) Thierry |
Hello,
Thanks for the explanation ! So Nicolai is probably right, RPackageCreated should be named RPackageRegistered to be consistent. Franck > Date: Sun, 19 Jul 2015 13:47:37 +0200 > From: [hidden email] > To: [hidden email] > Subject: Re: [Pharo-dev] RPackage classes name > > Hi Franck, > > Le 18/07/2015 15:48, Franck Warlouzet a écrit : > > Hello, > > > > Currently I am working on groups in Nautilus, and I am actually > > reimplementing them because I could not just fix them (There are a lot > > of bugs which make them almost unusable in practice), it is too > > complicated for nothing. Doing this I somehow have to use RPackage > > announcements and I am a little bit confused by their name. > > When you remove a package, an announcement RPackageUnregistered is > > raised, but I do not know if there is a difference with RPackageRemoved > > (which by the way does not exist, but I was expecting a name like that). > > What is this registration thing ? There is no RPackageRegistered but > > there is RPackageCreated. > > > > So I am confused. Does someone know if I should create an announcement > > RPackageRemoved or rename RPackageCreated into RPackageRegistered ? It > > does not seem consistent and so it is confusing. Or can someone explain > > to me the notion of registration for the RPackages ? > > I'd say that, at the moment, the RPackage code is a bit half-way through > a complete handling of all those aspects; some decisions about packages > are left outside the RPackage code, in Monticello in particular. > > So objects tracking packages changes should also have a look into the > Monticello related announcements which are (digging through the > AltBrowser code)... MCWorkingCopyCreated, MCWorkingCopyModified, > MCWorkingCopyDeleted, in addition to RPackageCreated, > RPackageUnregistered. For example, AltBrowser, for its package > categories and browsing environments (aka groups), tracks all of them. > > I haven't checked, but I suspect that only Monticello can really delete > a package (by unloading it) and that RPackageOrganizer will react to it > by unregistering the package. Another possibility is the removal of a > system category. > > So renaming RPackageUnregistered as RPackageRemoved requires significant > changes in RPackageOrganizer, for which I'd say beware: this is a very > good way of confirming that Pharo5 is alpha software ;) > > Thierry > |
Le 19/07/2015 13:58, Franck Warlouzet a écrit :
> Hello, > > Thanks for the explanation ! So Nicolai is probably right, > RPackageCreated should be named RPackageRegistered to be consistent. Yes, Nicolai is right. RPackageCreated is announced in two places: RPackageOrganizer>>registerPackage: and RPackageOrganizer>>ensureExistAndRegisterPackageNamed: (i.e. both are "registerPackage" methods). A simple class rename refactoring should be enough ;) Thierry > > Franck > > > Date: Sun, 19 Jul 2015 13:47:37 +0200 > > From: [hidden email] > > To: [hidden email] > > Subject: Re: [Pharo-dev] RPackage classes name > > > > Hi Franck, > > > > Le 18/07/2015 15:48, Franck Warlouzet a écrit : > > > Hello, > > > > > > Currently I am working on groups in Nautilus, and I am actually > > > reimplementing them because I could not just fix them (There are a lot > > > of bugs which make them almost unusable in practice), it is too > > > complicated for nothing. Doing this I somehow have to use RPackage > > > announcements and I am a little bit confused by their name. > > > When you remove a package, an announcement RPackageUnregistered is > > > raised, but I do not know if there is a difference with RPackageRemoved > > > (which by the way does not exist, but I was expecting a name like > that). > > > What is this registration thing ? There is no RPackageRegistered but > > > there is RPackageCreated. > > > > > > So I am confused. Does someone know if I should create an announcement > > > RPackageRemoved or rename RPackageCreated into RPackageRegistered ? It > > > does not seem consistent and so it is confusing. Or can someone explain > > > to me the notion of registration for the RPackages ? > > > > I'd say that, at the moment, the RPackage code is a bit half-way through > > a complete handling of all those aspects; some decisions about packages > > are left outside the RPackage code, in Monticello in particular. > > > > So objects tracking packages changes should also have a look into the > > Monticello related announcements which are (digging through the > > AltBrowser code)... MCWorkingCopyCreated, MCWorkingCopyModified, > > MCWorkingCopyDeleted, in addition to RPackageCreated, > > RPackageUnregistered. For example, AltBrowser, for its package > > categories and browsing environments (aka groups), tracks all of them. > > > > I haven't checked, but I suspect that only Monticello can really delete > > a package (by unloading it) and that RPackageOrganizer will react to it > > by unregistering the package. Another possibility is the removal of a > > system category. > > > > So renaming RPackageUnregistered as RPackageRemoved requires significant > > changes in RPackageOrganizer, for which I'd say beware: this is a very > > good way of confirming that Pharo5 is alpha software ;) > > > > Thierry > > |
Ok I will do that, thanks again
Fanck > Date: Sun, 19 Jul 2015 15:12:06 +0200 > From: [hidden email] > To: [hidden email] > Subject: Re: [Pharo-dev] RPackage classes name > > Le 19/07/2015 13:58, Franck Warlouzet a écrit : > > Hello, > > > > Thanks for the explanation ! So Nicolai is probably right, > > RPackageCreated should be named RPackageRegistered to be consistent. > > Yes, Nicolai is right. RPackageCreated is announced in two places: > RPackageOrganizer>>registerPackage: > and > RPackageOrganizer>>ensureExistAndRegisterPackageNamed: > > (i.e. both are "registerPackage" methods). > > A simple class rename refactoring should be enough ;) > > Thierry > > > > > Franck > > > > > Date: Sun, 19 Jul 2015 13:47:37 +0200 > > > From: [hidden email] > > > To: [hidden email] > > > Subject: Re: [Pharo-dev] RPackage classes name > > > > > > Hi Franck, > > > > > > Le 18/07/2015 15:48, Franck Warlouzet a écrit : > > > > Hello, > > > > > > > > Currently I am working on groups in Nautilus, and I am actually > > > > reimplementing them because I could not just fix them (There are a lot > > > > of bugs which make them almost unusable in practice), it is too > > > > complicated for nothing. Doing this I somehow have to use RPackage > > > > announcements and I am a little bit confused by their name. > > > > When you remove a package, an announcement RPackageUnregistered is > > > > raised, but I do not know if there is a difference with RPackageRemoved > > > > (which by the way does not exist, but I was expecting a name like > > that). > > > > What is this registration thing ? There is no RPackageRegistered but > > > > there is RPackageCreated. > > > > > > > > So I am confused. Does someone know if I should create an announcement > > > > RPackageRemoved or rename RPackageCreated into RPackageRegistered ? It > > > > does not seem consistent and so it is confusing. Or can someone explain > > > > to me the notion of registration for the RPackages ? > > > > > > I'd say that, at the moment, the RPackage code is a bit half-way through > > > a complete handling of all those aspects; some decisions about packages > > > are left outside the RPackage code, in Monticello in particular. > > > > > > So objects tracking packages changes should also have a look into the > > > Monticello related announcements which are (digging through the > > > AltBrowser code)... MCWorkingCopyCreated, MCWorkingCopyModified, > > > MCWorkingCopyDeleted, in addition to RPackageCreated, > > > RPackageUnregistered. For example, AltBrowser, for its package > > > categories and browsing environments (aka groups), tracks all of them. > > > > > > I haven't checked, but I suspect that only Monticello can really delete > > > a package (by unloading it) and that RPackageOrganizer will react to it > > > by unregistering the package. Another possibility is the removal of a > > > system category. > > > > > > So renaming RPackageUnregistered as RPackageRemoved requires significant > > > changes in RPackageOrganizer, for which I'd say beware: this is a very > > > good way of confirming that Pharo5 is alpha software ;) > > > > > > Thierry > > > > > |
Thanks for looking at this issue.
Stef Le 19/7/15 15:15, Franck Warlouzet a
écrit :
|
Free forum by Nabble | Edit this page |