Cowdery, Bob [UK]
Bob.Cowdery at CGI-Europe.com
Sun May 7 19:54:08 UTC 2006
Bob.Cowdery at CGI-Europe.com puso en su mail :
Hi all - well I think I am getting better as finding my way around but clearly not there yet. I have a class that generates me a SAR file from a dozen or so categories and a bunch of other stuff. I have been manually doing a fileOut on each category but want to add this to the class so it's more automatic. I followed various paths for fileOut and ended up with so many classes that seem to do the same thing like Browser, Class, PseudoClass, SystemOrganizer etc. None of which I could actually make work. I am not sure how to determine which is the proper class to use and why my attempts to use any of them failed.
Thanks again for any help.
Edger J. De Cleene wrote:
The most easy way is do the following:
| myStuff classList |
classList := #(RemoteDebugServer Socket MailSender). "Here I pick any class"
myStuff := ChangeSet basicNewNamed: 'BobThings'.
classList do: [:ea| realClass := (Smalltalk at: ea).
myStuff addClass: realClass.
(realClass methodDict) do: [: icm| myStuff adoptSelector: icm who last forClass: icm who first].
( realClass class methodDict ) do: [: ccm| myStuff adoptSelector: ccm who last forClass: ccm who first]].
I add a sample of this fileOut, you must change RemoteDebugServer Socket MailSender for you own.
Thanks for that, not sure I would have got there any time soon. I have built my SAR file now which pulls in one .cs file as opposed to many .st files. Is this doing an equivalent thing or are there subtle differences? I loaded it on another machine and it seems to work fine. One question, I have a pool dictionary that I was instantiating first in my SAR file because I seemed to need to do that. I have left that file as a .st, and file it in first, is there a better way to do that?
*** Confidentiality Notice *** Proprietary/Confidential
Information belonging to CGI Group Inc. and its affiliates
may be contained in this message. If you are not a recipient
indicated or intended in this message (or responsible for
delivery of this message to such person), or you think for
any reason that this message may have been addressed to you
in error, you may not use or copy or deliver this message
to anyone else. In such case, you should destroy this
message and are asked to notify the sender by reply email.
More information about the Squeak-dev