| OLD | NEW |
| 1 // This code was auto-generated, is not intended to be edited, and is subject to | 1 // This code was auto-generated, is not intended to be edited, and is subject to |
| 2 // significant change. Please see the README file for more information. | 2 // significant change. Please see the README file for more information. |
| 3 library engine.element; | 3 library engine.element; |
| 4 import 'dart:collection'; | 4 import 'dart:collection'; |
| 5 import 'java_core.dart'; | 5 import 'java_core.dart'; |
| 6 import 'java_engine.dart'; | 6 import 'java_engine.dart'; |
| 7 import 'utilities_collection.dart'; | 7 import 'utilities_collection.dart'; |
| 8 import 'source.dart'; | 8 import 'source.dart'; |
| 9 import 'scanner.dart' show Keyword; | 9 import 'scanner.dart' show Keyword; |
| 10 import 'ast.dart' show Identifier, LibraryIdentifier; | 10 import 'ast.dart' show Identifier, LibraryIdentifier; |
| (...skipping 955 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 966 */ | 966 */ |
| 967 LibraryElement get importedLibrary; | 967 LibraryElement get importedLibrary; |
| 968 | 968 |
| 969 /** | 969 /** |
| 970 * Return the prefix that was specified as part of the import directive, or `n
ull` if there | 970 * Return the prefix that was specified as part of the import directive, or `n
ull` if there |
| 971 * was no prefix specified. | 971 * was no prefix specified. |
| 972 * | 972 * |
| 973 * @return the prefix that was specified as part of the import directive | 973 * @return the prefix that was specified as part of the import directive |
| 974 */ | 974 */ |
| 975 PrefixElement get prefix; | 975 PrefixElement get prefix; |
| 976 |
| 977 /** |
| 978 * Return the offset of the prefix of this import in the file that contains th
is import directive, |
| 979 * or `-1` if this import is synthetic, does not have a prefix, or otherwise d
oes not have |
| 980 * an offset. |
| 981 * |
| 982 * @return the offset of the prefix of this import |
| 983 */ |
| 984 int get prefixOffset; |
| 985 |
| 986 /** |
| 987 * Return the offset of the character immediately following the last character
of this node's URI, |
| 988 * or `-1` for synthetic import. |
| 989 * |
| 990 * @return the offset of the character just past the node's URI |
| 991 */ |
| 992 int get uriEnd; |
| 976 } | 993 } |
| 977 /** | 994 /** |
| 978 * The interface `LabelElement` defines the behavior of elements representing a
label | 995 * The interface `LabelElement` defines the behavior of elements representing a
label |
| 979 * associated with a statement. | 996 * associated with a statement. |
| 980 * | 997 * |
| 981 * @coverage dart.engine.element | 998 * @coverage dart.engine.element |
| 982 */ | 999 */ |
| 983 abstract class LabelElement implements Element { | 1000 abstract class LabelElement implements Element { |
| 984 | 1001 |
| 985 /** | 1002 /** |
| (...skipping 2833 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3819 HtmlScriptElementImpl(XmlTagNode node) : super.con2(node.tag.lexeme, node.tag.
offset); | 3836 HtmlScriptElementImpl(XmlTagNode node) : super.con2(node.tag.lexeme, node.tag.
offset); |
| 3820 } | 3837 } |
| 3821 /** | 3838 /** |
| 3822 * Instances of the class `ImportElementImpl` implement an [ImportElement]. | 3839 * Instances of the class `ImportElementImpl` implement an [ImportElement]. |
| 3823 * | 3840 * |
| 3824 * @coverage dart.engine.element | 3841 * @coverage dart.engine.element |
| 3825 */ | 3842 */ |
| 3826 class ImportElementImpl extends ElementImpl implements ImportElement { | 3843 class ImportElementImpl extends ElementImpl implements ImportElement { |
| 3827 | 3844 |
| 3828 /** | 3845 /** |
| 3846 * The offset of this directive, may be `-1` if synthetic. |
| 3847 */ |
| 3848 int _offset = -1; |
| 3849 |
| 3850 /** |
| 3851 * The offset of the character immediately following the last character of thi
s node's URI, may be |
| 3852 * `-1` if synthetic. |
| 3853 */ |
| 3854 int _uriEnd = -1; |
| 3855 |
| 3856 /** |
| 3857 * The offset of the prefix of this import in the file that contains the this
import directive, or |
| 3858 * `-1` if this import is synthetic. |
| 3859 */ |
| 3860 int _prefixOffset = 0; |
| 3861 |
| 3862 /** |
| 3829 * The URI that is specified by this directive. | 3863 * The URI that is specified by this directive. |
| 3830 */ | 3864 */ |
| 3831 String _uri; | 3865 String _uri; |
| 3832 | 3866 |
| 3833 /** | 3867 /** |
| 3834 * The library that is imported into this library by this import directive. | 3868 * The library that is imported into this library by this import directive. |
| 3835 */ | 3869 */ |
| 3836 LibraryElement _importedLibrary; | 3870 LibraryElement _importedLibrary; |
| 3837 | 3871 |
| 3838 /** | 3872 /** |
| (...skipping 10 matching lines...) Expand all Loading... |
| 3849 | 3883 |
| 3850 /** | 3884 /** |
| 3851 * Initialize a newly created import element. | 3885 * Initialize a newly created import element. |
| 3852 */ | 3886 */ |
| 3853 ImportElementImpl() : super.con1(null); | 3887 ImportElementImpl() : super.con1(null); |
| 3854 accept(ElementVisitor visitor) => visitor.visitImportElement(this); | 3888 accept(ElementVisitor visitor) => visitor.visitImportElement(this); |
| 3855 List<NamespaceCombinator> get combinators => _combinators; | 3889 List<NamespaceCombinator> get combinators => _combinators; |
| 3856 LibraryElement get importedLibrary => _importedLibrary; | 3890 LibraryElement get importedLibrary => _importedLibrary; |
| 3857 ElementKind get kind => ElementKind.IMPORT; | 3891 ElementKind get kind => ElementKind.IMPORT; |
| 3858 PrefixElement get prefix => _prefix; | 3892 PrefixElement get prefix => _prefix; |
| 3893 int get prefixOffset => _prefixOffset; |
| 3859 String get uri => _uri; | 3894 String get uri => _uri; |
| 3895 int get uriEnd => _uriEnd; |
| 3860 | 3896 |
| 3861 /** | 3897 /** |
| 3862 * Set the combinators that were specified as part of the import directive to
the given array of | 3898 * Set the combinators that were specified as part of the import directive to
the given array of |
| 3863 * combinators. | 3899 * combinators. |
| 3864 * | 3900 * |
| 3865 * @param combinators the combinators that were specified as part of the impor
t directive | 3901 * @param combinators the combinators that were specified as part of the impor
t directive |
| 3866 */ | 3902 */ |
| 3867 void set combinators(List<NamespaceCombinator> combinators) { | 3903 void set combinators(List<NamespaceCombinator> combinators) { |
| 3868 this._combinators = combinators; | 3904 this._combinators = combinators; |
| 3869 } | 3905 } |
| 3870 | 3906 |
| 3871 /** | 3907 /** |
| 3872 * Set the library that is imported into this library by this import directive
to the given | 3908 * Set the library that is imported into this library by this import directive
to the given |
| 3873 * library. | 3909 * library. |
| 3874 * | 3910 * |
| 3875 * @param importedLibrary the library that is imported into this library | 3911 * @param importedLibrary the library that is imported into this library |
| 3876 */ | 3912 */ |
| 3877 void set importedLibrary(LibraryElement importedLibrary) { | 3913 void set importedLibrary(LibraryElement importedLibrary) { |
| 3878 this._importedLibrary = importedLibrary; | 3914 this._importedLibrary = importedLibrary; |
| 3879 } | 3915 } |
| 3880 | 3916 |
| 3881 /** | 3917 /** |
| 3918 * Set the offset of this directive. |
| 3919 */ |
| 3920 void set offset(int offset) { |
| 3921 this._offset = offset; |
| 3922 } |
| 3923 |
| 3924 /** |
| 3882 * Set the prefix that was specified as part of the import directive to the gi
ven prefix. | 3925 * Set the prefix that was specified as part of the import directive to the gi
ven prefix. |
| 3883 * | 3926 * |
| 3884 * @param prefix the prefix that was specified as part of the import directive | 3927 * @param prefix the prefix that was specified as part of the import directive |
| 3885 */ | 3928 */ |
| 3886 void set prefix(PrefixElement prefix) { | 3929 void set prefix(PrefixElement prefix) { |
| 3887 this._prefix = prefix; | 3930 this._prefix = prefix; |
| 3888 } | 3931 } |
| 3889 | 3932 |
| 3890 /** | 3933 /** |
| 3934 * Set the offset of the prefix of this import in the file that contains the t
his import |
| 3935 * directive. |
| 3936 */ |
| 3937 void set prefixOffset(int prefixOffset) { |
| 3938 this._prefixOffset = prefixOffset; |
| 3939 } |
| 3940 |
| 3941 /** |
| 3891 * Set the URI that is specified by this directive. | 3942 * Set the URI that is specified by this directive. |
| 3892 * | 3943 * |
| 3893 * @param uri the URI that is specified by this directive. | 3944 * @param uri the URI that is specified by this directive. |
| 3894 */ | 3945 */ |
| 3895 void set uri(String uri) { | 3946 void set uri(String uri) { |
| 3896 this._uri = uri; | 3947 this._uri = uri; |
| 3897 } | 3948 } |
| 3949 |
| 3950 /** |
| 3951 * Set the the offset of the character immediately following the last characte
r of this node's |
| 3952 * URI. `-1` for synthetic import. |
| 3953 */ |
| 3954 void set uriEnd(int uriEnd) { |
| 3955 this._uriEnd = uriEnd; |
| 3956 } |
| 3898 void visitChildren(ElementVisitor visitor) { | 3957 void visitChildren(ElementVisitor visitor) { |
| 3899 super.visitChildren(visitor); | 3958 super.visitChildren(visitor); |
| 3900 safelyVisitChild(_prefix, visitor); | 3959 safelyVisitChild(_prefix, visitor); |
| 3901 } | 3960 } |
| 3902 void appendTo(JavaStringBuilder builder) { | 3961 void appendTo(JavaStringBuilder builder) { |
| 3903 builder.append("import "); | 3962 builder.append("import "); |
| 3904 ((_importedLibrary as LibraryElementImpl)).appendTo(builder); | 3963 ((_importedLibrary as LibraryElementImpl)).appendTo(builder); |
| 3905 } | 3964 } |
| 3906 String get identifier => ((_importedLibrary as LibraryElementImpl)).identifier
; | 3965 String get identifier => "${((_importedLibrary as LibraryElementImpl)).identif
ier}@${_offset}"; |
| 3907 } | 3966 } |
| 3908 /** | 3967 /** |
| 3909 * Instances of the class `LabelElementImpl` implement a `LabelElement`. | 3968 * Instances of the class `LabelElementImpl` implement a `LabelElement`. |
| 3910 * | 3969 * |
| 3911 * @coverage dart.engine.element | 3970 * @coverage dart.engine.element |
| 3912 */ | 3971 */ |
| 3913 class LabelElementImpl extends ElementImpl implements LabelElement { | 3972 class LabelElementImpl extends ElementImpl implements LabelElement { |
| 3914 | 3973 |
| 3915 /** | 3974 /** |
| 3916 * A flag indicating whether this label is associated with a `switch` statemen
t. | 3975 * A flag indicating whether this label is associated with a `switch` statemen
t. |
| (...skipping 2757 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6674 return false; | 6733 return false; |
| 6675 } | 6734 } |
| 6676 } | 6735 } |
| 6677 return true; | 6736 return true; |
| 6678 } | 6737 } |
| 6679 ClassElement element = this.element; | 6738 ClassElement element = this.element; |
| 6680 if (element == null || visitedClasses.contains(element)) { | 6739 if (element == null || visitedClasses.contains(element)) { |
| 6681 return false; | 6740 return false; |
| 6682 } | 6741 } |
| 6683 javaSetAdd(visitedClasses, element); | 6742 javaSetAdd(visitedClasses, element); |
| 6684 InterfaceType supertype = element.supertype; | 6743 InterfaceType supertype = superclass; |
| 6685 if (supertype != null && ((supertype as InterfaceTypeImpl)).isMoreSpecificTh
an2(s, visitedClasses)) { | 6744 if (supertype != null && ((supertype as InterfaceTypeImpl)).isMoreSpecificTh
an2(s, visitedClasses)) { |
| 6686 return true; | 6745 return true; |
| 6687 } | 6746 } |
| 6688 for (InterfaceType interfaceType in element.interfaces) { | 6747 for (InterfaceType interfaceType in interfaces) { |
| 6689 if (((interfaceType as InterfaceTypeImpl)).isMoreSpecificThan2(s, visitedC
lasses)) { | 6748 if (((interfaceType as InterfaceTypeImpl)).isMoreSpecificThan2(s, visitedC
lasses)) { |
| 6690 return true; | 6749 return true; |
| 6691 } | 6750 } |
| 6692 } | 6751 } |
| 6693 for (InterfaceType mixinType in element.mixins) { | 6752 for (InterfaceType mixinType in mixins) { |
| 6694 if (((mixinType as InterfaceTypeImpl)).isMoreSpecificThan2(s, visitedClass
es)) { | 6753 if (((mixinType as InterfaceTypeImpl)).isMoreSpecificThan2(s, visitedClass
es)) { |
| 6695 return true; | 6754 return true; |
| 6696 } | 6755 } |
| 6697 } | 6756 } |
| 6698 return false; | 6757 return false; |
| 6699 } | 6758 } |
| 6700 bool isSubtypeOf2(InterfaceType type, Set<ClassElement> visitedClasses) { | 6759 bool isSubtypeOf2(InterfaceType type, Set<ClassElement> visitedClasses) { |
| 6701 InterfaceType typeT = this; | 6760 InterfaceType typeT = this; |
| 6702 InterfaceType typeS = type; | 6761 InterfaceType typeS = type; |
| 6703 ClassElement elementT = element; | 6762 ClassElement elementT = element; |
| (...skipping 808 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 7512 } | 7571 } |
| 7513 /** | 7572 /** |
| 7514 * The interface `VoidType` defines the behavior of the unique object representi
ng the type | 7573 * The interface `VoidType` defines the behavior of the unique object representi
ng the type |
| 7515 * `void`. | 7574 * `void`. |
| 7516 * | 7575 * |
| 7517 * @coverage dart.engine.type | 7576 * @coverage dart.engine.type |
| 7518 */ | 7577 */ |
| 7519 abstract class VoidType implements Type2 { | 7578 abstract class VoidType implements Type2 { |
| 7520 VoidType substitute2(List<Type2> argumentTypes, List<Type2> parameterTypes); | 7579 VoidType substitute2(List<Type2> argumentTypes, List<Type2> parameterTypes); |
| 7521 } | 7580 } |
| OLD | NEW |