sedj
Programmer
- Aug 6, 2002
- 5,610
Hi,
I wish to bind an object to Tomcat's InitialContext under the name "java:/abc" however, at the moment I am getting an error that the "java:" Context is read-only.
Has anybody any ideas ?
This is what I triedso far :
Cheers
Ben
I wish to bind an object to Tomcat's InitialContext under the name "java:/abc" however, at the moment I am getting an error that the "java:" Context is read-only.
Has anybody any ideas ?
This is what I triedso far :
Code:
Context jctx = (Context)ctx.lookup("java:");
// jctx.createSubcontext("abc"); // barfs
// jctx.bind("abc", "def"); // as does this
// jctx.addToEnvironment("abc", "def"); // does not barf, but doesn't seem to do much ...
Cheers
Ben