- Timestamp:
- Sep 4, 2018, 1:00:48 PM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
binary-improvements/7dtd-server-fixes/src/JSON/JSONNull.cs
r309 r325 1 using System;2 1 using System.Text; 3 2 4 namespace AllocsFixes.JSON 5 { 6 public class JSONNull : JSONValue 7 { 8 public JSONNull () 9 { 10 } 11 12 public override void ToString (StringBuilder stringBuilder, bool prettyPrint = false, int currentLevel = 0) 13 { 3 namespace AllocsFixes.JSON { 4 public class JSONNull : JSONValue { 5 public override void ToString (StringBuilder stringBuilder, bool prettyPrint = false, int currentLevel = 0) { 14 6 stringBuilder.Append ("null"); 15 7 } 16 8 17 public static JSONNull Parse (string json, ref int offset) 18 { 9 public static JSONNull Parse (string json, ref int offset) { 19 10 //Log.Out ("ParseNull enter (" + offset + ")"); 20 11 … … 23 14 offset += 4; 24 15 return new JSONNull (); 25 } else {26 throw new MalformedJSONException ("No valid null value found");27 16 } 17 18 throw new MalformedJSONException ("No valid null value found"); 28 19 } 29 30 20 } 31 21 } 32
Note:
See TracChangeset
for help on using the changeset viewer.