Пример #1
0
 @Override
 public void unregister(Session session) {
   for (ResourceHolder resource : resources.values()) {
     SessionHolder sessionHolder = resource.sessions.get(session.id());
     if (sessionHolder != null) {
       resource.stateMachine.unregister(sessionHolder.session);
     }
   }
 }
Пример #2
0
 @Override
 public void close(Session session) {
   for (ResourceHolder resource : resources.values()) {
     SessionHolder sessionHolder = resource.sessions.remove(session.id());
     if (sessionHolder != null) {
       resource.stateMachine.close(sessionHolder.session);
       sessionHolder.commit.close();
     }
   }
 }