static void Mapping() { MappingTool mapper = new MappingTool(configFile); mapper.Info(); //mapper.Map(true, 1000); //mapper.Truncate(10); //mapper.Check(1992); }
static void Mapping() { MappingTool mapper = new MappingTool(configFile); mapper.Info(); //mapper.Map(false, 2000); //mapper.Truncate(10); //mapper.Check(2000); }
static void PartialMapping() { MappingTool mapper = new MappingTool(configFile); mapper.PartialMap(1901, new IPathSelector[] { new TakePathByList() { Paths = new string[] { "/src/gpexecute.inc" } } } ); }
static void MapReleases() { MappingTool mapper = new MappingTool(configFile); mapper.MapReleases( new Dictionary <string, string>() { { "e8b5079917c0734637e444018c304ea057ad7f32", "Synthetic Release # 1" }, { "37541bbf91d09ad0200f2c26c7a3f79fdf050801", "Synthetic Release # 2" }, { "2e3d4ea2bdb8515772a198a863575ddbd32fd09c", "Synthetic Release # 3" }, { "6e512ec75fba7372babb04988c6cbf5197a26438", "Synthetic Release # 4" }, { "4137a8eb9b2bef436a7e975f4ffe58af49072d94", "Synthetic Release # 5" }, } ); }
static void MapReleases() { MappingTool mapper = new MappingTool(configFile); mapper.MapReleases( new Dictionary <string, string>() { { "308aee2d8229cbdd26f29eb04954044592dffa9d", "0.1.0" }, { "4d00ea8121fd373525ecf6fa93243efc91666554", "0.1.1" }, { "f0c86737a276553e72a4ff1b070e8e30eaab50a0", "0.2.0" }, { "0e10ffa1fc83ae4d6b3657266865df4c4a3534da", "0.2.1" }, { "4f9d9cdbefa90a8d3673f94d078f196de2ec788b", "0.3.0" }, { "3bab948571635f5b2bf8c9f8ac7ce867c4e57414", "0.3.1" }, { "368d67c4f309ee9b3f437f9c36845f7a02837d41", "0.3.2" }, } ); }
public static bool ParserInfoOracle(string path, ref List <ParsedInfo> infoLists, ref string tableName) { try { XmlDocument doc = new XmlDocument(); doc.XmlResolver = null;//this忽略 DTD doc.Load(path); XmlNode xn = doc.SelectSingleNode("hibernate-mapping"); XmlNode xn1 = xn.ChildNodes[0]; XmlElement xe1 = (XmlElement)xn1; tableName = xe1.GetAttribute("table").ToString().ToUpper(); XmlNodeList xnlist = xn1.ChildNodes; foreach (XmlNode xn2 in xnlist) { ParsedInfo info = new ParsedInfo(); XmlElement xe = (XmlElement)xn2; info.Name = xe.GetAttribute("name").ToString(); string type = xe.GetAttribute("type").ToString().Split(new char[] { '.' })[2]; info.TypeInfo = MappingTool.JavaToOracle(type); info.Column = xe.GetAttribute("column").ToString(); infoLists.Add(info); } if (infoLists == null || tableName == null) { return(false); } else { return(true); } } catch (Exception ex) { MessageBox.Show(ex.ToString(), "XML解析失败,请重新尝试!", MessageBoxButtons.OK, MessageBoxIcon.Error); return(false); } }
public void DisableActiveTool() { switch (ActiveTool) { case MappingTool.EyeDropper: { if (btnEyeDropper.Selected) { btnEyeDropper.Selected = false; } } break; } ActiveTool = MappingTool.Editor; }
public void SetActiveTool(MappingTool tool) { switch (tool) { case MappingTool.Editor: { DisableActiveTool(); } break; case MappingTool.EyeDropper: { btnEyeDropper.Selected = true; } break; } ActiveTool = tool; }
static void MapSyntheticReleases(int count, double stabilizationProbability) { MappingTool mapper = new MappingTool(configFile); mapper.MapSyntheticReleases(count, stabilizationProbability); }