Class DefaultRelatedExpression<N,T,B,MB extends B,TB extends B,S,QI,EV,PP,R extends DefaultRelatedExpression<N,T,B,MB,TB,S,QI,EV,PP,R>>
java.lang.Object
de.monochromata.anaphors.ast.relatedexp.DefaultRelatedExpression<N,T,B,MB,TB,S,QI,EV,PP,R>
- Type Parameters:
N- The node type in the ASTT- The type typeB- The binding typeMB- The method binding typeTB- The type binding typeS- The scope type (optional)QI- The type used to represent qualified identifiersEV- The type of the event contained in the condition that is evaluated to check when the perspectivations shall be applied.PP- The type used for positions that carry perspectivationsR- The sub-type of related expression to use
- All Implemented Interfaces:
RelatedExpression<N,T,B,TB,S,QI,R>
@Deprecated public class DefaultRelatedExpression<N,T,B,MB extends B,TB extends B,S,QI,EV,PP,R extends DefaultRelatedExpression<N,T,B,MB,TB,S,QI,EV,PP,R>> extends Object implements RelatedExpression<N,T,B,TB,S,QI,R>
Deprecated.
An abstract base class for implementing related expressions.
-
Field Summary
-
Constructor Summary
Constructors Modifier Constructor Description protectedDefaultRelatedExpression()Deprecated.Used in contract testing.DefaultRelatedExpression(boolean isEffectivelyFinal, Supplier<QI> nameSupplier, N relatedExpression, RelatedExpressionStrategy<N,T,B,TB,S,QI,R> strategy, RelatedExpressionsSpi<N,?,T,B,MB,TB,S,?,QI,EV,PP,R> relatedExpressionsSpi, Function<S,B> nameBindingResolver, Function<S,Integer> lengthOfTypeForTempVarFunction, BiFunction<S,Function<TB,T>,T> typeForTypeVarFunction, Function<S,TB> typeResolver, BiPredicate<? super DefaultRelatedExpression<N,T,B,MB,TB,S,QI,EV,PP,R>,R> canBeUsedInsteadOfBiPredicate)Deprecated. -
Method Summary
Modifier and Type Method Description booleancanBeUsedInsteadOf(R other)Deprecated.Used to resolve referential ambiguity between related expressions.booleanequals(Object obj)Deprecated.List<QI>getAssociateNames()Deprecated.intgetColumn()Deprecated.List<QI>getContainedNamesFromSurface()Deprecated.StringgetDescription()Deprecated.intgetLengthOfTypeForTempVar(S scope)Deprecated.intgetLine()Deprecated.QIgetName()Deprecated.Return the name used as identifier in the related expression, if the related expression declares a name.List<QI>getPartNames()Deprecated.NgetRelatedExpression()Deprecated.RelatedExpressionStrategy<N,T,B,TB,S,QI,R>getStrategy()Deprecated.TgetTypeForTempVar(S scope, Function<TB,T> importRewrite)Deprecated.Returns the type of the related expression for use in declaring a local temporary variable.inthashCode()Deprecated.booleanisEffectivelyFinal()Deprecated.If the related expression is effectively final, its value is identical at run-time, regardless of whether the related expression occurs in its original position, or would be moved or copied to the position of the anaphor.List<TB>resolveAssociateTypes(S scope)Deprecated.List<TB>resolveContainedTypesFromSurface(S scope)Deprecated.BresolveNameBinding(S scope)Deprecated.Resolves the binding of the name declared in the related expression.List<TB>resolvePartTypes(S scope)Deprecated.TBresolveType(S scope)Deprecated.Resolve the type of the related expressionvoidsetRelatedExpression(N relatedExpression)Deprecated.Replaces the current related expression with the given one.StringtoString()Deprecated.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface de.monochromata.anaphors.ast.relatedexp.RelatedExpression
hasName, shouldResolutionReplaceRelatedExpressionWithTempDeclaration
-
Field Details
-
Constructor Details
-
DefaultRelatedExpression
protected DefaultRelatedExpression()Deprecated.Used in contract testing.
-
-
Method Details
-
isEffectivelyFinal
Deprecated.Description copied from interface:RelatedExpressionIf the related expression is effectively final, its value is identical at run-time, regardless of whether the related expression occurs in its original position, or would be moved or copied to the position of the anaphor. -
getName
Deprecated.Description copied from interface:RelatedExpressionReturn the name used as identifier in the related expression, if the related expression declares a name. Null is returned, ifRelatedExpression.hasName()returns false.- Specified by:
getNamein interfaceRelatedExpression<N,T,B,MB extends B,TB extends B,S,QI>- Returns:
- Null, if
RelatedExpression.hasName()returns false. - See Also:
RelatedExpression.hasName()
-
getRelatedExpression
Deprecated. -
setRelatedExpression
Deprecated.Description copied from interface:RelatedExpressionReplaces the current related expression with the given one.- Specified by:
setRelatedExpressionin interfaceRelatedExpression<N,T,B,MB extends B,TB extends B,S,QI>- Parameters:
relatedExpression- The new related expression- See Also:
RelatedExpression.getRelatedExpression(),RelatedExpression.getStrategy()
-
getStrategy
Deprecated. -
resolveNameBinding
Deprecated.Description copied from interface:RelatedExpressionResolves the binding of the name declared in the related expression. Returns null, ifRelatedExpression.hasName()returns false.- Specified by:
resolveNameBindingin interfaceRelatedExpression<N,T,B,MB extends B,TB extends B,S,QI>- Parameters:
scope- The scope containing the related expression if used by the compiler-specific implementation. Implementations of this method must not access the scope but merely pass it on to SPI's they invoke.- Returns:
- The resolved binding.
-
getLengthOfTypeForTempVar
Deprecated. -
getTypeForTempVar
Deprecated.Description copied from interface:RelatedExpressionReturns the type of the related expression for use in declaring a local temporary variable. This method needs to add import declarations if necessary to make the type useable for the temp var. -
resolveType
Deprecated.Description copied from interface:RelatedExpressionResolve the type of the related expression- Specified by:
resolveTypein interfaceRelatedExpression<N,T,B,MB extends B,TB extends B,S,QI>- Parameters:
scope- The scope containing the related expression if used by the compiler-specific implementation. Implementations of this method must not access the scope but merely pass it on to SPI's they invoke.- Returns:
- The resolved type.
-
getContainedNamesFromSurface
Deprecated. -
getPartNames
Deprecated. -
getAssociateNames
Deprecated. -
resolveContainedTypesFromSurface
Deprecated. -
resolvePartTypes
Deprecated. -
resolveAssociateTypes
Deprecated. -
canBeUsedInsteadOf
Deprecated.Description copied from interface:RelatedExpressionUsed to resolve referential ambiguity between related expressions.- Specified by:
canBeUsedInsteadOfin interfaceRelatedExpression<N,T,B,MB extends B,TB extends B,S,QI>- Parameters:
other- Another related expression.- Returns:
- True, if this related expression refers to the same referent as
otherand this related expression should be used instead ofotherin order to eliminate the ambiguity between the two. False is returned otherwise.
-
getDescription
Deprecated. -
getLine
Deprecated. -
getColumn
Deprecated. -
hashCode
Deprecated. -
equals
Deprecated. -
toString
Deprecated.
-
RelatedExpressionwill be turned into a POJO instead