AnalysisDomain class
The analysis domain contains API's related to the analysis of files.
Constructors
- AnalysisDomain(AnalysisServer server)
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- name → String
-
finalinherited
-
onAnalyzedFiles
→ Stream<
AnalysisAnalyzedFiles> -
Reports the paths of the files that are being analyzed.
no setter
-
onClosingLabels
→ Stream<
AnalysisClosingLabels> -
Reports closing labels relevant to a given file.
no setter
-
onErrors
→ Stream<
AnalysisErrors> -
Reports the errors associated with a given file. The set of errors
included in the notification is always a complete list that supersedes any
previously reported errors.
no setter
-
onFlushResults
→ Stream<
AnalysisFlushResults> -
Reports that any analysis results that were previously associated with the
given files should be considered to be invalid because those files are no
longer being analyzed, either because the analysis root that contained it
is no longer being analyzed or because the file no longer exists.
no setter
-
onFolding
→ Stream<
AnalysisFolding> -
Reports the folding regions associated with a given file. Folding regions
can be nested, but will not be overlapping. Nesting occurs when a foldable
element, such as a method, is nested inside another foldable element such
as a class.
no setter
-
onHighlights
→ Stream<
AnalysisHighlights> -
Reports the highlight regions associated with a given file.
no setter
-
onImplemented
→ Stream<
AnalysisImplemented> -
Reports the classes that are implemented or extended and class members
that are implemented or overridden in a file.
no setter
-
onInvalidate
→ Stream<
AnalysisInvalidate> -
Reports that the navigation information associated with a region of a
single file has become invalid and should be re-requested.
no setter
-
Reports the navigation targets associated with a given file.
no setter
-
onOccurrences
→ Stream<
AnalysisOccurrences> -
Reports the occurrences of references to elements within a single file.
no setter
-
onOutline
→ Stream<
AnalysisOutline> -
Reports the outline associated with a single file.
no setter
-
onOverrides
→ Stream<
AnalysisOverrides> -
Reports the overriding members in a file.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- server → AnalysisServer
-
finalinherited
Methods
-
getErrors(
String? file) → Future< ErrorsResult> -
Return the errors associated with the given file. If the errors for the
given file have not yet been computed, or the most recently computed
errors for the given file are out of date, then the response for this
request will be delayed until they have been computed. If some or all of
the errors for the file cannot be computed, then the subset of the errors
that can be computed will be returned and the response will contain an
error to indicate why the errors could not be computed. If the content of
the file changes after this request was received but before a response
could be sent, then an error of type
CONTENT_MODIFIED
will be generated. -
getHover(
String? file, int? offset) → Future< HoverResult> - Return the hover information associate with the given location. If some or all of the hover information is not available at the time this request is processed the information will be omitted from the response.
-
getImportedElements(
String? file, int? offset, int? length) → Future< ImportedElementsResult> - Return a description of all of the elements referenced in a given region of a given file that come from imported libraries.
-
getLibraryDependencies(
) → Future< LibraryDependenciesResult> - Return library dependency information for use in client-side indexing and package URI resolution.
-
Return the navigation information associated with the given region of the
given file. If the navigation information for the given file has not yet
been computed, or the most recently computed navigation information for
the given file is out of date, then the response for this request will be
delayed until it has been computed. If the content of the file changes
after this request was received but before a response could be sent, then
an error of type
CONTENT_MODIFIED
will be generated. -
getReachableSources(
String? file) → Future< ReachableSourcesResult> -
getSignature(
String? file, int? offset) → Future< SignatureResult> -
Return the signature information associated with the given location in the
given file. If the signature information for the given file has not yet
been computed, or the most recently computed signature information for the
given file is out of date, then the response for this request will be
delayed until it has been computed. If a request is made for a file which
does not exist, or which is not currently subject to analysis (e.g.
because it is not associated with any analysis root specified to
analysis.setAnalysisRoots), an error of type
GET_SIGNATURE_INVALID_FILE
will be generated. If the location given is not inside the argument list for a function (including method and constructor) invocation, then an error of typeGET_SIGNATURE_INVALID_OFFSET
will be generated. If the location is inside an argument list but the function is not defined or cannot be determined (such as a method invocation where the target has type 'dynamic') then an error of typeGET_SIGNATURE_UNKNOWN_FUNCTION
will be generated. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
reanalyze(
) → Future - Force re-reading of all potentially changed files, re-resolving of all referenced URIs, and corresponding re-analysis of everything affected in the current analysis roots.
-
setAnalysisRoots(
List< String> ? included, List<String> ? excluded, {Map<String, String> ? packageRoots}) → Future - Sets the root paths used to determine which files to analyze. The set of files to be analyzed are all of the files in one of the root paths that are not either explicitly or implicitly excluded. A file is explicitly excluded if it is in one of the excluded paths. A file is implicitly excluded if it is in a subdirectory of one of the root paths where the name of the subdirectory starts with a period (that is, a hidden directory).
-
setGeneralSubscriptions(
List< String> subscriptions) → Future - Subscribe for general services (that is, services that are not specific to individual files). All previous subscriptions are replaced by the given set of services.
-
setPriorityFiles(
List< String> files) → Future - Set the priority files to the files in the given list. A priority file is a file that is given priority when scheduling which analysis work to do first. The list typically contains those files that are visible to the user and those for which analysis results will have the biggest impact on the user experience. The order of the files within the list is significant: the first file will be given higher priority than the second, the second higher priority than the third, and so on.
-
setSubscriptions(
Map< String, List< subscriptions) → FutureString> > - Subscribe for services that are specific to individual files. All previous subscriptions are replaced by the current set of subscriptions. If a given service is not included as a key in the map then no files will be subscribed to the service, exactly as if the service had been included in the map with an explicit empty list of files.
-
toString(
) → String -
A string representation of this object.
inherited
-
updateContent(
Map< String, ContentOverlayType> files) → Future - Update the content of one or more files. Files that were previously updated but not included in this update remain unchanged. This effectively represents an overlay of the filesystem. The files whose content is overridden are therefore seen by server as being files with the given content, even if the files do not exist on the filesystem or if the file path represents the path to a directory on the filesystem.
-
updateOptions(
AnalysisOptions options) → Future
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited