Topaz file out a package

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Topaz file out a package

GLASS mailing list
Hi,
GS 3.4.1

It is possible to fileout an entire Package in Topaz ?

A class is very easy:
topaz 1> fileout class: Object toFile: object.gs

But i could not find:
topaz 1> fileout packge: 'package-name' toFile: package.gs

It is possible in Jade i think it only iterate over all package classes and
append all to the same File Stream.

regards,
bruno



--
Sent from: http://forum.world.st/GLASS-f1460844.html
_______________________________________________
Glass mailing list
[hidden email]
https://lists.gemtalksystems.com/mailman/listinfo/glass
Reply | Threaded
Open this post in threaded view
|

Re: Topaz file out a package

GLASS mailing list
Yes, that would be nice to have ... especially when upgrading to another database version. I am in luck, my application creates during runtime only classes of a specific subclass, so I can find that stuff ... but when filing in, the package structure is gone. So in my specific case I have a base empty package, which I file in after upgrading, and then I file in all my exported classes ...

Marten
BrunoBB via Glass < [hidden email]> hat am 22. Januar 2020 um 20:49 geschrieben:


Hi,
GS 3.4.1

It is possible to fileout an entire Package in Topaz ?

A class is very easy:
topaz 1> fileout class: Object toFile: object.gs

But i could not find:
topaz 1> fileout packge: 'package-name' toFile: package.gs

It is possible in Jade i think it only iterate over all package classes and
append all to the same File Stream.

regards,
bruno



--
_______________________________________________
Glass mailing list

_______________________________________________
Glass mailing list
[hidden email]
https://lists.gemtalksystems.com/mailman/listinfo/glass
Reply | Threaded
Open this post in threaded view
|

Re: Topaz file out a package

GLASS mailing list
In reply to this post by GLASS mailing list

Bruno/Marten,

tODE has a command for doing fileouts of packages:

mc fileout <fileout-directory-path> <package-name-list>

but I'm not sure that it does what you are expecting as it creates a .gs file per class.

When I tested the command I found that there were a handful of bugs (for extension methods the algorithm expects the files to exist already) ... the bugs could be fixed but I don't know whether or not you are using tODE and I don't whether or not you will benefit from using this command as the code was written to make it possible to update the .gs file structure used for the GemStone base product -- I created these commands to update the base .gs files based on edits I was making in tODE and over the years I moved away from package-based updates, thus the bugs:)

I'm pretty busy with Rowan, right now, but if a file per class will work for you, I can fix the extension method bugs in tODE.

Otherwise you can take a look at these two tODE methods[1] and [2] for inspiration.

I do have support for writing out .gs files in Rowan - the code can read filetree format packages and produce a .gs file per package. If you are not inspired to create your own .gs file writer, using Monticello code, I could probably provide you with a topaz solo extent that has Rowan installed and a workspace that you can modify to create your .gs files ... this will be much easier for me to do since I just don't have the time to redo the work that I've already done in Rowan using Monticello.

If you are not using or cannot create filetree format packages, then the Rowan code won't be of use to you.

Dale

[1] https://github.com/dalehenrich/tode/blob/master/repository/Topez-Server-Core.package/TDMonticelloTool.class/instance/mcfileout.packageNames.definitionsFilename.methodsFilename.classToFilenameMap.defaultHeader..st
[2] https://github.com/dalehenrich/tode/blob/master/repository/Topez-Server-Core.package/TDMonticelloTool.class/instance/mcfileout.packageNames.classToFilenameMap.defaultHeader..st


On 1/22/20 11:49 AM, BrunoBB via Glass wrote:
Hi,
GS 3.4.1

It is possible to fileout an entire Package in Topaz ?

A class is very easy:
topaz 1> fileout class: Object toFile: object.gs

But i could not find:
topaz 1> fileout packge: 'package-name' toFile: package.gs

It is possible in Jade i think it only iterate over all package classes and
append all to the same File Stream.

regards,
bruno



--
Sent from: http://forum.world.st/GLASS-f1460844.html
_______________________________________________
Glass mailing list
[hidden email]
https://lists.gemtalksystems.com/mailman/listinfo/glass

_______________________________________________
Glass mailing list
[hidden email]
https://lists.gemtalksystems.com/mailman/listinfo/glass