Exemple #1
0
        private IDbSetBase <TEntity> GetEntitySetCore <TEntity>() where TEntity : ObjectBase, new()
        {
            IDbSetBase <TEntity> result = null;

            if (ENTITY_TYPES.Contains(typeof(TEntity)))
            {
                result = EntityUnitTestHelperBase <TEntity> .GetMockDataMethod.Invoke(null, new object[] { }) as IDbSetBase <TEntity>;
            }

            return(result);
        }
Exemple #2
0
        public IDbSetBase <TEntity> Set <TEntity>() where TEntity : ObjectBase, new()
        {
            // check core entities
            IDbSetBase <TEntity> result = GetEntitySetCore <TEntity>();

            // check project entities
            if (result == null)
            {
                result = GetEntitySetProject <TEntity>();
            }

            return(result);
        }