/// <summary> /// Creates and Instance of TIfcType and initializes the properties in accordance with the lambda expression /// i.e. Person person = CreateInstance>Person<(p =< { p.FamilyName = "Undefined"; p.GivenName = "Joe"; }); /// </summary> /// <typeparam name = "TIfcType"></typeparam> /// <param name = "initPropertiesFunc"></param> /// <returns></returns> public TIfcType New <TIfcType>(InitProperties <TIfcType> initPropertiesFunc) where TIfcType : IPersistIfcEntity, new() { TIfcType instance = New <TIfcType>(); initPropertiesFunc(instance); return(instance); }
public T New <T>(InitProperties <T> initPropertiesFunc) where T : IPersistIfcEntity, new() { return(_model.InstancesLocal.New <T>(initPropertiesFunc)); }