Neco.Backend/SessionManager.cs
/// <summary>Returns a session with sepcified ID. 
/// If the Session is expired, it returns null, and removes the session from the collection.
/// Otherwise, it extends the session before returning it.</summary>
/// <param name="ID"></param>
/// <returns>Returns a session if one exists, if not NULL</returns>
Returns a session with sepcified ID.
If the Session is expired, it returns null, and removes the session from the collection.
Otherwise, it extends the session before returning it.
Returns a session with sepcified ID . If the Session is expired it returns null and removes the session from the collection . Otherwise it extends the session before returning it .
public Session FindSession(Guid ID) {
            Session S = Sessions.FirstOrDefault(S => S.ID == ID);
            if (S == null) { return null; }
            if (S.Expired) { Sessions.Remove(S); return null; }
            S.ExtendSession();
            return S;
        }
public Session FindSession ( Guid ID ) { Session S = Sessions . FirstOrDefault ( S => S . ID == ID ) ; if ( S == null ) { return null ; } if ( S . Expired ) { Sessions . Remove ( S ) ; return null ; } S . ExtendSession ( ) ; return S ; }
Returns a session with sepcified ID.
Returns a session with sepcified ID .
Returns a session if one exists, if not NULL
Returns a session if one exists if not NULL
ID
Guid
None