Interface IAggregateSymbol
- All Superinterfaces:
ICanBeGeneric, IScope, IScopedSymbol, ISymbol, ISymbolNature, ITokenReference, Serializable
- All Known Implementing Classes:
AggregateSymbol, AggregateWithTraitsSymbol, AnyTypeSymbol
Interface for an aggregate, typically a class or something like that.
-
Nested Class Summary
Nested classes/interfaces inherited from interface IScope
IScope.ScopeType -
Method Summary
Modifier and TypeMethodDescriptiondefault voidused to add back pointers to subclasses.Clone the symbol and re-parent if this symbol like a method should have a parent.default List<MethodSymbol> Get all methods marked as abstract in this or any supers.default List<MethodSymbol> Get all methods in this scope only that are abstract.default List<MethodSymbol> Gets all methods that are effective, by this I mean if supers (classes or traits) have the same method name but, it has been overridden then we would only retain the 'overridden' one as that has taken effect.default List<AggregateWithTraitsSymbol> default List<MethodSymbol> All methods abstract and non-abstract in this scope.default List<MethodSymbol> Get all methods on this and any supers or traits.default List<MethodSymbol> Get all methods not marked as abstract in this or any supers.default List<MethodSymbol> Get all methods in this scope only that are not abstract.default List<MethodSymbol> Get all operators on this and any supers or traits.default List<AggregateWithTraitsSymbol> A list of all the defined constructors.getName()Name of this aggregate.Just access to the properties in this aggregate - no supers.What sort of scope is this aggregate.default List<IAggregateSymbol> To get a full hierarchy you will need to get these subclasses and then get the subclasses of those.default Optional<IAggregateSymbol> default List<IAggregateSymbol> default booleandefault booleanisImplementingInSomeWay(IAggregateSymbol aggregate) Only really used by aggregates that can have one or more traits.booleanisInAggregateHierarchy(IAggregateSymbol theAggregateToCheck) default booleanIs this aggregate a dispatcher or just a normal class component whatever.default MethodSymbolSearchResultresolveMatchingMethods(MethodSymbolSearch search, MethodSymbolSearchResult result) Resolve for matching methods and add matches to result.resolveMember(SymbolSearch search) Just try and resolve a member in this or super scopes.default voidsetMarkedAsDispatcher(boolean markedAsDispatcher) default voidsetSuperAggregate(Optional<IAggregateSymbol> superAggregate) default voidsetSuperAggregate(IAggregateSymbol superAggregateSymbol) Methods inherited from interface ICanBeGeneric
addGenericSymbolReference, addTypeParameterOrArgument, getAnyConceptualTypeParameters, getGenericSymbolReferences, getGenericType, getTypeParameterOrArguments, isOpenForExtensionMethods inherited from interface IScope
define, findNearestDynamicBlockScopeInEnclosingScopes, findNearestNonBlockScopeInEnclosingScopes, getAllSymbolsMatchingName, getEnclosingScope, getEncounteredExceptionToken, getFriendlyScopeName, getScopeName, getSymbolsForThisScope, isMarkedPure, isScopeAMatchForEnclosingScope, isTerminatedNormally, resolve, resolveInThisScopeOnly, resolveMatchingMethodsInThisScopeOnly, setEncounteredExceptionTokenMethods inherited from interface ISymbol
clearInitialisedBy, getAssignableCostTo, getAssignableCostTo, getFriendlyName, getFullyQualifiedName, getInitialisedBy, getParsedModule, getSourceToken, getSquirrelledData, getType, getUnCoercedAssignableCostTo, isAssignableTo, isAssignableTo, isDeclaredAsConstant, isDevSource, isExactSameType, isExtensionOfInjectable, isFromLiteral, isIncomingParameter, isInitialised, isInjectable, isInjectionExpected, isLibSource, isLoopVariable, isMarkedAbstract, isMarkedPure, isMutable, isNullAllowed, isPrivate, isPromotionSupported, isPropertyField, isProtected, isPublic, isReferenced, isReturningParameter, putSquirrelledData, setInitialisedBy, setInjectionExpected, setName, setNotMutable, setNullAllowed, setParsedModule, setReferenced, setType, setTypeMethods inherited from interface ISymbolNature
getCategory, getGenus, isApplication, isConceptualTypeParameter, isConstant, isControl, isEk9Core, isFunction, isGenericInNature, isMethod, isParameterisedType, isPrimitiveType, isTemplateFunction, isTemplateType, isType, isVariable, setGenusMethods inherited from interface ITokenReference
setSourceToken
-
Method Details
-
getScopeType
IScope.ScopeType getScopeType()What sort of scope is this aggregate.- Specified by:
getScopeTypein interfaceIScope
-
isMarkedAsDispatcher
default boolean isMarkedAsDispatcher()Is this aggregate a dispatcher or just a normal class component whatever.- Returns:
- true if marked as a dispatcher.
-
setMarkedAsDispatcher
default void setMarkedAsDispatcher(boolean markedAsDispatcher) -
getPipeSinkType
-
getSubAggregateSymbols
To get a full hierarchy you will need to get these subclasses and then get the subclasses of those.- Returns:
- a list of all the subclasses of this class
-
addSubAggregateSymbol
used to add back pointers to subclasses.- Parameters:
sub- The subclass to point back to.
-
getAllEffectiveMethods
Gets all methods that are effective, by this I mean if supers (classes or traits) have the same method name but, it has been overridden then we would only retain the 'overridden' one as that has taken effect. In the case of a trait that has multiple traits where the same method has been overridden in the trait only one method is now in effect. However, if there are multiple traits (or a super has the same method name) we would end up with 'duplicate' methods of the same name in this list 'CheckConflictingMethods' will need to detect this.- Returns:
- A List of methods that are in effect.
-
getAllMethods
Get all methods on this and any supers or traits.- Returns:
- the list
-
getAllOperators
Get all operators on this and any supers or traits.- Returns:
- the list
-
getAllAbstractMethods
Get all methods marked as abstract in this or any supers.- Returns:
- The list.
-
getAllNonAbstractMethods
Get all methods not marked as abstract in this or any supers.- Returns:
- The list.
-
getConstructors
List<MethodSymbol> getConstructors()A list of all the defined constructors.- Returns:
- The list of constructors
-
getAllMethodInThisScopeOnly
All methods abstract and non-abstract in this scope. -
getAllNonAbstractMethodsInThisScopeOnly
Get all methods in this scope only that are not abstract.- Returns:
- The list
-
getAllAbstractMethodsInThisScopeOnly
Get all methods in this scope only that are abstract.- Returns:
- The list
-
getProperties
-
getName
-
resolveMatchingMethods
default MethodSymbolSearchResult resolveMatchingMethods(MethodSymbolSearch search, MethodSymbolSearchResult result) Resolve for matching methods and add matches to result. Idea is to be able to gather all these up and ensure only one single good result i.e. matching methods does exist and one single method matches best. Else ambiguity or no match.- Specified by:
resolveMatchingMethodsin interfaceIScope
-
resolveMember
Just try and resolve a member in this or super scopes.- Specified by:
resolveMemberin interfaceIScope
-
getSuperAggregate
-
setSuperAggregate
-
setSuperAggregate
-
isInAggregateHierarchy
-
getTraits
-
getAllExtensionConstrainedTraits
-
getAllTraits
-
isExtensionConstrained
default boolean isExtensionConstrained() -
isImplementingInSomeWay
Only really used by aggregates that can have one or more traits. But also super classes or super traits. So can either be implementing directly, super, super - super or traits and supe traits. -
getAggregateDescription
String getAggregateDescription() -
clone
Description copied from interface:ISymbolClone the symbol and re-parent if this symbol like a method should have a parent. Other symbols like VariableSymbols are un-parented
-