public ISession GetCurrentSession() { if (currentSessionContext == null) { throw new HibernateException("No CurrentSessionContext configured (set the property " + Environment.CurrentSessionContextClass + ")!"); } return(currentSessionContext.CurrentSession()); }
public ISession GetCurrentSession() { return(currentSessionContext != null?currentSessionContext.CurrentSession() : null); }