ASTTypeFunction<F extends Function> class

ASTType for a Function.

Inheritance

Constructors

ASTTypeFunction([ASTType? returnType, List<ASTType>? parameters])

Properties

annotations List<ASTAnnotation>?
finalinherited
children Iterable<ASTNode>
The children nodes of this node.
no setteroverride
descendantChildren List<ASTNode>
Return the children and it's descendant children (unmodifiable).
no setterinherited
generics List<ASTType>?
finalinherited
hasGenerics bool
Returns true if this type has generics.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
hasSuperType bool
Returns true if this type has a super type.
no setterinherited
name String
finalinherited
parentNode ASTNode?
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
superType ASTType?
finalinherited

Methods

acceptsType(ASTType type) bool
Any function type is accepted as another function type. Function values carry their own declaration and are checked at call time, so signature generics (return/parameter types) aren't enforced structurally here — this lets an untyped Function argument bind to a typed int Function(int) parameter and vice versa.
override
associateToType(ASTTypedNode node) → void
inherited
cacheDescendantChildren() → void
Mark that this node can cache its descendantChildren.
inherited
callCasted<R>(R call<T>()) → R
inherited
canCastToType(ASTType type) bool
Return true if this can be cast to type;
inherited
commonType(ASTType? other) ASTType?
inherited
getClass() ASTClass<F>
inherited
getNodeIdentifier(String name, {ASTNode? requester}) ASTNode?
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
resolveNode(ASTNode? parentNode) → void
inherited
resolveRuntimeType(VMContext context, ASTNode? node) FutureOr<ASTType>
inherited
resolveType(VMContext? context) FutureOr<ASTType>
inherited
setClass(ASTClass<F> clazz) → void
inherited
toASTValue(Object? value) ASTValueFunction<F>?
override
toDefaultValue(VMContext context) FutureOr<ASTValue<F>?>
inherited
toString() String
A string representation of this object.
inherited
toValue(VMContext context, Object? v) FutureOr<ASTValueFunction<F>?>
override

Operators

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