| org.andromda.translation.ocl.BaseTranslator org.andromda.translation.ocl.query.QueryTranslator
All known Subclasses: org.andromda.translation.ocl.query.EjbQLTranslator,
QueryTranslator | public class QueryTranslator extends BaseTranslator (Code) | | Performs translation to the following:
author: Chad Brandon |
Method Summary | |
public void | handleDotOperation(String translation, Object node) | public void | handleIncludes(String translation, Object node) | public void | handleIsLike(String translation, Object node) | public void | handleLogicalExpression(String translation, Object node) | public void | handleRelationalExpression(String translation, Object node) | public void | handleSelect(String translation, Object node) | public void | handleSortedBy(String translation, Object node) | public void | handleSubSelect(String translation, Object node) | public void | inAFeatureCall(AFeatureCall expression) Override to handle any featureCall expressions ( i.e. | public void | inALogicalExpressionTail(ALogicalExpressionTail logicalExpressionTail) Override to deal with logical 'and, 'or', 'xor, ... | public void | inAParenthesesPrimaryExpression(AParenthesesPrimaryExpression expression) Override to deal with entering parenthesis expressions '( )'. | public void | inAPropertyCallExpression(APropertyCallExpression expression) Override to handle any propertyCall expressions ( i.e. | public void | inARelationalExpressionTail(ARelationalExpressionTail relationalExpressionTail) Override to deal with relational ' <, '>', '=', ... | public void | inAStandardDeclarator(AStandardDeclarator declarator) Helps out with 'includesAll', replaces the {1} in the expression fragment when a declarator is encountered (i.e. | protected boolean | isInitialDeclarator() True/false whether or not its the initial declarator. | public void | outAParenthesesPrimaryExpression(AParenthesesPrimaryExpression expression) Override to deal with leaving parenthesis expressions '( )'. | public void | postProcess() Handles any final processing. | public void | preProcess() Called by super class to reset any objects. | protected String | replaceFragment(String fragment, String replacement, int index) Checks to see if the replacement is an argument and if so replaces the {index} in the fragment with the
'argument' fragment from the template. |
handleLogicalExpression | public void handleLogicalExpression(String translation, Object node)(Code) | | |
handleRelationalExpression | public void handleRelationalExpression(String translation, Object node)(Code) | | |
inAFeatureCall | public void inAFeatureCall(AFeatureCall expression)(Code) | | Override to handle any featureCall expressions ( i.e. sortedBy( ), etc.)
See Also: org.andromda.core.translation.analysis.DepthFirstAdapter.inAFeatureCallExpression(org.andromda.core.translation.node.APropertyCallExpression) |
inALogicalExpressionTail | public void inALogicalExpressionTail(ALogicalExpressionTail logicalExpressionTail)(Code) | | Override to deal with logical 'and, 'or', 'xor, ... expressions.
See Also: org.andromda.core.translation.analysis.DepthFirstAdapter.inALogicalExpressionTail(org.andromda.core.translation.node.ALogicalExpressionTail) |
inAParenthesesPrimaryExpression | public void inAParenthesesPrimaryExpression(AParenthesesPrimaryExpression expression)(Code) | | Override to deal with entering parenthesis expressions '( )'.
See Also: org.andromda.core.translation.analysis.DepthFirstAdapter.inAParenthesesPrimaryExpression(org.andromda.core.translation.node.AParenthesesPrimaryExpression) |
inAPropertyCallExpression | public void inAPropertyCallExpression(APropertyCallExpression expression)(Code) | | Override to handle any propertyCall expressions ( i.e. includes( ), select( ), etc.)
See Also: org.andromda.core.translation.analysis.DepthFirstAdapter.inAPropertyCallExpression(org.andromda.core.translation.node.APropertyCallExpression) |
inARelationalExpressionTail | public void inARelationalExpressionTail(ARelationalExpressionTail relationalExpressionTail)(Code) | | Override to deal with relational ' <, '>', '=', ... expressions.
See Also: org.andromda.core.translation.analysis.DepthFirstAdapter.inARelationalExpressionTail(org.andromda.core.translation.node.ARelationalExpressionTail) |
inAStandardDeclarator | public void inAStandardDeclarator(AStandardDeclarator declarator)(Code) | | Helps out with 'includesAll', replaces the {1} in the expression fragment when a declarator is encountered (i.e.
'| ')
|
isInitialDeclarator | protected boolean isInitialDeclarator()(Code) | | True/false whether or not its the initial declarator. We care about this because we must know what the first one
is for differentiating between the first declarator (the beginning of the query) and any other declarators (the
connecting associations).
|
outAParenthesesPrimaryExpression | public void outAParenthesesPrimaryExpression(AParenthesesPrimaryExpression expression)(Code) | | Override to deal with leaving parenthesis expressions '( )'.
See Also: org.andromda.core.translation.analysis.DepthFirstAdapter.outAParenthesesPrimaryExpression(org.andromda.core.translation.node.AParenthesesPrimaryExpression) |
postProcess | public void postProcess()(Code) | | Handles any final processing.
|
preProcess | public void preProcess()(Code) | | Called by super class to reset any objects.
|
replaceFragment | protected String replaceFragment(String fragment, String replacement, int index)(Code) | | Checks to see if the replacement is an argument and if so replaces the {index} in the fragment with the
'argument' fragment from the template. Otherwise replaces the {index} with the passed in replacement value.
Parameters: fragment - the fragment to perform replacement. Parameters: replacement - the replacement string Parameters: index - the index in the string to replace. String the fragment with any replacements. |
Fields inherited from org.andromda.translation.ocl.BaseTranslator | protected Logger logger(Code)(Java Doc)
|
|
|