Hi,
I noticed that whether I do:
@Persist("session")
public abstract void setMemberId(Long id);
or
@InjectState("memberId")
public abstract void setMemberId(Long id);
new session is created. However, my:
@InjectStateFlag("memberId")
public abstract boolean isLoggedIn();
returns true only if I set member id thru @InjectState, but returns
false if I set the member id thru @Persist("session"). I don't
understand why, afterall both are creating a session attribute right?
And if so, how come my HttpSessionAttributeListener is not reporting
anything no matter how I set member id? Yet HttpSessionListener
clearly shows that session does get created.
public class HttpSessionSniffer extends LogableObject implements
HttpSessionListener, HttpSessionAttributeListener {
public void sessionCreated(HttpSessionEvent arg0) {
if (sDbg())
_sLog.debug("session created: " +
arg0.getSession().getId());
}
public void attributeAdded(HttpSessionBindingEvent arg0) {
if (sDbg())
_sLog.debug(arg0.getName() + " " + (String)
arg0.getValue());
}
public void attributeRemoved(HttpSessionBindingEvent arg0) {
if (sDbg())
_sLog.debug(arg0.getName() + " " + (String)
arg0.getValue());
}
public void attributeReplaced(HttpSessionBindingEvent arg0) {
if (sDbg())
_sLog.debug(arg0.getName() + " " + (String)
arg0.getValue());
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]