Ejemplo n.º 1
0
 public void Number64Integer_Binary()
 {
     JsonWriteMicroBenchmarks.ExecuteWriteMicroBenchmark(
         writeTokens: (jsonWriter) => { jsonWriter.WriteNumber64Value(123); },
         benchmarkSerializationFormat: BenchmarkSerializationFormat.Binary);
 }
Ejemplo n.º 2
0
 public void True_Binary()
 {
     JsonWriteMicroBenchmarks.ExecuteWriteMicroBenchmark(
         writeTokens: (jsonWriter) => { jsonWriter.WriteBoolValue(true); },
         benchmarkSerializationFormat: BenchmarkSerializationFormat.Binary);
 }
Ejemplo n.º 3
0
 public void False_Newtonsoft()
 {
     JsonWriteMicroBenchmarks.ExecuteWriteMicroBenchmark(
         writeTokens: (jsonWriter) => { jsonWriter.WriteBoolValue(false); },
         benchmarkSerializationFormat: BenchmarkSerializationFormat.Newtonsoft);
 }
Ejemplo n.º 4
0
 public void Object_Newtonsoft()
 {
     JsonWriteMicroBenchmarks.ExecuteWriteMicroBenchmark(
         writeTokens: (jsonWriter) => { jsonWriter.WriteObjectStart(); jsonWriter.WriteObjectEnd(); },
         benchmarkSerializationFormat: BenchmarkSerializationFormat.Newtonsoft);
 }
Ejemplo n.º 5
0
 public void Null_Text()
 {
     JsonWriteMicroBenchmarks.ExecuteWriteMicroBenchmark(
         writeTokens: (jsonWriter) => { jsonWriter.WriteNullValue(); },
         benchmarkSerializationFormat: BenchmarkSerializationFormat.Text);
 }
Ejemplo n.º 6
0
 public void Array_Binary()
 {
     JsonWriteMicroBenchmarks.ExecuteWriteMicroBenchmark(
         writeTokens: (jsonWriter) => { jsonWriter.WriteArrayStart(); jsonWriter.WriteArrayEnd(); },
         benchmarkSerializationFormat: BenchmarkSerializationFormat.Binary);
 }
Ejemplo n.º 7
0
 public void String_Newtonsoft()
 {
     JsonWriteMicroBenchmarks.ExecuteWriteMicroBenchmark(
         writeTokens: (jsonWriter) => { jsonWriter.WriteStringValue("Hello World"); },
         benchmarkSerializationFormat: BenchmarkSerializationFormat.Newtonsoft);
 }
Ejemplo n.º 8
0
 public void Number64Double_Newtonsoft()
 {
     JsonWriteMicroBenchmarks.ExecuteWriteMicroBenchmark(
         writeTokens: (jsonWriter) => { jsonWriter.WriteNumber64Value(6.0221409e+23); },
         benchmarkSerializationFormat: BenchmarkSerializationFormat.Newtonsoft);
 }