| OLD | NEW |
| 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 // This file has been automatically generated. Please do not edit it manually. | 5 // This file has been automatically generated. Please do not edit it manually. |
| 6 // To regenerate the file, use the script "pkg/analyzer/tool/generate_files". | 6 // To regenerate the file, use the script "pkg/analyzer/tool/generate_files". |
| 7 | 7 |
| 8 library analyzer.src.summary.format; | 8 library analyzer.src.summary.format; |
| 9 | 9 |
| 10 import 'flat_buffers.dart' as fb; | 10 import 'flat_buffers.dart' as fb; |
| (...skipping 3264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3275 String toString() => convert.JSON.encode(toJson()); | 3275 String toString() => convert.JSON.encode(toJson()); |
| 3276 } | 3276 } |
| 3277 | 3277 |
| 3278 class UnlinkedConstBuilder extends Object with _UnlinkedConstMixin implements id
l.UnlinkedConst { | 3278 class UnlinkedConstBuilder extends Object with _UnlinkedConstMixin implements id
l.UnlinkedConst { |
| 3279 bool _finished = false; | 3279 bool _finished = false; |
| 3280 | 3280 |
| 3281 List<idl.UnlinkedExprAssignOperator> _assignmentOperators; | 3281 List<idl.UnlinkedExprAssignOperator> _assignmentOperators; |
| 3282 List<double> _doubles; | 3282 List<double> _doubles; |
| 3283 List<int> _ints; | 3283 List<int> _ints; |
| 3284 bool _isValidConst; | 3284 bool _isValidConst; |
| 3285 String _name; | |
| 3286 List<idl.UnlinkedConstOperation> _operations; | 3285 List<idl.UnlinkedConstOperation> _operations; |
| 3287 List<EntityRefBuilder> _references; | 3286 List<EntityRefBuilder> _references; |
| 3288 List<String> _strings; | 3287 List<String> _strings; |
| 3289 | 3288 |
| 3290 @override | 3289 @override |
| 3291 List<idl.UnlinkedExprAssignOperator> get assignmentOperators => _assignmentOpe
rators ??= <idl.UnlinkedExprAssignOperator>[]; | 3290 List<idl.UnlinkedExprAssignOperator> get assignmentOperators => _assignmentOpe
rators ??= <idl.UnlinkedExprAssignOperator>[]; |
| 3292 | 3291 |
| 3293 /** | 3292 /** |
| 3294 * Sequence of operators used by assignment operations. | 3293 * Sequence of operators used by assignment operations. |
| 3295 */ | 3294 */ |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3329 /** | 3328 /** |
| 3330 * Indicates whether the expression is a valid potentially constant | 3329 * Indicates whether the expression is a valid potentially constant |
| 3331 * expression. | 3330 * expression. |
| 3332 */ | 3331 */ |
| 3333 void set isValidConst(bool _value) { | 3332 void set isValidConst(bool _value) { |
| 3334 assert(!_finished); | 3333 assert(!_finished); |
| 3335 _isValidConst = _value; | 3334 _isValidConst = _value; |
| 3336 } | 3335 } |
| 3337 | 3336 |
| 3338 @override | 3337 @override |
| 3339 String get name => _name ??= ''; | |
| 3340 | |
| 3341 /** | |
| 3342 * If the expression is a [NamedExpression], the name of the expression. | |
| 3343 */ | |
| 3344 void set name(String _value) { | |
| 3345 assert(!_finished); | |
| 3346 _name = _value; | |
| 3347 } | |
| 3348 | |
| 3349 @override | |
| 3350 List<idl.UnlinkedConstOperation> get operations => _operations ??= <idl.Unlink
edConstOperation>[]; | 3338 List<idl.UnlinkedConstOperation> get operations => _operations ??= <idl.Unlink
edConstOperation>[]; |
| 3351 | 3339 |
| 3352 /** | 3340 /** |
| 3353 * Sequence of operations to execute (starting with an empty stack) to form | 3341 * Sequence of operations to execute (starting with an empty stack) to form |
| 3354 * the constant value. | 3342 * the constant value. |
| 3355 */ | 3343 */ |
| 3356 void set operations(List<idl.UnlinkedConstOperation> _value) { | 3344 void set operations(List<idl.UnlinkedConstOperation> _value) { |
| 3357 assert(!_finished); | 3345 assert(!_finished); |
| 3358 _operations = _value; | 3346 _operations = _value; |
| 3359 } | 3347 } |
| (...skipping 17 matching lines...) Expand all Loading... |
| 3377 | 3365 |
| 3378 /** | 3366 /** |
| 3379 * Sequence of strings consumed by the operations `pushString` and | 3367 * Sequence of strings consumed by the operations `pushString` and |
| 3380 * `invokeConstructor`. | 3368 * `invokeConstructor`. |
| 3381 */ | 3369 */ |
| 3382 void set strings(List<String> _value) { | 3370 void set strings(List<String> _value) { |
| 3383 assert(!_finished); | 3371 assert(!_finished); |
| 3384 _strings = _value; | 3372 _strings = _value; |
| 3385 } | 3373 } |
| 3386 | 3374 |
| 3387 UnlinkedConstBuilder({List<idl.UnlinkedExprAssignOperator> assignmentOperators
, List<double> doubles, List<int> ints, bool isValidConst, String name, List<idl
.UnlinkedConstOperation> operations, List<EntityRefBuilder> references, List<Str
ing> strings}) | 3375 UnlinkedConstBuilder({List<idl.UnlinkedExprAssignOperator> assignmentOperators
, List<double> doubles, List<int> ints, bool isValidConst, List<idl.UnlinkedCons
tOperation> operations, List<EntityRefBuilder> references, List<String> strings}
) |
| 3388 : _assignmentOperators = assignmentOperators, | 3376 : _assignmentOperators = assignmentOperators, |
| 3389 _doubles = doubles, | 3377 _doubles = doubles, |
| 3390 _ints = ints, | 3378 _ints = ints, |
| 3391 _isValidConst = isValidConst, | 3379 _isValidConst = isValidConst, |
| 3392 _name = name, | |
| 3393 _operations = operations, | 3380 _operations = operations, |
| 3394 _references = references, | 3381 _references = references, |
| 3395 _strings = strings; | 3382 _strings = strings; |
| 3396 | 3383 |
| 3397 /** | 3384 /** |
| 3398 * Flush [informative] data recursively. | 3385 * Flush [informative] data recursively. |
| 3399 */ | 3386 */ |
| 3400 void flushInformative() { | 3387 void flushInformative() { |
| 3401 _references?.forEach((b) => b.flushInformative()); | 3388 _references?.forEach((b) => b.flushInformative()); |
| 3402 } | 3389 } |
| 3403 | 3390 |
| 3404 fb.Offset finish(fb.Builder fbBuilder) { | 3391 fb.Offset finish(fb.Builder fbBuilder) { |
| 3405 assert(!_finished); | 3392 assert(!_finished); |
| 3406 _finished = true; | 3393 _finished = true; |
| 3407 fb.Offset offset_assignmentOperators; | 3394 fb.Offset offset_assignmentOperators; |
| 3408 fb.Offset offset_doubles; | 3395 fb.Offset offset_doubles; |
| 3409 fb.Offset offset_ints; | 3396 fb.Offset offset_ints; |
| 3410 fb.Offset offset_name; | |
| 3411 fb.Offset offset_operations; | 3397 fb.Offset offset_operations; |
| 3412 fb.Offset offset_references; | 3398 fb.Offset offset_references; |
| 3413 fb.Offset offset_strings; | 3399 fb.Offset offset_strings; |
| 3414 if (!(_assignmentOperators == null || _assignmentOperators.isEmpty)) { | 3400 if (!(_assignmentOperators == null || _assignmentOperators.isEmpty)) { |
| 3415 offset_assignmentOperators = fbBuilder.writeListUint8(_assignmentOperators
.map((b) => b.index).toList()); | 3401 offset_assignmentOperators = fbBuilder.writeListUint8(_assignmentOperators
.map((b) => b.index).toList()); |
| 3416 } | 3402 } |
| 3417 if (!(_doubles == null || _doubles.isEmpty)) { | 3403 if (!(_doubles == null || _doubles.isEmpty)) { |
| 3418 offset_doubles = fbBuilder.writeListFloat64(_doubles); | 3404 offset_doubles = fbBuilder.writeListFloat64(_doubles); |
| 3419 } | 3405 } |
| 3420 if (!(_ints == null || _ints.isEmpty)) { | 3406 if (!(_ints == null || _ints.isEmpty)) { |
| 3421 offset_ints = fbBuilder.writeListUint32(_ints); | 3407 offset_ints = fbBuilder.writeListUint32(_ints); |
| 3422 } | 3408 } |
| 3423 if (_name != null) { | |
| 3424 offset_name = fbBuilder.writeString(_name); | |
| 3425 } | |
| 3426 if (!(_operations == null || _operations.isEmpty)) { | 3409 if (!(_operations == null || _operations.isEmpty)) { |
| 3427 offset_operations = fbBuilder.writeListUint8(_operations.map((b) => b.inde
x).toList()); | 3410 offset_operations = fbBuilder.writeListUint8(_operations.map((b) => b.inde
x).toList()); |
| 3428 } | 3411 } |
| 3429 if (!(_references == null || _references.isEmpty)) { | 3412 if (!(_references == null || _references.isEmpty)) { |
| 3430 offset_references = fbBuilder.writeList(_references.map((b) => b.finish(fb
Builder)).toList()); | 3413 offset_references = fbBuilder.writeList(_references.map((b) => b.finish(fb
Builder)).toList()); |
| 3431 } | 3414 } |
| 3432 if (!(_strings == null || _strings.isEmpty)) { | 3415 if (!(_strings == null || _strings.isEmpty)) { |
| 3433 offset_strings = fbBuilder.writeList(_strings.map((b) => fbBuilder.writeSt
ring(b)).toList()); | 3416 offset_strings = fbBuilder.writeList(_strings.map((b) => fbBuilder.writeSt
ring(b)).toList()); |
| 3434 } | 3417 } |
| 3435 fbBuilder.startTable(); | 3418 fbBuilder.startTable(); |
| 3436 if (offset_assignmentOperators != null) { | 3419 if (offset_assignmentOperators != null) { |
| 3437 fbBuilder.addOffset(6, offset_assignmentOperators); | 3420 fbBuilder.addOffset(6, offset_assignmentOperators); |
| 3438 } | 3421 } |
| 3439 if (offset_doubles != null) { | 3422 if (offset_doubles != null) { |
| 3440 fbBuilder.addOffset(4, offset_doubles); | 3423 fbBuilder.addOffset(4, offset_doubles); |
| 3441 } | 3424 } |
| 3442 if (offset_ints != null) { | 3425 if (offset_ints != null) { |
| 3443 fbBuilder.addOffset(1, offset_ints); | 3426 fbBuilder.addOffset(1, offset_ints); |
| 3444 } | 3427 } |
| 3445 if (_isValidConst == true) { | 3428 if (_isValidConst == true) { |
| 3446 fbBuilder.addBool(5, true); | 3429 fbBuilder.addBool(5, true); |
| 3447 } | 3430 } |
| 3448 if (offset_name != null) { | |
| 3449 fbBuilder.addOffset(7, offset_name); | |
| 3450 } | |
| 3451 if (offset_operations != null) { | 3431 if (offset_operations != null) { |
| 3452 fbBuilder.addOffset(0, offset_operations); | 3432 fbBuilder.addOffset(0, offset_operations); |
| 3453 } | 3433 } |
| 3454 if (offset_references != null) { | 3434 if (offset_references != null) { |
| 3455 fbBuilder.addOffset(2, offset_references); | 3435 fbBuilder.addOffset(2, offset_references); |
| 3456 } | 3436 } |
| 3457 if (offset_strings != null) { | 3437 if (offset_strings != null) { |
| 3458 fbBuilder.addOffset(3, offset_strings); | 3438 fbBuilder.addOffset(3, offset_strings); |
| 3459 } | 3439 } |
| 3460 return fbBuilder.endTable(); | 3440 return fbBuilder.endTable(); |
| 3461 } | 3441 } |
| 3462 } | 3442 } |
| 3463 | 3443 |
| 3464 class _UnlinkedConstReader extends fb.TableReader<_UnlinkedConstImpl> { | 3444 class _UnlinkedConstReader extends fb.TableReader<_UnlinkedConstImpl> { |
| 3465 const _UnlinkedConstReader(); | 3445 const _UnlinkedConstReader(); |
| 3466 | 3446 |
| 3467 @override | 3447 @override |
| 3468 _UnlinkedConstImpl createObject(fb.BufferPointer bp) => new _UnlinkedConstImpl
(bp); | 3448 _UnlinkedConstImpl createObject(fb.BufferPointer bp) => new _UnlinkedConstImpl
(bp); |
| 3469 } | 3449 } |
| 3470 | 3450 |
| 3471 class _UnlinkedConstImpl extends Object with _UnlinkedConstMixin implements idl.
UnlinkedConst { | 3451 class _UnlinkedConstImpl extends Object with _UnlinkedConstMixin implements idl.
UnlinkedConst { |
| 3472 final fb.BufferPointer _bp; | 3452 final fb.BufferPointer _bp; |
| 3473 | 3453 |
| 3474 _UnlinkedConstImpl(this._bp); | 3454 _UnlinkedConstImpl(this._bp); |
| 3475 | 3455 |
| 3476 List<idl.UnlinkedExprAssignOperator> _assignmentOperators; | 3456 List<idl.UnlinkedExprAssignOperator> _assignmentOperators; |
| 3477 List<double> _doubles; | 3457 List<double> _doubles; |
| 3478 List<int> _ints; | 3458 List<int> _ints; |
| 3479 bool _isValidConst; | 3459 bool _isValidConst; |
| 3480 String _name; | |
| 3481 List<idl.UnlinkedConstOperation> _operations; | 3460 List<idl.UnlinkedConstOperation> _operations; |
| 3482 List<idl.EntityRef> _references; | 3461 List<idl.EntityRef> _references; |
| 3483 List<String> _strings; | 3462 List<String> _strings; |
| 3484 | 3463 |
| 3485 @override | 3464 @override |
| 3486 List<idl.UnlinkedExprAssignOperator> get assignmentOperators { | 3465 List<idl.UnlinkedExprAssignOperator> get assignmentOperators { |
| 3487 _assignmentOperators ??= const fb.ListReader<idl.UnlinkedExprAssignOperator>
(const _UnlinkedExprAssignOperatorReader()).vTableGet(_bp, 6, const <idl.Unlinke
dExprAssignOperator>[]); | 3466 _assignmentOperators ??= const fb.ListReader<idl.UnlinkedExprAssignOperator>
(const _UnlinkedExprAssignOperatorReader()).vTableGet(_bp, 6, const <idl.Unlinke
dExprAssignOperator>[]); |
| 3488 return _assignmentOperators; | 3467 return _assignmentOperators; |
| 3489 } | 3468 } |
| 3490 | 3469 |
| 3491 @override | 3470 @override |
| 3492 List<double> get doubles { | 3471 List<double> get doubles { |
| 3493 _doubles ??= const fb.Float64ListReader().vTableGet(_bp, 4, const <double>[]
); | 3472 _doubles ??= const fb.Float64ListReader().vTableGet(_bp, 4, const <double>[]
); |
| 3494 return _doubles; | 3473 return _doubles; |
| 3495 } | 3474 } |
| 3496 | 3475 |
| 3497 @override | 3476 @override |
| 3498 List<int> get ints { | 3477 List<int> get ints { |
| 3499 _ints ??= const fb.Uint32ListReader().vTableGet(_bp, 1, const <int>[]); | 3478 _ints ??= const fb.Uint32ListReader().vTableGet(_bp, 1, const <int>[]); |
| 3500 return _ints; | 3479 return _ints; |
| 3501 } | 3480 } |
| 3502 | 3481 |
| 3503 @override | 3482 @override |
| 3504 bool get isValidConst { | 3483 bool get isValidConst { |
| 3505 _isValidConst ??= const fb.BoolReader().vTableGet(_bp, 5, false); | 3484 _isValidConst ??= const fb.BoolReader().vTableGet(_bp, 5, false); |
| 3506 return _isValidConst; | 3485 return _isValidConst; |
| 3507 } | 3486 } |
| 3508 | 3487 |
| 3509 @override | 3488 @override |
| 3510 String get name { | |
| 3511 _name ??= const fb.StringReader().vTableGet(_bp, 7, ''); | |
| 3512 return _name; | |
| 3513 } | |
| 3514 | |
| 3515 @override | |
| 3516 List<idl.UnlinkedConstOperation> get operations { | 3489 List<idl.UnlinkedConstOperation> get operations { |
| 3517 _operations ??= const fb.ListReader<idl.UnlinkedConstOperation>(const _Unlin
kedConstOperationReader()).vTableGet(_bp, 0, const <idl.UnlinkedConstOperation>[
]); | 3490 _operations ??= const fb.ListReader<idl.UnlinkedConstOperation>(const _Unlin
kedConstOperationReader()).vTableGet(_bp, 0, const <idl.UnlinkedConstOperation>[
]); |
| 3518 return _operations; | 3491 return _operations; |
| 3519 } | 3492 } |
| 3520 | 3493 |
| 3521 @override | 3494 @override |
| 3522 List<idl.EntityRef> get references { | 3495 List<idl.EntityRef> get references { |
| 3523 _references ??= const fb.ListReader<idl.EntityRef>(const _EntityRefReader())
.vTableGet(_bp, 2, const <idl.EntityRef>[]); | 3496 _references ??= const fb.ListReader<idl.EntityRef>(const _EntityRefReader())
.vTableGet(_bp, 2, const <idl.EntityRef>[]); |
| 3524 return _references; | 3497 return _references; |
| 3525 } | 3498 } |
| 3526 | 3499 |
| 3527 @override | 3500 @override |
| 3528 List<String> get strings { | 3501 List<String> get strings { |
| 3529 _strings ??= const fb.ListReader<String>(const fb.StringReader()).vTableGet(
_bp, 3, const <String>[]); | 3502 _strings ??= const fb.ListReader<String>(const fb.StringReader()).vTableGet(
_bp, 3, const <String>[]); |
| 3530 return _strings; | 3503 return _strings; |
| 3531 } | 3504 } |
| 3532 } | 3505 } |
| 3533 | 3506 |
| 3534 abstract class _UnlinkedConstMixin implements idl.UnlinkedConst { | 3507 abstract class _UnlinkedConstMixin implements idl.UnlinkedConst { |
| 3535 @override | 3508 @override |
| 3536 Map<String, Object> toJson() { | 3509 Map<String, Object> toJson() { |
| 3537 Map<String, Object> _result = <String, Object>{}; | 3510 Map<String, Object> _result = <String, Object>{}; |
| 3538 if (assignmentOperators.isNotEmpty) _result["assignmentOperators"] = assignm
entOperators.map((_value) => _value.toString().split('.')[1]).toList(); | 3511 if (assignmentOperators.isNotEmpty) _result["assignmentOperators"] = assignm
entOperators.map((_value) => _value.toString().split('.')[1]).toList(); |
| 3539 if (doubles.isNotEmpty) _result["doubles"] = doubles.map((_value) => _value.
isFinite ? _value : _value.toString()).toList(); | 3512 if (doubles.isNotEmpty) _result["doubles"] = doubles.map((_value) => _value.
isFinite ? _value : _value.toString()).toList(); |
| 3540 if (ints.isNotEmpty) _result["ints"] = ints; | 3513 if (ints.isNotEmpty) _result["ints"] = ints; |
| 3541 if (isValidConst != false) _result["isValidConst"] = isValidConst; | 3514 if (isValidConst != false) _result["isValidConst"] = isValidConst; |
| 3542 if (name != '') _result["name"] = name; | |
| 3543 if (operations.isNotEmpty) _result["operations"] = operations.map((_value) =
> _value.toString().split('.')[1]).toList(); | 3515 if (operations.isNotEmpty) _result["operations"] = operations.map((_value) =
> _value.toString().split('.')[1]).toList(); |
| 3544 if (references.isNotEmpty) _result["references"] = references.map((_value) =
> _value.toJson()).toList(); | 3516 if (references.isNotEmpty) _result["references"] = references.map((_value) =
> _value.toJson()).toList(); |
| 3545 if (strings.isNotEmpty) _result["strings"] = strings; | 3517 if (strings.isNotEmpty) _result["strings"] = strings; |
| 3546 return _result; | 3518 return _result; |
| 3547 } | 3519 } |
| 3548 | 3520 |
| 3549 @override | 3521 @override |
| 3550 Map<String, Object> toMap() => { | 3522 Map<String, Object> toMap() => { |
| 3551 "assignmentOperators": assignmentOperators, | 3523 "assignmentOperators": assignmentOperators, |
| 3552 "doubles": doubles, | 3524 "doubles": doubles, |
| 3553 "ints": ints, | 3525 "ints": ints, |
| 3554 "isValidConst": isValidConst, | 3526 "isValidConst": isValidConst, |
| 3555 "name": name, | |
| 3556 "operations": operations, | 3527 "operations": operations, |
| 3557 "references": references, | 3528 "references": references, |
| 3558 "strings": strings, | 3529 "strings": strings, |
| 3559 }; | 3530 }; |
| 3560 | 3531 |
| 3561 @override | 3532 @override |
| 3562 String toString() => convert.JSON.encode(toJson()); | 3533 String toString() => convert.JSON.encode(toJson()); |
| 3563 } | 3534 } |
| 3564 | 3535 |
| 3565 class UnlinkedConstructorInitializerBuilder extends Object with _UnlinkedConstru
ctorInitializerMixin implements idl.UnlinkedConstructorInitializer { | 3536 class UnlinkedConstructorInitializerBuilder extends Object with _UnlinkedConstru
ctorInitializerMixin implements idl.UnlinkedConstructorInitializer { |
| 3566 bool _finished = false; | 3537 bool _finished = false; |
| 3567 | 3538 |
| 3568 List<UnlinkedConstBuilder> _arguments; | 3539 List<UnlinkedConstBuilder> _arguments; |
| 3540 List<String> _argumentNames; |
| 3569 UnlinkedConstBuilder _expression; | 3541 UnlinkedConstBuilder _expression; |
| 3570 idl.UnlinkedConstructorInitializerKind _kind; | 3542 idl.UnlinkedConstructorInitializerKind _kind; |
| 3571 String _name; | 3543 String _name; |
| 3572 | 3544 |
| 3573 @override | 3545 @override |
| 3574 List<UnlinkedConstBuilder> get arguments => _arguments ??= <UnlinkedConstBuild
er>[]; | 3546 List<UnlinkedConstBuilder> get arguments => _arguments ??= <UnlinkedConstBuild
er>[]; |
| 3575 | 3547 |
| 3576 /** | 3548 /** |
| 3577 * If [kind] is `thisInvocation` or `superInvocation`, the arguments of the | 3549 * If [kind] is `thisInvocation` or `superInvocation`, the arguments of the |
| 3578 * invocation. Otherwise empty. | 3550 * invocation. Otherwise empty. |
| 3579 */ | 3551 */ |
| 3580 void set arguments(List<UnlinkedConstBuilder> _value) { | 3552 void set arguments(List<UnlinkedConstBuilder> _value) { |
| 3581 assert(!_finished); | 3553 assert(!_finished); |
| 3582 _arguments = _value; | 3554 _arguments = _value; |
| 3583 } | 3555 } |
| 3584 | 3556 |
| 3585 @override | 3557 @override |
| 3558 List<String> get argumentNames => _argumentNames ??= <String>[]; |
| 3559 |
| 3560 /** |
| 3561 * If there are `m` [arguments] and `n` [argumentNames], then each argument |
| 3562 * from [arguments] with index `i` such that `n + i - m >= 0`, should be used |
| 3563 * with the name at `n + i - m`. |
| 3564 */ |
| 3565 void set argumentNames(List<String> _value) { |
| 3566 assert(!_finished); |
| 3567 _argumentNames = _value; |
| 3568 } |
| 3569 |
| 3570 @override |
| 3586 UnlinkedConstBuilder get expression => _expression; | 3571 UnlinkedConstBuilder get expression => _expression; |
| 3587 | 3572 |
| 3588 /** | 3573 /** |
| 3589 * If [kind] is `field`, the expression of the field initializer. | 3574 * If [kind] is `field`, the expression of the field initializer. |
| 3590 * Otherwise `null`. | 3575 * Otherwise `null`. |
| 3591 */ | 3576 */ |
| 3592 void set expression(UnlinkedConstBuilder _value) { | 3577 void set expression(UnlinkedConstBuilder _value) { |
| 3593 assert(!_finished); | 3578 assert(!_finished); |
| 3594 _expression = _value; | 3579 _expression = _value; |
| 3595 } | 3580 } |
| (...skipping 16 matching lines...) Expand all Loading... |
| 3612 * If [kind] is `field`, the name of the field declared in the class. If | 3597 * If [kind] is `field`, the name of the field declared in the class. If |
| 3613 * [kind] is `thisInvocation`, the name of the constructor, declared in this | 3598 * [kind] is `thisInvocation`, the name of the constructor, declared in this |
| 3614 * class, to redirect to. If [kind] is `superInvocation`, the name of the | 3599 * class, to redirect to. If [kind] is `superInvocation`, the name of the |
| 3615 * constructor, declared in the superclass, to invoke. | 3600 * constructor, declared in the superclass, to invoke. |
| 3616 */ | 3601 */ |
| 3617 void set name(String _value) { | 3602 void set name(String _value) { |
| 3618 assert(!_finished); | 3603 assert(!_finished); |
| 3619 _name = _value; | 3604 _name = _value; |
| 3620 } | 3605 } |
| 3621 | 3606 |
| 3622 UnlinkedConstructorInitializerBuilder({List<UnlinkedConstBuilder> arguments, U
nlinkedConstBuilder expression, idl.UnlinkedConstructorInitializerKind kind, Str
ing name}) | 3607 UnlinkedConstructorInitializerBuilder({List<UnlinkedConstBuilder> arguments, L
ist<String> argumentNames, UnlinkedConstBuilder expression, idl.UnlinkedConstruc
torInitializerKind kind, String name}) |
| 3623 : _arguments = arguments, | 3608 : _arguments = arguments, |
| 3609 _argumentNames = argumentNames, |
| 3624 _expression = expression, | 3610 _expression = expression, |
| 3625 _kind = kind, | 3611 _kind = kind, |
| 3626 _name = name; | 3612 _name = name; |
| 3627 | 3613 |
| 3628 /** | 3614 /** |
| 3629 * Flush [informative] data recursively. | 3615 * Flush [informative] data recursively. |
| 3630 */ | 3616 */ |
| 3631 void flushInformative() { | 3617 void flushInformative() { |
| 3632 _arguments?.forEach((b) => b.flushInformative()); | 3618 _arguments?.forEach((b) => b.flushInformative()); |
| 3633 _expression?.flushInformative(); | 3619 _expression?.flushInformative(); |
| 3634 } | 3620 } |
| 3635 | 3621 |
| 3636 fb.Offset finish(fb.Builder fbBuilder) { | 3622 fb.Offset finish(fb.Builder fbBuilder) { |
| 3637 assert(!_finished); | 3623 assert(!_finished); |
| 3638 _finished = true; | 3624 _finished = true; |
| 3639 fb.Offset offset_arguments; | 3625 fb.Offset offset_arguments; |
| 3626 fb.Offset offset_argumentNames; |
| 3640 fb.Offset offset_expression; | 3627 fb.Offset offset_expression; |
| 3641 fb.Offset offset_name; | 3628 fb.Offset offset_name; |
| 3642 if (!(_arguments == null || _arguments.isEmpty)) { | 3629 if (!(_arguments == null || _arguments.isEmpty)) { |
| 3643 offset_arguments = fbBuilder.writeList(_arguments.map((b) => b.finish(fbBu
ilder)).toList()); | 3630 offset_arguments = fbBuilder.writeList(_arguments.map((b) => b.finish(fbBu
ilder)).toList()); |
| 3644 } | 3631 } |
| 3632 if (!(_argumentNames == null || _argumentNames.isEmpty)) { |
| 3633 offset_argumentNames = fbBuilder.writeList(_argumentNames.map((b) => fbBui
lder.writeString(b)).toList()); |
| 3634 } |
| 3645 if (_expression != null) { | 3635 if (_expression != null) { |
| 3646 offset_expression = _expression.finish(fbBuilder); | 3636 offset_expression = _expression.finish(fbBuilder); |
| 3647 } | 3637 } |
| 3648 if (_name != null) { | 3638 if (_name != null) { |
| 3649 offset_name = fbBuilder.writeString(_name); | 3639 offset_name = fbBuilder.writeString(_name); |
| 3650 } | 3640 } |
| 3651 fbBuilder.startTable(); | 3641 fbBuilder.startTable(); |
| 3652 if (offset_arguments != null) { | 3642 if (offset_arguments != null) { |
| 3653 fbBuilder.addOffset(3, offset_arguments); | 3643 fbBuilder.addOffset(3, offset_arguments); |
| 3654 } | 3644 } |
| 3645 if (offset_argumentNames != null) { |
| 3646 fbBuilder.addOffset(4, offset_argumentNames); |
| 3647 } |
| 3655 if (offset_expression != null) { | 3648 if (offset_expression != null) { |
| 3656 fbBuilder.addOffset(1, offset_expression); | 3649 fbBuilder.addOffset(1, offset_expression); |
| 3657 } | 3650 } |
| 3658 if (_kind != null && _kind != idl.UnlinkedConstructorInitializerKind.field)
{ | 3651 if (_kind != null && _kind != idl.UnlinkedConstructorInitializerKind.field)
{ |
| 3659 fbBuilder.addUint8(2, _kind.index); | 3652 fbBuilder.addUint8(2, _kind.index); |
| 3660 } | 3653 } |
| 3661 if (offset_name != null) { | 3654 if (offset_name != null) { |
| 3662 fbBuilder.addOffset(0, offset_name); | 3655 fbBuilder.addOffset(0, offset_name); |
| 3663 } | 3656 } |
| 3664 return fbBuilder.endTable(); | 3657 return fbBuilder.endTable(); |
| 3665 } | 3658 } |
| 3666 } | 3659 } |
| 3667 | 3660 |
| 3668 class _UnlinkedConstructorInitializerReader extends fb.TableReader<_UnlinkedCons
tructorInitializerImpl> { | 3661 class _UnlinkedConstructorInitializerReader extends fb.TableReader<_UnlinkedCons
tructorInitializerImpl> { |
| 3669 const _UnlinkedConstructorInitializerReader(); | 3662 const _UnlinkedConstructorInitializerReader(); |
| 3670 | 3663 |
| 3671 @override | 3664 @override |
| 3672 _UnlinkedConstructorInitializerImpl createObject(fb.BufferPointer bp) => new _
UnlinkedConstructorInitializerImpl(bp); | 3665 _UnlinkedConstructorInitializerImpl createObject(fb.BufferPointer bp) => new _
UnlinkedConstructorInitializerImpl(bp); |
| 3673 } | 3666 } |
| 3674 | 3667 |
| 3675 class _UnlinkedConstructorInitializerImpl extends Object with _UnlinkedConstruct
orInitializerMixin implements idl.UnlinkedConstructorInitializer { | 3668 class _UnlinkedConstructorInitializerImpl extends Object with _UnlinkedConstruct
orInitializerMixin implements idl.UnlinkedConstructorInitializer { |
| 3676 final fb.BufferPointer _bp; | 3669 final fb.BufferPointer _bp; |
| 3677 | 3670 |
| 3678 _UnlinkedConstructorInitializerImpl(this._bp); | 3671 _UnlinkedConstructorInitializerImpl(this._bp); |
| 3679 | 3672 |
| 3680 List<idl.UnlinkedConst> _arguments; | 3673 List<idl.UnlinkedConst> _arguments; |
| 3674 List<String> _argumentNames; |
| 3681 idl.UnlinkedConst _expression; | 3675 idl.UnlinkedConst _expression; |
| 3682 idl.UnlinkedConstructorInitializerKind _kind; | 3676 idl.UnlinkedConstructorInitializerKind _kind; |
| 3683 String _name; | 3677 String _name; |
| 3684 | 3678 |
| 3685 @override | 3679 @override |
| 3686 List<idl.UnlinkedConst> get arguments { | 3680 List<idl.UnlinkedConst> get arguments { |
| 3687 _arguments ??= const fb.ListReader<idl.UnlinkedConst>(const _UnlinkedConstRe
ader()).vTableGet(_bp, 3, const <idl.UnlinkedConst>[]); | 3681 _arguments ??= const fb.ListReader<idl.UnlinkedConst>(const _UnlinkedConstRe
ader()).vTableGet(_bp, 3, const <idl.UnlinkedConst>[]); |
| 3688 return _arguments; | 3682 return _arguments; |
| 3689 } | 3683 } |
| 3690 | 3684 |
| 3691 @override | 3685 @override |
| 3686 List<String> get argumentNames { |
| 3687 _argumentNames ??= const fb.ListReader<String>(const fb.StringReader()).vTab
leGet(_bp, 4, const <String>[]); |
| 3688 return _argumentNames; |
| 3689 } |
| 3690 |
| 3691 @override |
| 3692 idl.UnlinkedConst get expression { | 3692 idl.UnlinkedConst get expression { |
| 3693 _expression ??= const _UnlinkedConstReader().vTableGet(_bp, 1, null); | 3693 _expression ??= const _UnlinkedConstReader().vTableGet(_bp, 1, null); |
| 3694 return _expression; | 3694 return _expression; |
| 3695 } | 3695 } |
| 3696 | 3696 |
| 3697 @override | 3697 @override |
| 3698 idl.UnlinkedConstructorInitializerKind get kind { | 3698 idl.UnlinkedConstructorInitializerKind get kind { |
| 3699 _kind ??= const _UnlinkedConstructorInitializerKindReader().vTableGet(_bp, 2
, idl.UnlinkedConstructorInitializerKind.field); | 3699 _kind ??= const _UnlinkedConstructorInitializerKindReader().vTableGet(_bp, 2
, idl.UnlinkedConstructorInitializerKind.field); |
| 3700 return _kind; | 3700 return _kind; |
| 3701 } | 3701 } |
| 3702 | 3702 |
| 3703 @override | 3703 @override |
| 3704 String get name { | 3704 String get name { |
| 3705 _name ??= const fb.StringReader().vTableGet(_bp, 0, ''); | 3705 _name ??= const fb.StringReader().vTableGet(_bp, 0, ''); |
| 3706 return _name; | 3706 return _name; |
| 3707 } | 3707 } |
| 3708 } | 3708 } |
| 3709 | 3709 |
| 3710 abstract class _UnlinkedConstructorInitializerMixin implements idl.UnlinkedConst
ructorInitializer { | 3710 abstract class _UnlinkedConstructorInitializerMixin implements idl.UnlinkedConst
ructorInitializer { |
| 3711 @override | 3711 @override |
| 3712 Map<String, Object> toJson() { | 3712 Map<String, Object> toJson() { |
| 3713 Map<String, Object> _result = <String, Object>{}; | 3713 Map<String, Object> _result = <String, Object>{}; |
| 3714 if (arguments.isNotEmpty) _result["arguments"] = arguments.map((_value) => _
value.toJson()).toList(); | 3714 if (arguments.isNotEmpty) _result["arguments"] = arguments.map((_value) => _
value.toJson()).toList(); |
| 3715 if (argumentNames.isNotEmpty) _result["argumentNames"] = argumentNames; |
| 3715 if (expression != null) _result["expression"] = expression.toJson(); | 3716 if (expression != null) _result["expression"] = expression.toJson(); |
| 3716 if (kind != idl.UnlinkedConstructorInitializerKind.field) _result["kind"] =
kind.toString().split('.')[1]; | 3717 if (kind != idl.UnlinkedConstructorInitializerKind.field) _result["kind"] =
kind.toString().split('.')[1]; |
| 3717 if (name != '') _result["name"] = name; | 3718 if (name != '') _result["name"] = name; |
| 3718 return _result; | 3719 return _result; |
| 3719 } | 3720 } |
| 3720 | 3721 |
| 3721 @override | 3722 @override |
| 3722 Map<String, Object> toMap() => { | 3723 Map<String, Object> toMap() => { |
| 3723 "arguments": arguments, | 3724 "arguments": arguments, |
| 3725 "argumentNames": argumentNames, |
| 3724 "expression": expression, | 3726 "expression": expression, |
| 3725 "kind": kind, | 3727 "kind": kind, |
| 3726 "name": name, | 3728 "name": name, |
| 3727 }; | 3729 }; |
| 3728 | 3730 |
| 3729 @override | 3731 @override |
| 3730 String toString() => convert.JSON.encode(toJson()); | 3732 String toString() => convert.JSON.encode(toJson()); |
| 3731 } | 3733 } |
| 3732 | 3734 |
| 3733 class UnlinkedDocumentationCommentBuilder extends Object with _UnlinkedDocumenta
tionCommentMixin implements idl.UnlinkedDocumentationComment { | 3735 class UnlinkedDocumentationCommentBuilder extends Object with _UnlinkedDocumenta
tionCommentMixin implements idl.UnlinkedDocumentationComment { |
| (...skipping 4703 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8437 "propagatedTypeSlot": propagatedTypeSlot, | 8439 "propagatedTypeSlot": propagatedTypeSlot, |
| 8438 "type": type, | 8440 "type": type, |
| 8439 "visibleLength": visibleLength, | 8441 "visibleLength": visibleLength, |
| 8440 "visibleOffset": visibleOffset, | 8442 "visibleOffset": visibleOffset, |
| 8441 }; | 8443 }; |
| 8442 | 8444 |
| 8443 @override | 8445 @override |
| 8444 String toString() => convert.JSON.encode(toJson()); | 8446 String toString() => convert.JSON.encode(toJson()); |
| 8445 } | 8447 } |
| 8446 | 8448 |
| OLD | NEW |