@@ -27,9 +27,6 @@ class AnnotatedElement {
27
27
28
28
const AnnotatedElement (this .annotation, this .element);
29
29
30
- @Deprecated ('use element instead' )
31
- Element2 get element2 => element;
32
-
33
30
Metadata ? get metadata2 {
34
31
if (element case final Annotatable annotatable) {
35
32
return annotatable.metadata2;
@@ -44,33 +41,15 @@ class LibraryReader {
44
41
45
42
LibraryReader (this .element);
46
43
47
- @Deprecated ('use the default constructor instead' )
48
- LibraryReader .v2 (this .element);
49
-
50
- @Deprecated ('use element instead' )
51
- LibraryElement2 get element2 => element;
52
-
53
44
/// All of the declarations in this library.
54
45
Iterable <Element2 > get allElements => [element, ...element.children2];
55
46
56
- /// All of the declarations in this library.
57
- @Deprecated ('use allElements instead' )
58
- Iterable <Element2 > get allElements2 => allElements;
59
-
60
47
/// All of the elements representing classes in this library.
61
48
Iterable <ClassElement2 > get classes => element.classes;
62
49
63
- /// All of the elements representing classes in this library.
64
- @Deprecated ('use classes instead' )
65
- Iterable <ClassElement2 > get classes2 => classes;
66
-
67
50
/// All of the elements representing enums in this library.
68
51
Iterable <EnumElement2 > get enums => element.enums;
69
52
70
- /// All of the elements representing enums in this library.
71
- @Deprecated ('use enums instead' )
72
- Iterable <EnumElement2 > get enums3 => enums;
73
-
74
53
/// All of the declarations in this library annotated with [checker] .
75
54
Iterable <AnnotatedElement > annotatedWith (
76
55
TypeChecker checker, {
@@ -137,13 +116,6 @@ class LibraryReader {
137
116
return type is ClassElement2 ? type : null ;
138
117
}
139
118
140
- /// Returns a top-level [ClassElement2] publicly visible in by [name] .
141
- ///
142
- /// Unlike `LibraryElement2.getClass` , this also correctly traverses
143
- /// identifiers that are accessible via one or more `export` directives.
144
- @Deprecated ('Use findType() instead' )
145
- ClassElement2 ? findType2 (String name) => findType (name);
146
-
147
119
/// Returns a [Uri] from the current library to the target [asset] .
148
120
///
149
121
/// This is a typed convenience function for using [pathToUrl] , and the same
@@ -157,13 +129,6 @@ class LibraryReader {
157
129
Uri pathToElement (Element2 element) =>
158
130
pathToUrl (element.firstFragment.libraryFragment! .source.uri);
159
131
160
- /// Returns a [Uri] from the current library to the target [element] .
161
- ///
162
- /// This is a typed convenience function for using [pathToUrl] , and the same
163
- /// API restrictions hold around supported schemes and relative paths.
164
- @Deprecated ('use pathToElement instead' )
165
- Uri pathToElement2 (Element2 element) => pathToElement (element);
166
-
167
132
/// Returns a [Uri] from the current library to the one provided.
168
133
///
169
134
/// If possible, a `package:` or `dart:` URL scheme will be used to reference
0 commit comments