ElementKind class
The kind of elements in the element model.
Clients may not extend, implement or mix-in this class.
- Implemented types
Constructors
- ElementKind(String name, int ordinal, String displayName)
-
Initialize a newly created element kind to have the given
displayName
.const
Properties
- displayName → String
-
The name displayed in the UI for this kind of element.
final
- hashCode → int
-
The hash code for this object. [...]
read-only, override
- name → String
-
The name of this element kind.
final
- ordinal → int
-
The ordinal value of the element kind.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
read-only, inherited
Methods
-
compareTo(
ElementKind other) → int -
Compares this object to another Comparable [...]
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a non-existent method or property is accessed. [...]
inherited
-
toString(
) → String -
Returns a string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator. [...]
inherited
Static Methods
-
of(
Element element) → ElementKind -
Return the kind of the given
element
, or ERROR if the element isnull
. This is a utility method that can reduce the need for null checks in other places.
Constants
- CLASS → const ElementKind
-
const ElementKind('CLASS', 0, "class")
- COMPILATION_UNIT → const ElementKind
-
const ElementKind('COMPILATION_UNIT', 1, "compilation unit")
- CONSTRUCTOR → const ElementKind
-
const ElementKind('CONSTRUCTOR', 2, "constructor")
- DYNAMIC → const ElementKind
-
const ElementKind('DYNAMIC', 3, "<dynamic>")
- ENUM → const ElementKind
-
const ElementKind('ENUM', 4, "enum")
- ERROR → const ElementKind
-
const ElementKind('ERROR', 5, "<error>")
- EXPORT → const ElementKind
-
const ElementKind('EXPORT', 6, "export directive")
- EXTENSION → const ElementKind
-
const ElementKind('EXTENSION', 7, "extension")
- FIELD → const ElementKind
-
const ElementKind('FIELD', 8, "field")
- FUNCTION → const ElementKind
-
const ElementKind('FUNCTION', 9, "function")
- FUNCTION_TYPE_ALIAS → const ElementKind
-
const ElementKind('FUNCTION_TYPE_ALIAS', 23, "function type alias")
- GENERIC_FUNCTION_TYPE → const ElementKind
-
const ElementKind('GENERIC_FUNCTION_TYPE', 10, 'generic function type')
- GETTER → const ElementKind
-
const ElementKind('GETTER', 11, "getter")
- IMPORT → const ElementKind
-
const ElementKind('IMPORT', 12, "import directive")
- LABEL → const ElementKind
-
const ElementKind('LABEL', 13, "label")
- LIBRARY → const ElementKind
-
const ElementKind('LIBRARY', 14, "library")
- LOCAL_VARIABLE → const ElementKind
-
const ElementKind('LOCAL_VARIABLE', 15, "local variable")
- METHOD → const ElementKind
-
const ElementKind('METHOD', 16, "method")
- NAME → const ElementKind
-
const ElementKind('NAME', 17, "<name>")
- NEVER → const ElementKind
-
const ElementKind('NEVER', 18, "<never>")
- PARAMETER → const ElementKind
-
const ElementKind('PARAMETER', 19, "parameter")
- PREFIX → const ElementKind
-
const ElementKind('PREFIX', 20, "import prefix")
- SETTER → const ElementKind
-
const ElementKind('SETTER', 21, "setter")
- TOP_LEVEL_VARIABLE → const ElementKind
-
const ElementKind('TOP_LEVEL_VARIABLE', 22, "top level variable")
- TYPE_PARAMETER → const ElementKind
-
const ElementKind('TYPE_PARAMETER', 24, "type parameter")
- UNIVERSE → const ElementKind
-
const ElementKind('UNIVERSE', 25, "<universe>")
-
values
→ const List<
ElementKind> -
const [CLASS, COMPILATION_UNIT, CONSTRUCTOR, DYNAMIC, ENUM, ERROR, EXPORT, FIELD, FUNCTION, GENERIC_FUNCTION_TYPE, GETTER, IMPORT, LABEL, LIBRARY, LOCAL_VARIABLE, METHOD, NAME, NEVER, PARAMETER, PREFI…