public void mapFile(string fileToMap, bool clearPreviousData) { loadedFile = fileToMap; var tilesDefinitionXml = J2eeConfigFiles.getTilesDefinitionXml(fileToMap); tableList_TilesDefinitions.setDataTable(CreateDataTable_Local.fromGenericList(tilesDefinitionXml.definitions), clearPreviousData); /* * lbValidatatorForms.Items.Clear(); * //foreach(var form in validationXml.forms) * lbValidatatorForms.Items.AddRange(validationXml.forms.ToArray()); * if (lbValidatatorForms.Items.Count > 0) * lbValidatatorForms.SelectedIndex = 0; * //tableList_Forms.setDataTable(CreateDataTable.fromGenericList(validationXml.forms)); */ /*tableList_FormBeans.setDataTable(CreateDataTable.fromGenericList(strutsConfigXml.formBeans)); * tableList_GlobalForwards.setDataTable(CreateDataTable.fromDictionary_StringString(strutsConfigXml.globalForwards, "name", "path")); * tableList_ActionMappings.setDataTable(CreateDataTable.fromGenericList(strutsConfigXml.actionmappings)); */ //lbDescription.Text = webXml.description; //lbDisplayName.Text = webXml.displayName; //tableList_Filter.setDataTable(CreateDataTable.fromGenericList(webXml.filters)); //tableList_FilterMappings.setDataTable(CreateDataTable.fromGenericList(webXml.filterMappings)); //tableList_Servlets.setDataTable(CreateDataTable.fromGenericList(webXml.servlets)); //tableList_ServletMappings.setDataTable(CreateDataTable.fromGenericList(webXml.servletMappings)); }
public static IStrutsMappings calculateStrutsMapping(string webXmlFile, string strutsConfigFile, string tilesDefinitionsFile, string validationXmlFile) { var webXml = J2eeConfigFiles.getWebXml(webXmlFile); if (webXml == null) { return(null); } var tilesDefinitions = J2eeConfigFiles.getTilesDefinitionXml(tilesDefinitionsFile); var validation = J2eeConfigFiles.getValidationXml(validationXmlFile); var strutsConfig = J2eeConfigFiles.getStrutsConfig(strutsConfigFile, tilesDefinitions, validation); if (strutsConfig == null) { return(null); } return(calculateStrutsMapping(webXml, strutsConfig)); }