PatternVariableElement2 class abstract

A pattern variable.

Clients may not extend, implement or mix-in this class.

Implemented types
Implementers

Constructors

PatternVariableElement2()

Properties

baseElement LocalVariableElement2
The non-Member version of this element.
no setterinherited
children2 List<Element2>
The children of this element.
no setterinherited
displayName String
The display name of this element, or an empty string if the element does not have a name.
no setterinherited
enclosingElement2 Element2?
The element that either physically or logically encloses this element.
no setterinherited
enclosingFunction ExecutableFragment
The function in which the variable is defined.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
hasImplicitType bool
Whether the variable element did not have an explicit type specified for it.
no setterinherited
hasInitializer bool
Whether the variable has an initializer at declaration.
no setterinherited
id int
The unique integer identifier of this element.
no setterinherited
isConst bool
Whether the variable was declared with the 'const' modifier.
no setterinherited
isFinal bool
Whether the variable was declared with the 'final' modifier.
no setterinherited
isLate bool
Whether the variable uses late evaluation semantics.
no setterinherited
isPrivate bool
Whether this element is private.
no setterinherited
isPublic bool
Whether this element is public.
no setterinherited
isStatic bool
Whether the element is a static variable, as per section 8 of the Dart Language Specification:
no setterinherited
isSynthetic bool
Whether this element is synthetic.
no setterinherited
join2 JoinPatternVariableElement2?
The variable in which this variable joins with other pattern variables with the same name, in a logical-or pattern, or shared case scope.
no setter
kind ElementKind
The kind of this element.
no setterinherited
library2 LibraryElement2?
Library that contains this element.
no setterinherited
location ElementLocation?
The location of this element in the element model.
no setterinherited
name String
The name of this element.
no setterinherited
nameOffset int
The offset of the name in this element.
no setterinherited
nonSynthetic2 Element2
The non-synthetic element that caused this element to be created.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
session AnalysisSession?
The analysis session in which this element is defined.
no setterinherited
type DartType
The declared type of this variable.
no setterinherited

Methods

computeConstantValue() DartObject?
Returns a representation of the value of this variable.
inherited
displayString2({bool multiline = false, bool preferTypeAlias = false}) String
The presentation of this element as it should appear when presented to users.
inherited
isAccessibleIn2(LibraryElement2 library) bool
Whether the element, assuming that it is within scope, is accessible to code in the given library.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
thisOrAncestorMatching2<E extends Element2>(bool predicate(Element2)) → E?
Returns either this element or the most immediate ancestor of this element for which the predicate returns true.
inherited
thisOrAncestorOfType2<E extends Element2>() → E?
Returns either this element or the most immediate ancestor of this element that has the given type.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited