Class ExpressionProposalProvider
- java.lang.Object
-
- org.eclipse.xtext.ui.editor.contentassist.AbstractCompletionProposalFactory
-
- org.eclipse.xtext.ui.editor.contentassist.AbstractContentProposalProvider
-
- org.eclipse.xtext.ui.editor.contentassist.AbstractJavaBasedContentProposalProvider
-
- de.uni_hildesheim.sse.ui.contentassist.AbstractIvmlProposalProvider
-
- de.uni_hildesheim.sse.ui.contentassist.ExpressionProposalProvider
-
- All Implemented Interfaces:
org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalFactory,org.eclipse.xtext.ui.editor.contentassist.IContentProposalProvider
- Direct Known Subclasses:
IvmlProposalProvider
public class ExpressionProposalProvider extends de.uni_hildesheim.sse.ui.contentassist.AbstractIvmlProposalProviderImplements a proposal provider for IVML expressions. We separate the expression proposal provider from the remainder of the proposal implementation to enable specialized embedded editors such as the constraint editor to work with a restricted proposal provider. This class also provides access to the IVML model if available.- Author:
- Dernek, Holger Eichelberger
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.eclipse.xtext.ui.editor.contentassist.AbstractJavaBasedContentProposalProvider
org.eclipse.xtext.ui.editor.contentassist.AbstractJavaBasedContentProposalProvider.DefaultProposalCreator, org.eclipse.xtext.ui.editor.contentassist.AbstractJavaBasedContentProposalProvider.ReferenceProposalCreator
-
Nested classes/interfaces inherited from class org.eclipse.xtext.ui.editor.contentassist.AbstractContentProposalProvider
org.eclipse.xtext.ui.editor.contentassist.AbstractContentProposalProvider.DefaultContentAssistProcessorSwitch, org.eclipse.xtext.ui.editor.contentassist.AbstractContentProposalProvider.NullSafeCompletionProposalAcceptor
-
-
Field Summary
Fields Modifier and Type Field Description private org.eclipse.xtext.ui.IImageHelperimageHelper
-
Constructor Summary
Constructors Constructor Description ExpressionProposalProvider()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcompleteCall_Call(org.eclipse.emf.ecore.EObject model, org.eclipse.xtext.Assignment assignment, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor)Propose completions for a call.voidcompleteCall_SetOp(org.eclipse.emf.ecore.EObject model, org.eclipse.xtext.Assignment assignment, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor)Propose completions for a set operation.voidcompleteLiteral_Val(org.eclipse.emf.ecore.EObject model, org.eclipse.xtext.Assignment assignment, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor)Completes a literal value.voidcompleteLogicalExpressionPart_Op(org.eclipse.emf.ecore.EObject model, org.eclipse.xtext.Assignment assignment, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor)Propose completions for a high-level prototype of expressions with (internal) functions.protected IDatatypefindType(org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound typeDef, java.lang.String name)Finds the definition of a data type within the model represented bymodel.protected de.uni_hildesheim.sse.ivml.TypedefCompoundfindTypedefCompound(org.eclipse.xtext.nodemodel.INode node)Returns theTypedefCompound-object inside the declaration of this compound.protected ProjectgetVarModel(org.eclipse.emf.ecore.EObject model)Provides access to the already created IVML model if available.private IDatatypeinferType(de.uni_hildesheim.sse.ivml.AdditiveExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type forexpression.protected IDatatypeinferType(de.uni_hildesheim.sse.ivml.AssignmentExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type forexpression.private IDatatypeinferType(de.uni_hildesheim.sse.ivml.Call call, IDatatype operand, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type for acall.private IDatatypeinferType(de.uni_hildesheim.sse.ivml.EqualityExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type forexpression.protected IDatatypeinferType(de.uni_hildesheim.sse.ivml.Expression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type forexpression.private IDatatypeinferType(de.uni_hildesheim.sse.ivml.FeatureCall call, IDatatype operand, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type for acall.protected IDatatypeinferType(de.uni_hildesheim.sse.ivml.ImplicationExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type forexpression.protected IDatatypeinferType(de.uni_hildesheim.sse.ivml.LogicalExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type forexpression.private IDatatypeinferType(de.uni_hildesheim.sse.ivml.MultiplicativeExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type forexpression.private IDatatypeinferType(de.uni_hildesheim.sse.ivml.PostfixExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type forexpression.private IDatatypeinferType(de.uni_hildesheim.sse.ivml.PrimaryExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type forexpression.private IDatatypeinferType(de.uni_hildesheim.sse.ivml.RelationalExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type forexpression.private IDatatypeinferType(de.uni_hildesheim.sse.ivml.UnaryExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type forexpression.private IDatatypeinferType(de.uni_hildesheim.sse.ivml.Value value, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type forvale.private IDatatypeinferType(java.lang.String name, IDatatype operand, IDatatype[] pTypes, boolean containerOp)Determines the type of the operationnameonoperandwith given parameters.private IDatatypeinferType(java.util.List<de.uni_hildesheim.sse.ivml.Call> calls, IDatatype operand, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)Returns the IVML type for a chain ofcalls.protected static booleanisEmpty(java.util.List<?> list)Check whether a given List is null or empty.protected voidpropose(AttributeAssignment assgn, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor, int priority, java.util.Set<java.lang.String> done)Propose declared variables on the given attribute assignment.protected voidpropose(Compound type, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor, int priority, java.util.Set<java.lang.String> done)Propose declared variables on a compoundtype.protected voidpropose(DecisionVariableDeclaration decl, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor, int priority, java.util.Set<java.lang.String> done)Proposes an IVML variable declaration.private voidproposeOperations(IDatatype type, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor, boolean containerOp)Propose operations based on an IVML type.protected voidproposeOperations(org.eclipse.emf.ecore.EObject model, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor, boolean containerOp)Propose operations by inferring the actual IVML type.private static java.lang.StringstripSignature(java.lang.String signature)Removes the defining type from the signature.-
Methods inherited from class de.uni_hildesheim.sse.ui.contentassist.AbstractIvmlProposalProvider
complete_AccessName, complete_ActualArgument, complete_ActualArgumentList, complete_AdditiveExpression, complete_AdditiveExpressionPart, complete_AdditiveOperator, complete_AnnotateTo, complete_ANY_OTHER, complete_AssignmentExpression, complete_AssignmentExpressionPart, complete_AssignmentOperator, complete_AttrAssignment, complete_AttrAssignmentPart, complete_BasicType, complete_BlockExpression, complete_Call, complete_ConflictStmt, complete_ContainerInitializer, complete_ContainerOp, complete_Declaration, complete_Declarator, complete_DerivedType, complete_EqualityExpression, complete_EqualityExpressionPart, complete_EqualityOperator, complete_Eval, complete_EXPONENT, complete_Export, complete_Expression, complete_ExpressionAccess, complete_ExpressionListEntry, complete_ExpressionListOrRange, complete_ExpressionStatement, complete_FeatureCall, complete_Freeze, complete_FreezeStatement, complete_ID, complete_Identifier, complete_IfExpression, complete_ImplicationExpression, complete_ImplicationExpressionPart, complete_ImplicationOperator, complete_ImportStmt, complete_InterfaceDeclaration, complete_LetExpression, complete_Literal, complete_LogicalExpression, complete_LogicalExpressionPart, complete_LogicalOperator, complete_ML_COMMENT, complete_MultiplicativeExpression, complete_MultiplicativeExpressionPart, complete_MultiplicativeOperator, complete_NUMBER, complete_NumValue, complete_OpDefParameter, complete_OpDefParameterList, complete_OpDefStatement, complete_OptBlockExpression, complete_PostfixExpression, complete_PrimaryExpression, complete_Project, complete_ProjectContents, complete_QualifiedName, complete_RelationalExpression, complete_RelationalExpressionPart, complete_RelationalOperator, complete_SL_COMMENT, complete_STRING, complete_Type, complete_Typedef, complete_TypedefCompound, complete_TypedefConstraint, complete_TypedefEnum, complete_TypedefEnumLiteral, complete_TypedefMapping, complete_UnaryExpression, complete_UnaryOperator, complete_Value, complete_VariabilityUnit, complete_VariableDeclaration, complete_VariableDeclarationPart, complete_VERSION, complete_VersionStmt, complete_WS, completeAccessName_AName, completeActualArgument_Arg, completeActualArgument_Name, completeActualArgumentList_Args, completeAdditiveExpression_Left, completeAdditiveExpression_Right, completeAdditiveExpressionPart_Ex, completeAdditiveExpressionPart_Op, completeAnnotateTo_AnnotationDecl, completeAnnotateTo_AnnotationType, completeAnnotateTo_Names, completeAnnotateTo_Sname, completeAssignmentExpression_Left, completeAssignmentExpression_Right, completeAssignmentExpressionPart_Container, completeAssignmentExpressionPart_Ex, completeAssignmentExpressionPart_Op, completeAttrAssignment_Elements, completeAttrAssignment_Parts, completeAttrAssignmentPart_Name, completeAttrAssignmentPart_Value, completeBasicType_Type, completeBlockExpression_Exprs, completeCall_ArrayEx, completeCall_ContainerOp, completeConflictStmt_Name, completeConflictStmt_Restriction, completeContainerInitializer_Init, completeContainerInitializer_Type, completeContainerOp_Decl, completeContainerOp_Name, completeDeclaration_Id, completeDeclaration_Init, completeDeclaration_Type, completeDeclarator_Decl, completeDerivedType_Op, completeDerivedType_Type, completeEqualityExpression_Left, completeEqualityExpression_Right, completeEqualityExpressionPart_Container, completeEqualityExpressionPart_Ex, completeEqualityExpressionPart_Op, completeEval_Nested, completeEval_Statements, completeExport_Names, completeExpression_Container, completeExpression_Expr, completeExpression_Let, completeExpressionAccess_Access, completeExpressionAccess_Calls, completeExpressionAccess_Name, completeExpressionListEntry_Attrib, completeExpressionListEntry_Container, completeExpressionListEntry_Name, completeExpressionListEntry_Value, completeExpressionListOrRange_List, completeExpressionStatement_Expr, completeFeatureCall_Name, completeFreeze_Ex, completeFreeze_Id, completeFreeze_Names, completeFreezeStatement_Access, completeFreezeStatement_Dot, completeFreezeStatement_Name, completeIfExpression_ElseEx, completeIfExpression_IfEx, completeIfExpression_ThenEx, completeImplicationExpression_Left, completeImplicationExpression_Right, completeImplicationExpressionPart_Ex, completeImplicationExpressionPart_Op, completeImportStmt_Interface, completeImportStmt_Name, completeImportStmt_Restriction, completeInterfaceDeclaration_Exports, completeInterfaceDeclaration_Name, completeLetExpression_Name, completeLetExpression_SubExpr, completeLetExpression_Type, completeLetExpression_ValueExpr, completeLogicalExpression_Left, completeLogicalExpression_Right, completeLogicalExpressionPart_Ex, completeMultiplicativeExpression_Left, completeMultiplicativeExpression_Right, completeMultiplicativeExpressionPart_Expr, completeMultiplicativeExpressionPart_Op, completeNumValue_Val, completeOpDefParameter_Id, completeOpDefParameter_Type, completeOpDefParameter_Val, completeOpDefParameterList_List, completeOpDefStatement_Block, completeOpDefStatement_Id, completeOpDefStatement_Impl, completeOpDefStatement_Param, completeOpDefStatement_Result, completeOpDefStatement_Static, completeOptBlockExpression_Block, completeOptBlockExpression_Expr, completePostfixExpression_Access, completePostfixExpression_Call, completePostfixExpression_FCalls, completePostfixExpression_Left, completePrimaryExpression_Access, completePrimaryExpression_Calls, completePrimaryExpression_Ex, completePrimaryExpression_IfEx, completePrimaryExpression_Lit, completePrimaryExpression_RefEx, completeProject_Conflicts, completeProject_Contents, completeProject_Imports, completeProject_Interfaces, completeProject_Name, completeProject_Version, completeProjectContents_Elements, completeQualifiedName_QName, completeRelationalExpression_Left, completeRelationalExpression_Right, completeRelationalExpression_Right2, completeRelationalExpressionPart_Ex, completeRelationalExpressionPart_Op, completeType_Derived, completeType_Id, completeType_Type, completeTypedef_TCompound, completeTypedef_TEnum, completeTypedef_TMapping, completeTypedefCompound_Abstract, completeTypedefCompound_Elements, completeTypedefCompound_Name, completeTypedefCompound_Super, completeTypedefConstraint_Expressions, completeTypedefEnum_Constraint, completeTypedefEnum_Literals, completeTypedefEnum_Name, completeTypedefEnumLiteral_Name, completeTypedefEnumLiteral_Value, completeTypedefMapping_Constraint, completeTypedefMapping_NewType, completeTypedefMapping_Type, completeUnaryExpression_Expr, completeUnaryExpression_Op, completeValue_BValue, completeValue_NullValue, completeValue_NValue, completeValue_QValue, completeValue_Self, completeValue_SValue, completeValue_TValue, completeValue_Version, completeVariabilityUnit_Projects, completeVariableDeclaration_Const, completeVariableDeclaration_Decls, completeVariableDeclaration_Type, completeVariableDeclarationPart_Default, completeVariableDeclarationPart_Name, completeVersionStmt_Version
-
Methods inherited from class org.eclipse.xtext.ui.editor.contentassist.AbstractJavaBasedContentProposalProvider
announceProcessing, completeAssignment, completeKeyword, completeRuleCall, createProposals, getCrossReferenceProposalCreator, getHover, getProposalFactory, getScopeProvider, invokeMethod, lookupCrossReference, lookupCrossReference, lookupCrossReference, lookupCrossReference, lookupCrossReference, lookupCrossReference, setCrossReferenceProposalCreator, setScopeProvider
-
Methods inherited from class org.eclipse.xtext.ui.editor.contentassist.AbstractContentProposalProvider
createSelector, getDisplayString, getImage, getImage, getKeywordDisplayString, getLabelProvider, getQualifiedNameConverter, getStyledDisplayString, getStyledDisplayString, getValueConverter, setLabelProvider, setValueConverter
-
Methods inherited from class org.eclipse.xtext.ui.editor.contentassist.AbstractCompletionProposalFactory
createCompletionProposal, createCompletionProposal, createCompletionProposal, createCompletionProposal, doCreateProposal, doCreateProposal, getConflictHelper, getPriorityHelper, getReplacementContextLength, isValidProposal, setConflictHelper, setPriorityHelper
-
-
-
-
Method Detail
-
isEmpty
protected static boolean isEmpty(java.util.List<?> list)
Check whether a given List is null or empty.- Parameters:
list- The list to be checked.- Returns:
- True if the list is null or has no elements. False otherwise.
-
getVarModel
protected Project getVarModel(org.eclipse.emf.ecore.EObject model)
Provides access to the already created IVML model if available.- Parameters:
model- the node representing the ECore Xtext model- Returns:
- the IVML project (null if not available)
-
findType
protected IDatatype findType(org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound typeDef, java.lang.String name)
Finds the definition of a data type within the model represented bymodel.- Parameters:
model- the node representing the ECore Xtext modeltypeDef- the containing type (may be null for the project represented bytypeDef)name- the name of the type (may be null to search for the type oftypeDef- Returns:
- the type definition or null if not found
- See Also:
getVarModel(EObject)
-
propose
protected void propose(Compound type, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor, int priority, java.util.Set<java.lang.String> done)
Propose declared variables on a compoundtype.- Parameters:
type- the compound typecontext- the content assist contextacceptor- the proposal acceptorpriority- the maximum display priority to decrease per type refined typedone- the already processed variables (variable names)
-
propose
protected void propose(AttributeAssignment assgn, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor, int priority, java.util.Set<java.lang.String> done)
Propose declared variables on the given attribute assignment.- Parameters:
assgn- the attribute assignmentcontext- the content assist contextacceptor- the proposal acceptorpriority- the maximum display priority to decrease per type refined typedone- the already processed variables (variable names)
-
propose
protected void propose(DecisionVariableDeclaration decl, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor, int priority, java.util.Set<java.lang.String> done)
Proposes an IVML variable declaration.- Parameters:
decl- the variable declarationcontext- the content assist contextacceptor- the proposal acceptorpriority- the display priority to usedone- the already processed variables (variable names)
-
completeLiteral_Val
public void completeLiteral_Val(org.eclipse.emf.ecore.EObject model, org.eclipse.xtext.Assignment assignment, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor)Completes a literal value.- Overrides:
completeLiteral_Valin classde.uni_hildesheim.sse.ui.contentassist.AbstractIvmlProposalProvider- Parameters:
model- the node representing the ECore Xtext modelassignment- the assignmentcontext- the content assist contextacceptor- the proposal acceptor
-
findTypedefCompound
protected de.uni_hildesheim.sse.ivml.TypedefCompound findTypedefCompound(org.eclipse.xtext.nodemodel.INode node)
Returns theTypedefCompound-object inside the declaration of this compound.- Parameters:
node- the last complete node- Returns:
TypedefCompoundImpl, maybe null.
-
completeLogicalExpressionPart_Op
public void completeLogicalExpressionPart_Op(org.eclipse.emf.ecore.EObject model, org.eclipse.xtext.Assignment assignment, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor)Propose completions for a high-level prototype of expressions with (internal) functions.- Overrides:
completeLogicalExpressionPart_Opin classde.uni_hildesheim.sse.ui.contentassist.AbstractIvmlProposalProvider- Parameters:
model- the node representing the ECore Xtext modelassignment- the assignmentcontext- the content assist contextacceptor- the proposal acceptor
-
completeCall_Call
public void completeCall_Call(org.eclipse.emf.ecore.EObject model, org.eclipse.xtext.Assignment assignment, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor)Propose completions for a call.- Overrides:
completeCall_Callin classde.uni_hildesheim.sse.ui.contentassist.AbstractIvmlProposalProvider- Parameters:
model- the node representing the ECore Xtext modelassignment- the assignmentcontext- the content assist contextacceptor- the proposal acceptor
-
completeCall_SetOp
public void completeCall_SetOp(org.eclipse.emf.ecore.EObject model, org.eclipse.xtext.Assignment assignment, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor)Propose completions for a set operation.- Parameters:
model- the node representing the ECore Xtext modelassignment- the assignmentcontext- the content assist contextacceptor- the proposal acceptor
-
proposeOperations
protected void proposeOperations(org.eclipse.emf.ecore.EObject model, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor, boolean containerOp)Propose operations by inferring the actual IVML type.- Parameters:
model- the node representing the ECore Xtext modelcontext- the content assist contextacceptor- the proposal acceptorcontainerOp- propose only container operations
-
proposeOperations
private void proposeOperations(IDatatype type, org.eclipse.xtext.ui.editor.contentassist.ContentAssistContext context, org.eclipse.xtext.ui.editor.contentassist.ICompletionProposalAcceptor acceptor, boolean containerOp)
Propose operations based on an IVML type.- Parameters:
type- the IVML type to propose operations for (may be null)context- the content assist contextacceptor- the proposal acceptorcontainerOp- propose only container operations
-
stripSignature
private static java.lang.String stripSignature(java.lang.String signature)
Removes the defining type from the signature.- Parameters:
signature- the original signature- Returns:
- the stripped signature
-
inferType
protected IDatatype inferType(de.uni_hildesheim.sse.ivml.Expression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type forexpression.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
protected IDatatype inferType(de.uni_hildesheim.sse.ivml.ImplicationExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type forexpression.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
protected IDatatype inferType(de.uni_hildesheim.sse.ivml.AssignmentExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type forexpression.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
protected IDatatype inferType(de.uni_hildesheim.sse.ivml.LogicalExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type forexpression.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
private IDatatype inferType(de.uni_hildesheim.sse.ivml.EqualityExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type forexpression.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
private IDatatype inferType(de.uni_hildesheim.sse.ivml.RelationalExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type forexpression.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
private IDatatype inferType(de.uni_hildesheim.sse.ivml.AdditiveExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type forexpression.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
private IDatatype inferType(de.uni_hildesheim.sse.ivml.MultiplicativeExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type forexpression.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
private IDatatype inferType(de.uni_hildesheim.sse.ivml.UnaryExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type forexpression.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
private IDatatype inferType(de.uni_hildesheim.sse.ivml.PostfixExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type forexpression.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
private IDatatype inferType(de.uni_hildesheim.sse.ivml.PrimaryExpression expression, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type forexpression.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
private IDatatype inferType(java.util.List<de.uni_hildesheim.sse.ivml.Call> calls, IDatatype operand, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type for a chain ofcalls.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
private IDatatype inferType(de.uni_hildesheim.sse.ivml.Call call, IDatatype operand, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type for acall.- Parameters:
expression- the expression to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
private IDatatype inferType(de.uni_hildesheim.sse.ivml.FeatureCall call, IDatatype operand, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type for acall.- Parameters:
expression- the expression to return the type foroperand- the operand type (may be null, use first parameter type [implicit operand] instead if present)model- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
inferType
private IDatatype inferType(java.lang.String name, IDatatype operand, IDatatype[] pTypes, boolean containerOp)
Determines the type of the operationnameonoperandwith given parameters.- Parameters:
name- the name of the operationoperand- the operand typepTypes- the parameter types (may be null)containerOp- propose only container operations- Returns:
- the inferred type or null if no type is available
-
inferType
private IDatatype inferType(de.uni_hildesheim.sse.ivml.Value value, org.eclipse.emf.ecore.EObject model, de.uni_hildesheim.sse.ivml.TypedefCompound cmpDef)
Returns the IVML type forvale.- Parameters:
value- the value to return the type formodel- the node representing the ECore Xtext modelcmpDef- the containing type definition (may be null for project)- Returns:
- the inferred type or null if no type is available
-
-