Пример #1
0
        /// <summary>Creates a new, empty Entity object of the type specified</summary>
        /// <param name="entityTypeToCreate">The entity type to create.</param>
        /// <returns>A new, empty Entity object.</returns>
        public static IEntity2 Create(SD.LLBLGen.Pro.Examples.Authorization.EntityType entityTypeToCreate)
        {
            var      factoryToUse = EntityFactoryFactory.GetFactory(entityTypeToCreate);
            IEntity2 toReturn     = null;

            if (factoryToUse != null)
            {
                toReturn = factoryToUse.Create();
            }
            return(toReturn);
        }
Пример #2
0
 /// <summary>Implementation of the routine which gets the factory of the Entity type with the .NET type passed in</summary>
 /// <param name="typeOfEntity">The type of entity.</param>
 /// <returns>the entity factory of the entity type or null if not found</returns>
 protected override IEntityFactoryCore GetFactoryImpl(Type typeOfEntity)
 {
     return(EntityFactoryFactory.GetFactory(typeOfEntity));
 }
Пример #3
0
 /// <summary>Implementation of the routine which gets the factory of the Entity type with the SD.LLBLGen.Pro.Examples.Authorization.EntityType value passed in</summary>
 /// <param name="entityTypeValue">The entity type value.</param>
 /// <returns>the entity factory of the entity type or null if not found</returns>
 protected override IEntityFactoryCore GetFactoryImpl(int entityTypeValue)
 {
     return(EntityFactoryFactory.GetFactory((SD.LLBLGen.Pro.Examples.Authorization.EntityType)entityTypeValue));
 }