Ejemplo n.º 1
0
        static FwkGeneratorHelper()
        {
            //roottemplate = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "Templates"); //Path.Combine(HelperFunctions.ProgramFilesx86(), @"Allus Global BPO\FwkTemplates\tt\");
            roottemplate      = Path.Combine(System.IO.Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location), "Templates");
            _TemplateDocument = (TemplateDocument)HelperFunctions.DeserializeFromXml(typeof(TemplateDocument), GetFileTemplate("Templates.xml"));
            _MappingTypes     = (MappingTypes)HelperFunctions.DeserializeFromXml(typeof(MappingTypes), GetFileTemplate("MappingType.xml"));

            NotSupportTypes_ToIncludeInBackEnd = "xml,timestamp,sql_variant";

            NotSupportTypes_ToSearchInStoreProcedure = "xml,timestamp,sql_variant,varbinary,binary,image";
            NotSupportTypes_ToInsertStoreProcedure   = "xml,timestamp,sql_variant";


            _Entity_Envelope_tt = FwkGeneratorHelper.GetFileTemplate("Entity.txt");
            _Entity_Property_TemplateBinary_tt = _TemplateDocument.GetTemplate("Property_Binary").Content;

            _Entity_Property_tt = _TemplateDocument.GetTemplate("Property").Content;

            _Entity_Member_tt = "           private [TYPENAME][NullToken] _[Property_Name];";
        }
Ejemplo n.º 2
0
        static FwkGeneratorHelper()
        {
            roottemplate = Path.Combine(HelperFunctions.ProgramFilesx86(), @"Fwk Software Factory\5.0\FwkTemplates\tt\");

            _TemplateDocument = (TemplateDocument)HelperFunctions.DeserializeFromXml(typeof(TemplateDocument), GetFileTemplate("Templates.xml"));
            _MappingTypes     = (MappingTypes)HelperFunctions.DeserializeFromXml(typeof(MappingTypes), GetFileTemplate("MappingType.xml"));

            NotSupportTypes_ToIncludeInBackEnd = "xml,timestamp,sql_variant";

            NotSupportTypes_ToSearchInStoreProcedure = "xml,timestamp,sql_variant,varbinary,binary,image";
            NotSupportTypes_ToInsertStoreProcedure   = "xml,timestamp,sql_variant";


            _Entity_Envelope_tt = FwkGeneratorHelper.GetFileTemplate("Entity.txt");
            _Entity_Property_TemplateBinary_tt = _TemplateDocument.GetTemplate("Property_Binary").Content;

            _Entity_Property_tt = _TemplateDocument.GetTemplate("Property").Content;

            _Entity_Member_tt = "           private [TYPENAME][NullToken] _[Property_Name];";

            UserDefinedTypes = new UserDefinedTypes();
        }