On Wed, 26 Jan 2000, zhanglei wrote:
> Hi, everyone:
>
> I have a question about tcljava and namespace.
> I wrote Tcl extension using tcljava class lib
> (eg. public class Ext extends tcl.lang.Extension
> and add new commands using Interp.createCommand method)
> and made a tcl package index using pkg_mkIndex.
> After that, I load the extension using java::load
> in the package startup file.
> That's all right and i can use the new commands
> in the extension directly in the wish shell.
Just create the namespace and then use a namespace qualifier
for each of the commands you create.
Like so.
interp.eval("namespace eval ext {}");
interp.createCommand("ext::mycmd", cmd);
> But how can i make all the commands in the extension
> available in a package namespace? That is, i do not
> want them available in the wish shell directly, but
> with a package namespace prefix(eg. ext::someCommand ).
> Because i wrote the extension and all the commands
> in java. I don't know how to do it.
Gee, I hope nobody is going to die if you do not get
this demo working :)
> Can anyone help me? Because i have to make a demo
> two days later, I deadly need your advice.
> If you know the answer, pls reply ASAP.
> Thank you very much.
>
> zhanglei
Mo Dejong
Red Hat Inc.
----------------------------------------------------------------
The TclJava mailing list is sponsored by Scriptics Corporation.
To subscribe: send mail to [EMAIL PROTECTED]
with the word SUBSCRIBE as the subject.
To unsubscribe: send mail to [EMAIL PROTECTED]
with the word UNSUBSCRIBE as the subject.
To send to the list, send email to '[EMAIL PROTECTED]'.
An archive is available at http://www.mail-archive.com/tcljava@scriptics.com