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

Side by Side Diff: packages/analyzer/lib/src/summary/base.dart

Issue 2990843002: Removed fixed dependencies (Closed)
Patch Set: Created 3 years, 4 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
OLDNEW
(Empty)
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
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.
4
5 /**
6 * Base functionality which code generated summary classes are built upon.
7 */
8 library analyzer.src.summary.base;
9
10 /**
11 * Annotation used in the summary IDL to indicate the id of a field. The set
12 * of ids used by a class must cover the contiguous range from 0 to N-1, where
13 * N is the number of fields.
14 *
15 * In order to preserve forwards and backwards compatibility, id numbers must
16 * be stable between releases. So when new fields are added they should take
17 * the next available id without renumbering other fields.
18 */
19 class Id {
20 final int value;
21
22 const Id(this.value);
23 }
24
25 /**
26 * Instances of this class represent data that has been read from a summary.
27 */
28 abstract class SummaryClass {
29 /**
30 * Translate the data in this class into a JSON map, whose keys are the names
31 * of fields and whose values are the data stored in those fields,
32 * recursively converted into JSON.
33 *
34 * Fields containing their default value are elided.
35 *
36 * Intended for testing and debugging only.
37 */
38 Map<String, Object> toJson();
39
40 /**
41 * Translate the data in this class into a map whose keys are the names of
42 * fields and whose values are the data stored in those fields.
43 *
44 * Intended for testing and debugging only.
45 */
46 Map<String, Object> toMap();
47 }
48
49 /**
50 * Annotation used in the summary IDL to indicate that a summary class can be
51 * the top level object in an encoded summary.
52 */
53 class TopLevel {
54 /**
55 * If non-null, identifier that will be stored in bytes 4-7 of the file,
56 * prior all other file data. Must be exactly 4 Latin1 characters.
57 */
58 final String fileIdentifier;
59
60 const TopLevel([this.fileIdentifier]);
61 }
OLDNEW
« no previous file with comments | « packages/analyzer/lib/src/summary/api_signature.dart ('k') | packages/analyzer/lib/src/summary/bazel_summary.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698