« Return to Thread: [squeak-dev] Namespaces, Packages: Image available for download, screencast.

Re: [squeak-dev] Namespaces, Packages: Image available for download, screencast.

by Michael van der Gulik-2 :: Rate this Message:

Reply to Author | View in Thread

On Wed, 16 Jul 2008 03:33:09 +0300
"Igor Stasenko" <siguctua@...> wrote:

> Oh, and also, i'm missing a code for a namespace definition. E.g. in
> same way as browser shows a code how to define new classes, it should
> show a code how namespaces are defined, like:
>
> Morphic addNamespace: #Kernel
>
> or, with predefined list of imports:
>
> Morphic addNamespace: #Kernel
> imports:  'Kernel.Objects Collections'
>
> or:
> Morphic addNamespace: #Kernel
> imports:  'Kernel.Objects<xx> Collections<yy>'

...assuming that Morphic is a namespace here.

To add a Namespace in the NamespaceBrowser, you just right-click on it's parent and select "new". The functionality above to textually define a Namespace could be implemented. That's an interesting idea.

Namespace>>addNamespace: already exists, as does Namespace>>addImport:.

There are also methods in CodeBuilder which are used when filing in to define Namespace structure and imports.

Gulik.


--
Michael van der Gulik <mikevdg@...>

 « Return to Thread: [squeak-dev] Namespaces, Packages: Image available for download, screencast.

LightInTheBox - Buy quality products at wholesale price!