Uses of Class
org.ek9lang.compiler.symbols.MethodSymbol
Package
Description
Common parts of processing that can be reused across various phases.
E - Initial Symbol definition by traversing the 'ANTLR' - 'AST'.
F - Resolution of Explicitly Defined Type Symbols at this point phase1 processing should have defined
most of the explicitly defined symbols, so they should be resolvable.
G - Full Symbol Resolution can now take place.
Used primarily to hold structures that are related to searching for symbols.
Contains critical general components used in the
Ek9Compiler
listeners.
This is the main source of EK9 Symbols used within the compiler.
-
Uses of MethodSymbol in org.ek9lang.compiler.common
Modifier and TypeMethodDescriptionMethodAndAggregateData.methodSymbol()
Returns the value of themethodSymbol
record component.Modifier and TypeMethodDescriptionScopeStack.traverseBackUpStackToEnclosingMethod()
Navigate back up the scope stack to find the first enclosing method (there may not be one).Modifier and TypeMethodDescriptionvoid
AppropriateBodyOrError.accept
(MethodSymbol methodSymbol, EK9Parser.OperationDetailsContext ctx) void
ContextSupportsAbstractMethodOrError.accept
(MethodSymbol methodSymbol, org.antlr.v4.runtime.ParserRuleContext ctx) void
OverrideOrAbstractOrError.accept
(MethodSymbol methodSymbol) void
ProcessTraitMethodOrError.accept
(MethodSymbol method, EK9Parser.OperationDetailsContext ctx) void
TraitMethodAcceptableOrError.accept
(MethodSymbol method, EK9Parser.OperationDetailsContext ctx) ModifierConstructorDescriptionMethodAndAggregateData
(MethodSymbol methodSymbol, IAggregateSymbol aggregateSymbol) Creates an instance of aMethodAndAggregateData
record class. -
Uses of MethodSymbol in org.ek9lang.compiler.phase1
Modifier and TypeMethodDescriptionvoid
GenericConstructorOrError.accept
(IToken token, MethodSymbol methodSymbol) void
MethodNotOperatorOrError.accept
(MethodSymbol methodSymbol, EK9Parser.MethodDeclarationContext methodDeclarationContext) void
NoMethodReturnOrError.accept
(MethodSymbol methodSymbol, EK9Parser.MethodDeclarationContext ctx) void
NonExtendableMethodOrError.accept
(MethodSymbol methodSymbol, EK9Parser.MethodDeclarationContext methodDeclarationContext) void
NotDispatcherMethodOrError.accept
(MethodSymbol method, EK9Parser.MethodDeclarationContext ctx) void
ProcessCommonMethodsOrError.accept
(MethodSymbol method, EK9Parser.MethodDeclarationContext ctx) void
ProgramArgumentsOrError.accept
(IToken token, MethodSymbol methodSymbol) void
ProgramReturnOrError.accept
(IToken token, MethodSymbol methodSymbol) void
ValidMethodOrError.accept
(MethodSymbol method, EK9Parser.MethodDeclarationContext ctx) -
Uses of MethodSymbol in org.ek9lang.compiler.phase2
Modifier and TypeMethodDescriptionvoid
ValidOperatorOrError.accept
(MethodSymbol methodSymbol, EK9Parser.OperatorDeclarationContext ctx) -
Uses of MethodSymbol in org.ek9lang.compiler.phase3
Modifier and TypeMethodDescriptionResolveMethodOrError.apply
(IToken errorLocation, MethodSearchInScope searchOnAggregate) ThisOrSuperCallOrError.apply
(EK9Parser.CallContext ctx) Modifier and TypeMethodDescriptionvoid
TraverseAbstractMethods.accept
(IAggregateSymbol aggregateSymbol, Consumer<MethodSymbol> actionToTake) -
Uses of MethodSymbol in org.ek9lang.compiler.search
Modifier and TypeMethodDescriptionPossibleMatchingMethods.apply
(MethodSearchInScope searchOnAggregate) MethodSymbolSearchResult.getSingleBestMatchSymbol()
If there is a single best match for the search; then return it.ModifierConstructorDescriptionMethodSymbolSearch
(String newName, MethodSymbol methodSymbol) Create a method search given a method symbol, but used a new method name.ยง But this does not set the expected type.MethodSymbolSearch
(MethodSymbol methodSymbol) Create a method search given a method symbol.WeightedMethodSymbolMatch
(MethodSymbol methodSymbol, double matchWeight) -
Uses of MethodSymbol in org.ek9lang.compiler.support
Modifier and TypeMethodDescriptionAggregateFactory.addComparatorOperator
(IAggregateSymbol aggregateSymbol, String comparatorType, Optional<ISymbol> returnType) Adds a form of a comparison operator.AggregateFactory.addConstructor
(AggregateSymbol t, Optional<ISymbol> s) Add another constructor to type t, but passing in an s as the value in the construction.AggregateFactory.addConstructor
(AggregateSymbol t, ISymbol s) Add a constructor to the type aggregate with a particular parameter.AggregateFactory.addConstructor
(IAggregateSymbol t) Create a new constructor for the aggregate with no params.AggregateFactory.addPublicMethod
(AggregateSymbol aggregate, String methodName, List<ISymbol> methodParameters, Optional<ISymbol> returnType) Just add a method to an aggregate with the name and parameters and return type.AggregateFactory.addPurePublicSimpleOperator
(IAggregateSymbol aggregateSymbol, String methodName, Optional<ISymbol> returnType) Adds a simple operator, that is 'pure' (no side effects) and accepts no parameters, but just returns a value.CheckAndPopulateOperator.apply
(EK9Parser.OperatorDeclarationContext ctx, IAggregateSymbol aggregate) AggregateFactory.cloneMethodWithNewType
(MethodSymbol method, IAggregateSymbol to) AggregateFactory.createMutatorOperator
(IAggregateSymbol aggregateSymbol, String operatorType) Create an operator of the name supplied.AggregateFactory.createOperator
(IAggregateSymbol aggregateSymbol, String operatorType, boolean isPure) Create an operator of the name supplied.AggregateFactory.createPureAcceptSameTypeOperatorAndReturnType
(IAggregateSymbol aggregateSymbol, String comparatorType, Optional<ISymbol> returnType) Creates a pure method with an argument the same as the main type.AggregateFactory.createPureArgumentOperatorAndReturnType
(IAggregateSymbol aggregateSymbol, IAggregateSymbol arg0, String comparatorType, Optional<ISymbol> returnType) Creates a pure method with an argument of a different type as the main type.AggregateFactory.createPurePublicReturnSameTypeMethod
(IAggregateSymbol aggregateSymbol, String methodName) AggregateFactory.createPurePublicSimpleOperator
(IAggregateSymbol aggregateSymbol, String methodName, Optional<ISymbol> returnType) Just creates a public operator with the name specified.AggregateFactory.createToJsonSimpleOperator
(IAggregateSymbol aggregateSymbol) Create operator for json.(package private) MethodSymbol
OperatorFactory.getDefaultOperator
(IAggregateSymbol aggregate, String operator) SymbolFactory.newMethod
(EK9Parser.MethodDeclarationContext ctx, String methodName, IScopedSymbol scopedSymbol) Create a new method with a specific name.SymbolFactory.newMethod
(EK9Parser.MethodDeclarationContext ctx, IScopedSymbol scopedSymbol) Create a new method that represents an EK9 class/component method.SymbolFactory.newOperator
(EK9Parser.OperatorDeclarationContext ctx, IAggregateSymbol aggregate) Create a new aggregate that represents an EK9 operator, uses a method for this.SymbolFactory.newTextBody
(EK9Parser.TextBodyDeclarationContext ctx, IScope scope) Create a new aggregate that represents an EK9 text body - this is represented by a method.Modifier and TypeMethodDescriptionAggregateFactory.getAllPossibleDefaultOperators
(IAggregateSymbol aggregate) Provides all the possible default operators.(package private) List
<MethodSymbol> OperatorFactory.getAllPossibleDefaultOperators
(IAggregateSymbol aggregate) (package private) List
<MethodSymbol> OperatorFactory.getAllPossibleSyntheticOperators
(IAggregateSymbol aggregate) AggregateFactory.getDefaultOperator
(IAggregateSymbol aggregate, String operator) If the operator provided can be defaulted then a Method symbol with the correct signature will be returned.Modifier and TypeMethodDescriptionAggregateFactory.cloneMethodWithNewType
(MethodSymbol method, IAggregateSymbol to) void
SymbolFactory.ensureTextBodyIsInSuper
(MethodSymbol textMethodSymbol) Ensures that any method in a specific text block is always added to the base text for that component.Modifier and TypeMethodDescriptionvoid
SymbolMatcher.addMatchesToResult
(MethodSymbolSearchResult result, SymbolSearch criteria, List<MethodSymbol> methodSymbols) Match the search criteria against one or more symbol methods. -
Uses of MethodSymbol in org.ek9lang.compiler.symbols
Modifier and TypeClassDescriptionclass
Just re-uses the bulk of method symbol for when we want to make a symbol that is a call to an actual method.class
Scope for callable methods (operations) that are part of a Service.class
Just re-uses the bulk of method symbol.Modifier and TypeMethodDescriptionprotected MethodSymbol
MethodSymbol.cloneIntoMethodSymbol
(MethodSymbol newCopy) MethodSymbol.copyMethodProperties
(MethodSymbol newCopy) Just copies the properties over.MethodSymbol.setConstructor
(boolean constructor) MethodSymbol.setOperator
(boolean operator) Modifier and TypeMethodDescriptionAggregateSymbol.getAllAbstractMethods()
Gets all abstract methods in this aggregate and any super classes.AggregateWithTraitsSymbol.getAllAbstractMethods()
Gets all abstract methods in this aggregate and any super classes.IAggregateSymbol.getAllAbstractMethods()
Get all methods marked as abstract in this or any supers.AggregateSymbol.getAllAbstractMethodsInThisScopeOnly()
IAggregateSymbol.getAllAbstractMethodsInThisScopeOnly()
Get all methods in this scope only that are abstract.AggregateSymbol.getAllMethodInThisScopeOnly()
IAggregateSymbol.getAllMethodInThisScopeOnly()
All methods abstract and non-abstract in this scope.AggregateSymbol.getAllMethods()
AggregateWithTraitsSymbol.getAllMethods()
IAggregateSymbol.getAllMethods()
Get all methods on this and any supers or traits.AggregateSymbol.getAllNonAbstractMethods()
AggregateWithTraitsSymbol.getAllNonAbstractMethods()
IAggregateSymbol.getAllNonAbstractMethods()
Get all methods not marked as abstract in this or any supers.AggregateSymbol.getAllNonAbstractMethodsInThisScopeOnly()
IAggregateSymbol.getAllNonAbstractMethodsInThisScopeOnly()
Get all methods in this scope only that are not abstract.AggregateSymbol.getAllOperators()
IAggregateSymbol.getAllOperators()
Get all operators on this and any supers or traits.AggregateSymbol.getConstructors()
IAggregateSymbol.getConstructors()
A list of all the defined constructors.Modifier and TypeMethodDescriptionprotected MethodSymbol
MethodSymbol.cloneIntoMethodSymbol
(MethodSymbol newCopy) MethodSymbol.copyMethodProperties
(MethodSymbol newCopy) Just copies the properties over.boolean
MethodSymbol.isExactSignatureMatchTo
(MethodSymbol toMethod) This method just checks that the signature has exactly the same types as parameters.boolean
MethodSymbol.isSignatureMatchTo
(MethodSymbol toMethod) Does the signature of this method match that of the method passed in.