private static parseDictionary ( |
||
node | ||
Résultat | object>.Dictionary |
private static object parse(XmlNode node) { string name = node.Name; // ISSUE: reference to a compiler-generated method uint stringHash = (uint.Parse(name)); if (stringHash <= 1996966820U) { if (stringHash <= 398550328U) { if ((int)stringHash != 184981848) { if ((int)stringHash == 398550328 && name == "string") { return((object)node.InnerText); } } else if (name == "false") { return((object)false); } } else if ((int)stringHash != 1278716217) { if ((int)stringHash != 1303515621) { if ((int)stringHash == 1996966820 && name == "null") { return((object)null); } } else if (name == "true") { return((object)true); } } else if (name == "dict") { return((object)Plist.parseDictionary(node)); } } else if (stringHash <= 3218261061U) { if ((int)stringHash != -1973899994) { if ((int)stringHash == -1076706235 && name == "integer") { return((object)Convert.ToInt32(node.InnerText, (IFormatProvider)NumberFormatInfo.InvariantInfo)); } } else if (name == "array") { return((object)Plist.parseArray(node)); } } else if ((int)stringHash != -730669991) { if ((int)stringHash != -689983395) { if ((int)stringHash == -663559515 && name == "data") { return((object)Convert.FromBase64String(node.InnerText)); } } else if (name == "real") { return((object)Convert.ToDouble(node.InnerText, (IFormatProvider)NumberFormatInfo.InvariantInfo)); } } else if (name == "date") { return((object)XmlConvert.ToDateTime(node.InnerText, XmlDateTimeSerializationMode.Utc)); } throw new ApplicationException(string.Format("Plist Node `{0}' is not supported", (object)node.Name)); }
// Token: 0x06000111 RID: 273 RVA: 0x000070B0 File Offset: 0x000052B0 private static object parse(XmlNode node) { string name = node.Name; if (name != null) { Dictionary <string, int> xdict = null; if (xdict == null) { xdict = new Dictionary <string, int>(10) { { "dict", 0 }, { "array", 1 }, { "string", 2 }, { "integer", 3 }, { "real", 4 }, { "false", 5 }, { "true", 6 }, { "null", 7 }, { "date", 8 }, { "data", 9 } }; } int num; if (xdict.TryGetValue(name, out num)) { object result; switch (num) { case 0: result = Plist.parseDictionary(node); break; case 1: result = Plist.parseArray(node); break; case 2: result = node.InnerText; break; case 3: result = Convert.ToInt32(node.InnerText, NumberFormatInfo.InvariantInfo); break; case 4: result = Convert.ToDouble(node.InnerText, NumberFormatInfo.InvariantInfo); break; case 5: result = false; break; case 6: result = true; break; case 7: result = null; break; case 8: result = XmlConvert.ToDateTime(node.InnerText, XmlDateTimeSerializationMode.Utc); break; case 9: result = Convert.FromBase64String(node.InnerText); break; default: goto IL_170; } return(result); } } IL_170: throw new ApplicationException(string.Format("Plist Node `{0}' is not supported", node.Name)); }