Save a variable between plugin calls

I’m developing my first plugin. I’d like to save a variable set by one method (js_first) so that it can be accessed by another method (js_second). The variable is not a basic value (int, char, string, etc) but one defined by an api.

Is this possible?

We do ship source from some plugins (open the .jar files with zip), these may show what you want.