Exemplo n.º 1
0
        /// <summary>
        /// 지정된 Entity 형식이 매핑된 현재 Session을 반환한다.
        /// </summary>
        /// <param name="typeOfEntity"></param>
        /// <returns></returns>
        public static ISession GetCurrentSessionFor(Type typeOfEntity)
        {
            if (UnitOfWorkFactory is NHMultipleUnitOfWorkFactory)
            {
                return(UnitOfWorkFactory.GetCurrentSessionFor(typeOfEntity));
            }

            return(CurrentSession);
        }