Applet - maintain state between destroy() and init()

V

VisionSet

I have a signed applet that appears on every page. I need to save and
retrieve an object between page navs. I thought System.properties may
be the way, but it seems you can only store Strings. Any other ideas
anyone?

TIA,
Mike W
 
A

Andrew T.

VisionSet said:
I have a signed applet that appears on every page. I need to save and
retrieve an object between page navs. I thought System.properties may
be the way, but it seems you can only store Strings. Any other ideas
anyone?

Serialisation or XML encoding to the local file system.

(Cookies managed via JS/Java would not fill the requirement?).

Andrew T.
 
M

Mark Space

Andrew said:
(Cookies managed via JS/Java would not fill the requirement?).
I was going to say the same thing. Set a cookie for the session. Save
user state in a session object. When the applet is started, have it
download the saved session information from the server.
 
V

VisionSet

Mark said:
I was going to say the same thing. Set a cookie for the session. Save
user state in a session object. When the applet is started, have it
download the saved session information from the server.

Unfortunately the state is an object I need a reference to, actually a
Jabber/XMPPConnection to a chat server. The user is logged on so
hopefully somehow I can recreate the connection based on the log in,
but I don't know how at present.
Otherwise I'll play with the serialisation option.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Staff online

Members online

Forum statistics

Threads
473,767
Messages
2,569,570
Members
45,045
Latest member
DRCM

Latest Threads

Top