Method class

Implemented types
Annotations
  • @immutable

Constructors

Method([void updates(MethodBuilder b) ])
factory
Method.returnsVoid([void updates(MethodBuilder b) ])
factory

Properties

annotations BuiltList<Expression>
Annotations as metadata on the node.
read-only
body Code
Body of the method.
@nullable, read-only
closure Expression
This method as a closure.
read-only
docs BuiltList<String>
Dart docs.
read-only
external → bool
Whether the method should be prefixed with external.
read-only
lambda → bool
Whether this method is a simple lambda expression. [...]
@nullable, read-only
modifier MethodModifier
Whether this method is async, async*, or sync*.
@nullable, read-only
name → String
Name of the method or function. [...]
@nullable, read-only
optionalParameters BuiltList<Parameter>
Optional parameters.
read-only
requiredParameters BuiltList<Parameter>
Required parameters.
read-only
returns Reference
@nullable, read-only
static → bool
Whether this method should be prefixed with static. [...]
read-only
type MethodType
Whether this is a getter or setter.
@nullable, read-only
types BuiltList<Reference>
Generic type parameters.
read-only
hashCode → int
The hash code for this object.
read-only, inherited
runtimeType → Type
A representation of the runtime type of the object.
read-only, inherited

Methods

accept<R>(SpecVisitor<R> visitor, [ R context ]) → R
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
rebuild(dynamic updates(B builder)) Method
Rebuilds the instance. [...]
inherited
toBuilder() MethodBuilder
Converts the instance to a builder B. [...]
inherited
toString() → String
Returns a string representation of this object.
inherited

Operators

operator ==(dynamic other) → bool
The equality operator.
inherited