[Cuis-dev] Do classes know what package they come from ?

Nicola Mingotti nmingotti at gmail.com
Mon Aug 9 06:05:37 PDT 2021


solved, i think i  found the right way:

FooClass package packageDirectoryName .

bye
n.



On 8/9/21 2:33 PM, Nicola Mingotti wrote:
> Hi again,
>
> Problem. I have made my own package, classes, methods.
> Ok, all is ready to start the real work. But I need to do
> some cleaning and put data files in a reasonably safe directory
> Example: some JSON data file needed by my methods.
>
> The ideal for me would be to put the data files in the same directory
> containing the FooBar.pck.st file, or a sub-directory of it.
>
> Now, it would be all easy if i could say
> ----
> FooBar getMyPackageDirectory.
> ----
>
> Up to now i found that
> -----------------
> ou1 _ CodePackageList new.   "# here I can find the loaded package list."
>
> Then I could iterate over CodePackage list in 'CodePackageList new 
> packages' and check
> the first one containing class 'FooBar'.
>
> What I ask you is this. Can I go in the inverse way? Does
> a Class know who is its ClassCatergory ? Does a ClassCategory
> know who is its package ?
>
>
> bye
> Nicola
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20210809/64aba80e/attachment.htm>


More information about the Cuis-dev mailing list