本文整理汇总了Java中org.apache.shiro.session.SessionListener类的典型用法代码示例。如果您正苦于以下问题:Java SessionListener类的具体用法?Java SessionListener怎么用?Java SessionListener使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
SessionListener类属于org.apache.shiro.session包,在下文中一共展示了SessionListener类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: AbstractNativeSessionManager
import org.apache.shiro.session.SessionListener; //导入依赖的package包/类
public AbstractNativeSessionManager() {
this.listeners = new ArrayList<SessionListener>();
}
示例2: setSessionListeners
import org.apache.shiro.session.SessionListener; //导入依赖的package包/类
public void setSessionListeners(Collection<SessionListener> listeners) {
this.listeners = listeners != null ? listeners : new ArrayList<SessionListener>();
}
示例3: getSessionListeners
import org.apache.shiro.session.SessionListener; //导入依赖的package包/类
@SuppressWarnings({"UnusedDeclaration"})
public Collection<SessionListener> getSessionListeners() {
return this.listeners;
}
示例4: notifyStop
import org.apache.shiro.session.SessionListener; //导入依赖的package包/类
protected void notifyStop(Session session) {
Session forNotification = beforeInvalidNotification(session);
for (SessionListener listener : this.listeners) {
listener.onStop(forNotification);
}
}
示例5: notifyExpiration
import org.apache.shiro.session.SessionListener; //导入依赖的package包/类
protected void notifyExpiration(Session session) {
Session forNotification = beforeInvalidNotification(session);
for (SessionListener listener : this.listeners) {
listener.onExpiration(forNotification);
}
}
示例6: getSessionListenerList
import org.apache.shiro.session.SessionListener; //导入依赖的package包/类
public Set<SessionListener> getSessionListenerList() {
return sessionListenerList;
}
示例7: notifyStart
import org.apache.shiro.session.SessionListener; //导入依赖的package包/类
/**
* Notifies any interested {@link SessionListener}s that a Session has started. This method is invoked
* <em>after</em> the {@link #onStart onStart} method is called.
*
* @param session the session that has just started that will be delivered to any
* {@link #setSessionListeners(java.util.Collection) registered} session listeners.
* @see SessionListener#onStart(org.apache.shiro.session.Session)
*/
protected void notifyStart(Session session) {
for (SessionListener listener : this.listeners) {
listener.onStart(session);
}
}