private static void AddSplashEntry(JsonElementArray entries, SplashScreen splash) { if (Utils.CompareVersionNumbers(splash.minOsVersion, "7.0") <= 0) { AddSplashEntryForOSVersion(entries.AddDict(), splash, null); } if (splash.minOsVersion != null) { AddSplashEntryForOSVersion(entries.AddDict(), splash, splash.minOsVersion); } }
private void WriteArray(StringBuilder sb, JsonElementArray el, int indent) { sb.Append("["); bool flag = false; foreach (JsonElement element in el.values) { if (flag) { sb.Append(","); } sb.Append("\n"); this.AppendIndent(sb, indent + 1); if (element is JsonElementString) { this.WriteString(sb, element.AsString()); } else if (element is JsonElementInteger) { this.WriteInteger(sb, element.AsInteger()); } else if (element is JsonElementBoolean) { this.WriteBoolean(sb, element.AsBoolean()); } else if (element is JsonElementDict) { this.WriteDict(sb, element.AsDict(), indent + 1); } else if (element is JsonElementArray) { this.WriteArray(sb, element.AsArray(), indent + 1); } flag = true; } sb.Append("\n"); this.AppendIndent(sb, indent); sb.Append("]"); }
public JsonElementArray CreateArray(string key) { JsonElementArray array = new JsonElementArray(); this.values[key] = array; return array; }
public JsonElementArray AddArray() { JsonElementArray item = new JsonElementArray(); this.values.Add(item); return item; }
public JsonElementArray CreateArray(string key) { var v = new JsonElementArray(); values[key] = v; return v; }
public JsonElementArray AddArray() { var v = new JsonElementArray(); values.Add(v); return v; }