Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1911)

Side by Side Diff: benchmark/lib/benchmarks/int32_json.dart

Issue 1829573002: Fix all strong mode warnings in protoc-plugin (Closed) Base URL: git@github.com:dart-lang/dart-protoc-plugin.git@master
Patch Set: regenerate pb.dart files Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « benchmark/lib/benchmarks/has_strings.dart ('k') | benchmark/lib/benchmarks/int64_json.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library protoc.benchmark.int32_json; 5 library protoc.benchmark.int32_json;
6 6
7 import '../benchmark.dart'; 7 import '../benchmark.dart';
8 import '../generated/benchmark.pb.dart' show BenchmarkID, Request, Params, Sampl e; 8 import '../generated/benchmark.pb.dart'
9 show BenchmarkID, Request, Params, Sample;
9 import '../generated/int32grid.pb.dart' as pb; 10 import '../generated/int32grid.pb.dart' as pb;
10 11
11 /// A benchmark that deserializes a grid of int fields. 12 /// A benchmark that deserializes a grid of int fields.
12 class Int32Benchmark extends Benchmark { 13 class Int32Benchmark extends Benchmark {
13 final int width; 14 final int width;
14 final int height; 15 final int height;
15 String json; 16 String json;
16 int lastFieldTag; 17 int lastFieldTag;
17 18
18 Int32Benchmark(this.width, this.height) : super($id); 19 Int32Benchmark(this.width, this.height) : super($id);
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 71
71 @override 72 @override
72 measureSample(Sample s) => int32ReadsPerMillisecond(s); 73 measureSample(Sample s) => int32ReadsPerMillisecond(s);
73 74
74 @override 75 @override
75 get measureSampleUnits => "int32 reads/ms"; 76 get measureSampleUnits => "int32 reads/ms";
76 77
77 static const $id = BenchmarkID.READ_INT32_FIELDS_JSON; 78 static const $id = BenchmarkID.READ_INT32_FIELDS_JSON;
78 static final $type = new BenchmarkType($id, $create); 79 static final $type = new BenchmarkType($id, $create);
79 80
80 static $create(Request r) { 81 static Int32Benchmark $create(Request r) {
81 assert(r.params.hasInt32FieldCount()); 82 assert(r.params.hasInt32FieldCount());
82 assert(r.params.hasMessageCount()); 83 assert(r.params.hasMessageCount());
83 return new Int32Benchmark(r.params.int32FieldCount, r.params.messageCount); 84 return new Int32Benchmark(r.params.int32FieldCount, r.params.messageCount);
84 } 85 }
85 } 86 }
OLDNEW
« no previous file with comments | « benchmark/lib/benchmarks/has_strings.dart ('k') | benchmark/lib/benchmarks/int64_json.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698