[GemStone-Smalltalk] Class names and VisualWorks namespaces

David Shaffer shaffer at shaffer-consulting.com
Mon Nov 2 10:03:14 PST 2020


Thanks Richard, I guess I was just looking for confirmation that I had to write this code myself.  At the moment I’m mapping VW namespaces to GS symbol dictionaries (replacing “.” with __ and ignoring containment of one namespace inside another).  This keeps classes unambiguous on the server.  Code attached “kind of” works and comments are welcomed but not expected ;)  Now I have to sort out all of the magic in GbsSession>>createGemStoneClassFor:copyOldVersion: and GbsSession>>doesClientClass:matchServerClass: since those methods handle lots of special cases (class already exists with same/different structure etc) but are, unfortunately, interactive.

(Sorry about the crappy Topological sort…it will need to be revisited if you’re publishing a large number of classes).

Best,

David



> On Nov 2, 2020, at 12:51 PM, Richard Sargent <richard.sargent at gemtalksystems.com> wrote:
> 
> On Tue, Oct 27, 2020 at 7:48 PM David Shaffer via GemStone-Smalltalk <gemstone-smalltalk at lists.gemtalksystems.com <mailto:gemstone-smalltalk at lists.gemtalksystems.com>> wrote:
> Am I misunderstanding or does GemBuilder for VisualWorks ignore VisualWorks namespaces when automatically generating server classes and automatically creating connectors?  
> 
> From the GBS for VisualWorks documentation:
> GemBuilder deposits automatically generated GemStone server classes in the
> GemStone symbol dictionary UserClasses, which it creates if necessary.
> Automatically generated client Smalltalk classes are deposited in the current
> package. 
> With respect to the "ignore VisualWorks namespaces" part of your question, I think the best way to answer it is "pretty much".
> 
> As noted in the documentation, this automatic class generation is intended as a developer convenience. It is still best to deploy code to each environment in advance of running the application and to predefine the class connectors that could have a conflict or otherwise be unreachable by name lookup.
> 
> 
> Best,
> 
> David
> 
> _______________________________________________
> GemStone-Smalltalk mailing list
> GemStone-Smalltalk at lists.gemtalksystems.com <mailto:GemStone-Smalltalk at lists.gemtalksystems.com>
> https://lists.gemtalksystems.com/mailman/listinfo/gemstone-smalltalk <https://lists.gemtalksystems.com/mailman/listinfo/gemstone-smalltalk>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gemtalksystems.com/mailman/private/gemstone-smalltalk/attachments/20201102/de290e85/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: GemstoneClassBuilder.st
Type: application/octet-stream
Size: 2993 bytes
Desc: not available
URL: <https://lists.gemtalksystems.com/mailman/private/gemstone-smalltalk/attachments/20201102/de290e85/attachment.obj>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gemtalksystems.com/mailman/private/gemstone-smalltalk/attachments/20201102/de290e85/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Topological Sort.st
Type: application/octet-stream
Size: 3477 bytes
Desc: not available
URL: <https://lists.gemtalksystems.com/mailman/private/gemstone-smalltalk/attachments/20201102/de290e85/attachment-0001.obj>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gemtalksystems.com/mailman/private/gemstone-smalltalk/attachments/20201102/de290e85/attachment-0002.htm>


More information about the GemStone-Smalltalk mailing list