Files
sdk/pkg/analyzer_testing/api.txt
T
Paul Berry dca8eb4ae6 [API summary] Consider publicly exported names to be part of public API.
Changes the logic for deciding whether to output details about a top
level element. Previously, details would be output if the library
containing the element's declaration was in `lib` but not
`lib/src`. This led to a bug: if a top level element was declared in
`lib/src` but exported by an `export` directive in `lib`, no details
would be output, and the API summary would just show `(non-public)`
after the exported name.

This bug was mostly benign because we were working around it with an
analyzer-specific hack: when analyzing the `analyzer` package, top
level elements with an annotation of type `AnalyzerPublicApi` would
have their details output regardless of where they were declared. But
it wasn't completely benign: the tool was failing to output details of
`DartDocumentLinkVisitor` and `DocumentLink` (from
`package:analyzer_plugin`), as well as `PackageBuilder` (from
`package:analyzer_testing`).

The new logic is: details are output if the element appears in the
export namespace of any library in `lib` but not `lib/src`. I've
re-run the API summary tool so the `api.txt` files in
`package:analyzer_plugin` and `package:analyzer_testing` now include
the details they were missing.

The analyzer-specific hack is left in place, though, because there are
some analyzer classes that aren't exported, but still considered part
of the analyzer public API. In a follow-up CL, I will make the API
summary tool extensible so that this analyzer-specific logic can be
injected by the analyzer when generating its `api.txt` file, and it
won't pollute the incipient `api_summary` tool.

Change-Id: I6a6a69641d656caa4f8e6361557c13fa7485e422
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/482440
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2026-02-20 11:21:15 -08:00

107 lines
5.6 KiB
Plaintext

package:analyzer_testing/analysis_rule/analysis_rule.dart:
contextMessage (function: ExpectedContextMessage Function(File, int, int, {deprecated String? text, List<Pattern> textContains}))
error (function: ExpectedDiagnostic Function(DiagnosticCode, int, int, {List<ExpectedContextMessage>? contextMessages, Pattern? correctionContains, deprecated Pattern? messageContains, List<Pattern> messageContainsAll}))
AnalysisRuleTest (class extends PubPackageResolutionTest, abstract):
new (constructor: AnalysisRuleTest Function())
analysisRule (getter: String, deprecated)
rule (getter: AbstractAnalysisRule)
rule= (setter: AbstractAnalysisRule)
assertNoPubspecDiagnostics (method: Future<void> Function(String))
assertPubspecDiagnostics (method: Future<void> Function(String, List<ExpectedDiagnostic>))
correctionMessage (method: String Function(List<Diagnostic>))
lint (method: ExpectedDiagnostic Function(int, int, {List<ExpectedContextMessage>? contextMessages, Pattern? correctionContains, deprecated Pattern? messageContains, List<Pattern> messageContainsAll, String? name}))
setUp (method: void Function())
unexpectedMessage (method: String Function(List<Diagnostic>))
PackageBuilder (class extends Object):
addFile (method: void Function(String, String))
package:analyzer_testing/experiments/experiments.dart:
experimentsForTests (static getter: List<String>)
experimentsForTests= (static setter: List<String>)
package:analyzer_testing/mock_packages/mock_packages.dart:
BlazeMockPackages (class extends Object):
instance (static getter: BlazeMockPackages)
addFlutter (method: void Function(ResourceProvider))
addMeta (method: void Function(ResourceProvider))
MockPackagesMixin (mixin on Object):
packagesRootPath (getter: String)
pathContext (getter: Context)
resourceProvider (getter: ResourceProvider)
addFfi (method: Folder Function())
addFixnum (method: Folder Function())
addFlutter (method: Folder Function())
addMeta (method: Folder Function())
addSkyEngine (method: Folder Function({required String sdkPath}))
addTestReflectiveLoader (method: Folder Function())
addVectorMath (method: Folder Function())
package:analyzer_testing/package_root.dart:
packageRoot (static getter: String)
package:analyzer_testing/resource_provider_mixin.dart:
ResourceProviderMixin (mixin on Object):
pathContext (getter: Context)
resourceProvider (getter: ResourceProvider)
convertPath (method: String Function(String))
deleteFile (method: void Function(String))
deleteFolder (method: void Function(String))
fromUri (method: String Function(Uri))
getFile (method: File Function(String))
getFolder (method: Folder Function(String))
join (method: String Function(String, [String?, String?, String?, String?, String?, String?, String?]))
modifyFile2 (method: void Function(File, String))
newAnalysisOptionsYamlFile (method: File Function(String, String))
newBazelBuildFile (method: File Function(String, String))
newBuildGnFile (method: File Function(String, String))
newFile (method: File Function(String, String))
newFolder (method: Folder Function(String))
newLink (method: Link Function(String, String))
newPackageConfigJsonFile (method: File Function(String, String))
newPackageConfigJsonFileFromBuilder (method: File Function(String, PackageConfigFileBuilder))
newPubspecYamlFile (method: File Function(String, String))
newSinglePackageConfigJsonFile (method: void Function({required String name, required String packagePath}))
toUri (method: Uri Function(String))
toUriStr (method: String Function(String))
package:analyzer_testing/src/analysis_rule/pub_package_resolution.dart:
ExpectedContextMessage (non-public)
ExpectedDiagnostic (non-public)
PubPackageResolutionTest (non-public)
package:analyzer_testing/utilities/extensions/diagnostic_code.dart:
DiagnosticCodeExtension (extension on DiagnosticCode):
constantName (getter: String)
package:analyzer_testing/utilities/extensions/resource_provider.dart:
ResourceProviderExtension (extension on ResourceProvider):
convertPath (method: String Function(String))
package:analyzer_testing/utilities/extensions/string.dart:
StringExtension (extension on String):
isCamelCase (getter: bool)
isPascalCase (getter: bool)
toCamelCase (method: String Function())
toPascalCase (method: String Function())
toSnakeCase (method: String Function())
package:analyzer_testing/utilities/utilities.dart:
analysisOptionsContent (function: String Function({Map<String, Object?> errors, List<String> experiments, List<String> includes, List<String> legacyPlugins, bool propagateLinterExceptions, List<String> rules, bool strictCasts, bool strictInference, bool strictRawTypes, List<String> unignorableNames}))
pubspecYamlContent (function: String Function({List<String> dependencies, String? name, String? sdkVersion}))
dart:async:
Future (referenced)
dart:core:
List (referenced)
Map (referenced)
Object (referenced)
Pattern (referenced)
String (referenced)
Uri (referenced)
bool (referenced)
int (referenced)
package:_fe_analyzer_shared/src/base/errors.dart:
Diagnostic (referenced)
DiagnosticCode (referenced)
package:analyzer/file_system/file_system.dart:
File (referenced)
Folder (referenced)
Link (referenced)
ResourceProvider (referenced)
package:analyzer/src/analysis_rule/analysis_rule.dart:
AbstractAnalysisRule (referenced)
package:analyzer/utilities/package_config_file_builder.dart:
PackageConfigFileBuilder (referenced)
package:path/src/context.dart:
Context (referenced)